hardware acceleration on allwinner A10/A20 with vdpau and OpenGLES (zero-copy)
(2017-08-07, 20:55)xchetah Wrote: hi @mosterta

Quote:- thumbnails are generated using FFMPEG, but this should be done without using VDPAU. I can not work with VDPAU. I have seen some code that ffmpeg without VDPAU is used. But I have to double check that.
- the slow interface is probably due to excessive debug logging into kodi.log. When you disable it, it should be better. When you recompile with -O2, it also makes a huge improvement. But of course that makes debugging much more difficult.
- I can't see any tearing in A10/A20 implementation. Where does your kernel come from? check drivers/video/sunxi/disp/dev_fb.c that VSYNC is enabled
case FBIO_WAITFORVSYNC:
{
ret = Fb_wait_for_vsync(info);
break;
}
- audio visualizations should work. These use OpenGLES on the gui layer. The hardware layer and mixing is only used for video support.

for thumbnails , I have this from the log when I regenerate them
Code:
21:42:40.595 T:2684777216   DEBUG: DoWork - trying to extract thumb from video file /home/eyad/Desktop/big_buck_bunny_1080p_H264_AAC_25fps_7200K.MP4
21:42:40.604 T:2684777216   DEBUG: Open - probing detected format [mov,mp4,m4a,3gp,3g2,mj2]
21:42:41.432 T:2684777216   DEBUG: Open - avformat_find_stream_info starting
21:42:41.503 T:2923422464   DEBUG: Thread BackgroundLoader 2923422464 terminating
21:42:42.175 T:2684777216   DEBUG: Open - av_find_stream_info finished
21:42:42.183 T:2684777216   DEBUG: ScanForExternalSubtitles: Searching for subtitles...
21:42:42.185 T:2684777216   DEBUG: ScanForExternalSubtitles: END (total time: 3 ms)
21:42:42.186 T:2684777216   DEBUG: FactoryCodec - Video:  - Opening
21:42:42.187 T:2684777216  NOTICE: CDVDVideoCodecFFmpeg::Open() Using codec: H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
21:42:42.188 T:2684777216   DEBUG: CDVDVideoCodecFFmpeg - Updated codec: ff-h264
21:42:42.189 T:2684777216   DEBUG: FactoryCodec - Video: ff-h264 - Opened
21:42:42.190 T:2684777216   DEBUG: ExtractThumb - seeking to pos 15000ms (total: 45000ms) in /home/eyad/Desktop/big_buck_bunny_1080p_H264_AAC_25fps_7200K.MP4
21:42:42.191 T:2684777216   DEBUG: SeekTime - unknown position after seek
21:42:42.202 T:2684777216  NOTICE: CDVDVideoCodecFFmpeg::GetFormat - Creating VDPAU(1920x1080)
21:42:42.544 T:2684777216   DEBUG: cached image 'special://masterprofile/Thumbnails/d/de877497.jpg' size 720x405
21:42:42.715 T:2684777216   DEBUG: ExtractThumb - measured 2120 ms to extract thumb from file </home/eyad/Desktop/big_buck_bunny_1080p_H264_AAC_25fps_7200K.MP4> in 10 packets.
does this line means it is using vdpau?(NOTICE: CDVDVideoCodecFFmpeg::GetFormat - Creating VDPAU(1920x1080))

-checking config.status it seems I've already enabled -O2 , maybe because I enabled optimizations (without it ffmpeg doesn't compile).
-my kernel is the official linux-sunxi branch , and it has VSYNC is enabled.
-here's a video demonstrating the problem : https://drive.google.com/file/d/0BzQVVX8...Zwdm8/view
-fbset reports 68Hz , while kodi reports 50Hz could this be the problem?
-do you want me to debug libcedarJpeg so it can support A13?

I have checked, there is a if statement that for thumbnail generation plain ffmpeg should be used. But, I have changed the code that "hardware" buffers are used in case plain ffmpeg is used for videos not supported by VDPAU. (to accelerate non-vdpau videos). This functionality may have broken the thumbnail generation. I may not noticed because the thumbnails are all already generated when I test. Sad I have to check more in detail and repair it. Unfortunately there is nothing you can do to disable this functionality.

- I had a look to your video. actually I do not know whether I have the same issue. I could not see which use case you actually trigger, i.e. I do not know how to scroll the icons fast enough to check whether I see the same issue.
- If you have time to debug libcedarjpeg, that would be great. I guess there are two possible issues here: the pointer to the UMP buffer is wrong and the cedar HW overwrites kernel memory or even the interrupt table (check for passing address 0 to the cedar hardware) or the hardware itself stops working when it is triggered.
Reply


Messages In This Thread
RE: hardware acceleration on allwinner A10/A20 with vdpau and OpenGLES (zero-copy) - by mosterta - 2017-08-07, 22:39
Logout Mark Read Team Forum Stats Members Help
hardware acceleration on allwinner A10/A20 with vdpau and OpenGLES (zero-copy)2