I am writing a media player where we need to decode UHD video encoded in HEVC format. I tried using sample_decode app to decode the file. The decode rate was very low, as low as 7FPS.
The Intel Media SDK that I am using is version R6 (Though latest is R7, it is not available for Linux platform) professional 30 day evaluation version.
Does vR6 Intel Media SDK on Linux platform support h/w accelerated HEVC decode?
Is this decoding rate of 7FPS expected behaviour? Is there any way of getting better performance than this?
The command that I had used was
sample_decode h265 -i inp.h265 -o out.yuv -hw
The video used for decoding had following format.
Resolution 3840x2160 , Video: hevc (Main 10), 50fps
Any clarification on this will be of great help.
Can you please let us know what is your system configuration? Also, your writing an o/p to a file which is not the true way to check decoder performance since this involves lot of i/o part which should not be captured as a decoding performance.
I would recommend you to check the decoder without writing the o/p and using the surfaces directly into pipeline. On E3-1285L v4, I am able to achieve 100+ fps for a 3840x2160p video.
Hope it helps.
Thanks for providing system details. On 4th generation core processor, there is only 1 hevc implementation available on Linux i.e. sw hevc decode implementation due to which you are seeing entire load on CPU.
But it still looks like you might not be seeing best performance available on your platform. I did test on couple of commonly used videos on i7-4770K CPU and below is result of one of them
[root@localhost x64]# ./sample_decode_drm h265 -i /home/lmsdk/Videos/crowd_run_1080p.265
plugin_loader.h :157 [INFO] Plugin was loaded from GUID
libva info: VA-API version 0.35.0
libva info: va_getDriverName() returns 0
libva info: User requested driver 'iHD'
libva info: Trying to open /opt/intel/mediasdk/lib64/iHD_drv_video.so
libva info: Found init function __vaDriverInit_0_32
libva info: va_openDriver() returns 0
Decoding Sample Version 6.0.16043175.175
Input video HEVC
Output format YUV420
Crop X,Y,W,H 0,0,0,0
Frame rate 0.00
Memory type system
MediaSDK impl hw
MediaSDK version 1.16
Frame number: 500, fps: 163.186, fread_fps: 0.000, fwrite_fps: 0.000
Also, can you try adding async depth parameter. Asncy depth is the no. of asynchronous operations the application plans to perform before synchronization. It is suggested to use value 4 or 5 in case of single decode to stress the system enough and in case of multiple decode, keep the value to be 1.
Let us know if you see improved performance.
Thanks for the update. The resolution I am trying is of UHD. So, the performance is not comparable with HD resolution.
Is there any platform where HEVC decode in hardware is supported?
Yes, HEVC HW decode is available from 6th generation onwards(SKL).
Currently media server studio doesn't provide 6th generation support, will be coming out with that in future. You can use Intel Media SDK Client on windows, which currently supports 6th generation to measure the performance. Media Server Studio and Media SDK shares same API and SDK, they are targeting different segments. Also, the performance on Linux and Windows is pretty similar so you can expect to see similar results on SKL using Media Server Studio.