Jump to content


Photo

What is the current status of hardware acceleration

Hardware acceleration Emby Server 2017

  • Please log in to reply
43 replies to this topic

#41 dapharsyde OFFLINE  

dapharsyde

    Member

  • Members
  • 11 posts
  • Local time: 01:33 PM

Posted 24 April 2018 - 12:46 AM

From @dcrdev, he writes:

 

This is because the ffmpeg bundled with emby is compiled against the amdgpu kernel implementation of the radeonsi driver. Ubuntu uses radeon/gallium for pre GCN 1.2 cards a la a8-7600, support for GCN 1.1 in amdgpu is considered experimental. 

 

The correct DRM driver implementation for gallium, is gallium_drv_video.so - ffmpeg would have to be built against that for it to work. So yes you'd have to supply a custom build, which is problematic because of the self contained nature of the package - you'd also have to modify the startup script to remove the lib directory export and revert to externally managed dependencies; or create symbolic links.

 

I don't believe gallium is well supported by vaapi anyway - it only has a limited number of working extensions; so may not be worth it.

 

 

 

 
I'm using the radeon driver, but the bundled version of ffmpeg is compiled against radeonsi.

Edited by dapharsyde, 24 April 2018 - 12:46 AM.


#42 dapharsyde OFFLINE  

dapharsyde

    Member

  • Members
  • 11 posts
  • Local time: 01:33 PM

Posted 24 April 2018 - 04:53 AM

Well, I compiled my own ffmpeg with vaapi support, and succeeded in invoking a transcode with the vaapi device.  Unfortunately, it transcodes at 2 fps, whereas libx264 does 170+ fps.  The card is a Radeon R9 270X, so the slow performance doesn't seem right, I might have to troubleshoot this further with the ffmpeg devs.

 

 ./ffmpeg -vaapi_device /dev/dri/renderD128 -i /raid5vol02/video/livetv/24745_20180423010432.ts -vf 'format=nv12,hwupload' -c:v h264_vaapi -bf 0 -c:a copy /tmp/out.mp4
ffmpeg version N-90811-g2442cf3 Copyright (c) 2000-2018 the FFmpeg developers
  built with gcc 7 (Ubuntu 7.3.0-16ubuntu3)
  configuration: --prefix=/home/dapharsyde/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/home/dapharsyde/ffmpeg_build/include --extra-ldflags=-L/home/dapharsyde/ffmpeg_build/lib --extra-libs='-lpthread -lm' --bindir=/home/dapharsyde/bin --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree --enable-vaapi
  libavutil      56. 15.100 / 56. 15.100
  libavcodec     58. 19.100 / 58. 19.100
  libavformat    58. 13.100 / 58. 13.100
  libavdevice    58.  4.100 / 58.  4.100
  libavfilter     7. 19.100 /  7. 19.100
  libswscale      5.  2.100 /  5.  2.100
  libswresample   3.  2.100 /  3.  2.100
  libpostproc    55.  2.100 / 55.  2.100
Input #0, mpegts, from '/raid5vol02/video/livetv/24745_20180423010432.ts':
  Duration: 00:10:29.17, start: 35420.341567, bitrate: 3803 kb/s
  Program 1
    Stream #0:0[0xefd]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 1280x720 [SAR 1:1 DAR 16:9], Closed Captions, 59.94 fps, 59.94 tbr, 90k tbn, 119.88 tbc
    Stream #0:1[0xefe](eng): Audio: ac3 ([129][0][0][0] / 0x0081), 48000 Hz, 5.1(side), fltp, 384 kb/s
    Stream #0:2[0xeff](spa): Audio: ac3 ([129][0][0][0] / 0x0081), 48000 Hz, mono, fltp, 64 kb/s
    Stream #0:3[0xf00]: Data: scte_35
    Stream #0:4[0xf01]: Unknown: none (ETV1 / 0x31565445)
    Stream #0:5[0xf02]: Unknown: none (ETV1 / 0x31565445)
    Stream #0:6[0xf28]: Unknown: none ([192][0][0][0] / 0x00C0)
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (h264_vaapi))
  Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[h264 @ 0x55caf4b35200] co located POCs unavailable
[h264 @ 0x55caf4b83140] concealing 3215 DC, 3215 AC, 3215 MV errors in B frame
[h264_vaapi @ 0x55caf4c56dc0] Warning: some packed headers are not supported (want 0xd, got 0).
[mp4 @ 0x55caf4b35b00] track 1: codec frame size is not set
Output #0, mp4, to '/tmp/out.mp4':
  Metadata:
    encoder         : Lavf58.13.100
    Stream #0:0: Video: h264 (h264_vaapi) (Constrained Baseline) (avc1 / 0x31637661), vaapi_vld, 1280x720 [SAR 1:1 DAR 16:9], q=0-31, 59.94 fps, 60k tbn, 59.94 tbc
    Metadata:
      encoder         : Lavc58.19.100 h264_vaapi
    Stream #0:1(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s
frame=   70 fps=2.0 q=-0.0 Lsize=     350kB time=00:00:01.15 bitrate=2492.2kbits/s dup=59 drop=0 speed=0.0324x
 

Edited by dapharsyde, 24 April 2018 - 05:15 AM.


#43 jhoff80 OFFLINE  

jhoff80

    Advanced Member

  • Members
  • 353 posts
  • Local time: 04:33 PM

Posted 16 July 2018 - 03:22 PM

Does anyone have subtitles working with hardware acceleration?  Just not sure if there's something I have configured wrong on my system, or if it's a limitation of the hardware transcode.

 

I'm using NVENC and the file in this case has PGS forced subtitles.



#44 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 149355 posts
  • Local time: 04:33 PM

Posted 16 July 2018 - 03:51 PM

Does anyone have subtitles working with hardware acceleration?  Just not sure if there's something I have configured wrong on my system, or if it's a limitation of the hardware transcode.

 

I'm using NVENC and the file in this case has PGS forced subtitles.

 

If you're having an issue, please discuss an example and please attach the information requested in how to report a media playback issue. thanks !







Also tagged with one or more of these keywords: Hardware acceleration, Emby Server, 2017

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users