vaapi: Impossible to convert between the formats

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

vaapi: Impossible to convert between the formats

André Hänsel
I'm trying to transcode an MPEG4 avi to MP4 with VAAPI, but I'm getting an
error:

Impossible to convert between the formats supported by the filter
'Parsed_null_0' and the filter 'auto_scaler_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented

The failing command is:
ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
-hwaccel_output_format vaapi -i test.avi -c:v h264_vaapi out.mp4

Other combinations work just fine, like hardware decoding that same video:
ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -i test.avi -c:v
libx264 out.mp4

Hardware transcoding an MPEG2 input video works fine as well:
ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
-hwaccel_output_format vaapi -i test.mpg -c:v h264_vaapi out.mp4

Hardware transcoding an H264 video works, too:
ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
-hwaccel_output_format vaapi -i test.mp4 -c:v h264_vaapi out.mp4

How should I go about debugging this further?


_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Carl Eugen Hoyos-2
2018-06-13 12:29 GMT+02:00, André Hänsel <[hidden email]>:

> How should I go about debugging this further?

First step is to provide the command line you tested together
with the complete, uncut console output.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

André Hänsel
> > How should I go about debugging this further?
>
> First step is to provide the command line you tested together
> with the complete, uncut console output.
>
> Carl Eugen

# ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i test.avi -c:v h264_vaapi out.mp4
ffmpeg version 3.3.1-1~16.04.york0 Copyright (c) 2000-2017 the FFmpeg developers
  built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.4) 20160609
  configuration: --prefix=/usr --extra-version='1~16.04.york0' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
  libavutil      55. 58.100 / 55. 58.100
  libavcodec     57. 89.100 / 57. 89.100
  libavformat    57. 71.100 / 57. 71.100
  libavdevice    57.  6.100 / 57.  6.100
  libavfilter     6. 82.100 /  6. 82.100
  libavresample   3.  5.  0 /  3.  5.  0
  libswscale      4.  6.100 /  4.  6.100
  libswresample   2.  7.100 /  2.  7.100
  libpostproc    54.  5.100 / 54.  5.100
libva info: VA-API version 0.39.4
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_0_39
libva info: va_openDriver() returns 0
Input #0, avi, from 'test.avi':
  Metadata:
    encoder         : Lavf56.40.101
  Duration: 00:00:07.80, start: 0.000000, bitrate: 2851 kb/s
    Stream #0:0: Video: mpeg4 (Simple Profile) (FMP4 / 0x34504D46), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 2867 kb/s, 15 fps, 15 tbr, 15 tbn, 15 tbc
Stream mapping:
  Stream #0:0 -> #0:0 (mpeg4 (native) -> h264 (h264_vaapi))
Press [q] to stop, [?] for help
Impossible to convert between the formats supported by the filter 'Parsed_null_0' and the filter 'auto_scaler_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented
Error while processing the decoded data for stream #0:0
Conversion failed!

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

André Hänsel
In reply to this post by Carl Eugen Hoyos-2
> > How should I go about debugging this further?
>
> First step is to provide the command line you tested together
> with the complete, uncut console output.
>
> Carl Eugen

See below for another console output, this time with loglevel "trace".

I noticed this line:

[mpeg4 @ 0x555f040fe2e0] Codec mpeg4 profile 0 not supported for hardware decode.

So it seems it falls back silently to software decoding, so I need an hwupload filter?

Here's the trace output:

# ffmpeg -loglevel trace -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i test.avi -c:v h264_vaapi out.mp4
ffmpeg version 3.3.1-1~16.04.york0 Copyright (c) 2000-2017 the FFmpeg developers
  built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.4) 20160609
  configuration: --prefix=/usr --extra-version='1~16.04.york0' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
  libavutil      55. 58.100 / 55. 58.100
  libavcodec     57. 89.100 / 57. 89.100
  libavformat    57. 71.100 / 57. 71.100
  libavdevice    57.  6.100 / 57.  6.100
  libavfilter     6. 82.100 /  6. 82.100
  libavresample   3.  5.  0 /  3.  5.  0
  libswscale      4.  6.100 /  4.  6.100
  libswresample   2.  7.100 /  2.  7.100
  libpostproc    54.  5.100 / 54.  5.100
Splitting the commandline.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging level) with argument 'trace'.
Reading option '-hwaccel' ... matched as option 'hwaccel' (use HW accelerated decoding) with argument 'vaapi'.
Reading option '-vaapi_device' ... matched as option 'vaapi_device' (set VAAPI hardware device (DRM path or X11 display name)) with argument '/dev/dri/renderD128'.
Reading option '-hwaccel_output_format' ... matched as option 'hwaccel_output_format' (select output format used with HW accelerated decoding) with argument 'vaapi'.
Reading option '-i' ... matched as input url with argument 'test.avi'.
Reading option '-c:v' ... matched as option 'c' (codec name) with argument 'h264_vaapi'.
Reading option 'out.mp4' ... matched as output url.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option loglevel (set logging level) with argument trace.
Applying option vaapi_device (set VAAPI hardware device (DRM path or X11 display name)) with argument /dev/dri/renderD128.
[AVHWDeviceContext @ 0x555f040d7740] Opened VA display via DRM device /dev/dri/renderD128.
libva info: VA-API version 0.39.4
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_0_39
libva info: va_openDriver() returns 0
[AVHWDeviceContext @ 0x555f040d7740] Initialised VAAPI connection: version 0.39
[AVHWDeviceContext @ 0x555f040d7740] Format 0x32315659 -> yuv420p.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x30323449 -> unknown.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x3231564e -> nv12.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x32595559 -> yuyv422.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x59565955 -> uyvy422.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x48323234 -> yuv422p.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x58424752 -> rgb0.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x58524742 -> bgr0.
[AVHWDeviceContext @ 0x555f040d7740] Format 0x30313050 -> p010le.
[AVHWDeviceContext @ 0x555f040d7740] Matched "Intel i965 driver for Intel(R) Haswell Mobile - 1.7.0" as known driver "Intel i965 (Quick Sync)".
Successfully parsed a group of options.
Parsing a group of options: input url test.avi.
Applying option hwaccel (use HW accelerated decoding) with argument vaapi.
Applying option hwaccel_output_format (select output format used with HW accelerated decoding) with argument vaapi.
Successfully parsed a group of options.
Opening an input file: test.avi.
[file @ 0x555f040e24a0] Setting default whitelist 'file,crypto'
Probing avi score:100 size:2048
[avi @ 0x555f040e1e80] Format avi probed with size=2048 and score=100
[avi @ 0x555f040e2660] use odml:1
pos:14 tag: tag=LIST size=0x121c
pos:18 list: tag=hdrl size=0x0
pos:20 tag: tag=avih size=0x38
pos:60 tag: tag=LIST size=0x10c4
pos:64 list: tag=strl size=0x0
pos:6C tag: tag=strh size=0x38
pos:74 strh: tag=vids size=0xffffffff
[avi @ 0x555f040e1e80] 15 1 0
pos:AC tag: tag=strf size=0x58
pos:104 video: tag=FMP4 size=0x0
pos:10C tag: tag=JUNK size=0x1018
pos:112C tag: tag=JUNK size=0x104
pos:1238 tag: tag=LIST size=0x1a
pos:123C list: tag=INFO size=0x0
pos:125A tag: tag=JUNK size=0x3f8
pos:165A tag: tag=LIST size=0x2a4f68
pos:165E list: tag=movi size=0x0
movi end=2a65c2
[avi @ 0x555f040e1e80] movi_end=0x2a65c2
[avi @ 0x555f040e1e80] 0: tag=0x63643030 flags=0x10 pos=0x4 len=231579/231579 cum_len=0
[avi @ 0x555f040e1e80] 1: tag=0x63643030 flags=0x0 pos=0x388a8 len=22165/22165 cum_len=1
[avi @ 0x555f040e1e80] 2: tag=0x63643030 flags=0x0 pos=0x3df46 len=0/0 cum_len=2
[avi @ 0x555f040e1e80] 3: tag=0x63643030 flags=0x0 pos=0x3df4e len=0/0 cum_len=3
[avi @ 0x555f040e1e80] 4: tag=0x63643030 flags=0x0 pos=0x3df56 len=0/0 cum_len=4
[avi @ 0x555f040e1e80] 5: tag=0x63643030 flags=0x0 pos=0x3df5e len=0/0 cum_len=5
[avi @ 0x555f040e1e80] 6: tag=0x63643030 flags=0x0 pos=0x3df66 len=32778/32778 cum_len=6
[avi @ 0x555f040e1e80] 7: tag=0x63643030 flags=0x0 pos=0x45f78 len=17987/17987 cum_len=7
[avi @ 0x555f040e1e80] 8: tag=0x63643030 flags=0x0 pos=0x4a5c4 len=0/0 cum_len=8
[avi @ 0x555f040e1e80] 9: tag=0x63643030 flags=0x0 pos=0x4a5cc len=0/0 cum_len=9
[avi @ 0x555f040e1e80] 10: tag=0x63643030 flags=0x0 pos=0x4a5d4 len=28307/28307 cum_len=10
[avi @ 0x555f040e1e80] 11: tag=0x63643030 flags=0x0 pos=0x51470 len=0/0 cum_len=11
[avi @ 0x555f040e1e80] 12: tag=0x63643030 flags=0x0 pos=0x51478 len=24203/24203 cum_len=12
[avi @ 0x555f040e1e80] 13: tag=0x63643030 flags=0x0 pos=0x5730c len=0/0 cum_len=13
[avi @ 0x555f040e1e80] 14: tag=0x63643030 flags=0x0 pos=0x57314 len=0/0 cum_len=14
[avi @ 0x555f040e1e80] 15: tag=0x63643030 flags=0x0 pos=0x5731c len=0/0 cum_len=15
[avi @ 0x555f040e1e80] 16: tag=0x63643030 flags=0x0 pos=0x57324 len=0/0 cum_len=16
[avi @ 0x555f040e1e80] 17: tag=0x63643030 flags=0x0 pos=0x5732c len=0/0 cum_len=17
[avi @ 0x555f040e1e80] 18: tag=0x63643030 flags=0x0 pos=0x57334 len=0/0 cum_len=18
[avi @ 0x555f040e1e80] 19: tag=0x63643030 flags=0x0 pos=0x5733c len=95111/95111 cum_len=19
[avi @ 0x555f040e1e80] 20: tag=0x63643030 flags=0x0 pos=0x6e6cc len=0/0 cum_len=20
[avi @ 0x555f040e1e80] 21: tag=0x63643030 flags=0x10 pos=0x6e6d4 len=236118/236118 cum_len=21
[avi @ 0x555f040e1e80] 22: tag=0x63643030 flags=0x0 pos=0xa8132 len=0/0 cum_len=22
[avi @ 0x555f040e1e80] 23: tag=0x63643030 flags=0x0 pos=0xa813a len=0/0 cum_len=23
[avi @ 0x555f040e1e80] 24: tag=0x63643030 flags=0x0 pos=0xa8142 len=0/0 cum_len=24
[avi @ 0x555f040e1e80] 25: tag=0x63643030 flags=0x0 pos=0xa814a len=43468/43468 cum_len=25
[avi @ 0x555f040e1e80] 26: tag=0x63643030 flags=0x0 pos=0xb2b1e len=0/0 cum_len=26
[avi @ 0x555f040e1e80] 27: tag=0x63643030 flags=0x0 pos=0xb2b26 len=0/0 cum_len=27
[avi @ 0x555f040e1e80] 28: tag=0x63643030 flags=0x0 pos=0xb2b2e len=93287/93287 cum_len=28
[avi @ 0x555f040e1e80] 29: tag=0x63643030 flags=0x0 pos=0xc979e len=0/0 cum_len=29
[avi @ 0x555f040e1e80] 30: tag=0x63643030 flags=0x10 pos=0xc97a6 len=236053/236053 cum_len=30
[avi @ 0x555f040e1e80] 31: tag=0x63643030 flags=0x0 pos=0x1031c4 len=0/0 cum_len=31
[avi @ 0x555f040e1e80] 32: tag=0x63643030 flags=0x0 pos=0x1031cc len=32874/32874 cum_len=32
[avi @ 0x555f040e1e80] 33: tag=0x63643030 flags=0x0 pos=0x10b23e len=0/0 cum_len=33
[avi @ 0x555f040e1e80] 34: tag=0x63643030 flags=0x0 pos=0x10b246 len=0/0 cum_len=34
[avi @ 0x555f040e1e80] 35: tag=0x63643030 flags=0x0 pos=0x10b24e len=0/0 cum_len=35
[avi @ 0x555f040e1e80] 36: tag=0x63643030 flags=0x0 pos=0x10b256 len=0/0 cum_len=36
[avi @ 0x555f040e1e80] 37: tag=0x63643030 flags=0x0 pos=0x10b25e len=0/0 cum_len=37
[avi @ 0x555f040e1e80] 38: tag=0x63643030 flags=0x0 pos=0x10b266 len=0/0 cum_len=38
[avi @ 0x555f040e1e80] 39: tag=0x63643030 flags=0x0 pos=0x10b26e len=42873/42873 cum_len=39
[avi @ 0x555f040e1e80] 40: tag=0x63643030 flags=0x0 pos=0x1159f0 len=0/0 cum_len=40
[avi @ 0x555f040e1e80] 41: tag=0x63643030 flags=0x0 pos=0x1159f8 len=26925/26925 cum_len=41
[avi @ 0x555f040e1e80] 42: tag=0x63643030 flags=0x0 pos=0x11c32e len=0/0 cum_len=42
[avi @ 0x555f040e1e80] 43: tag=0x63643030 flags=0x0 pos=0x11c336 len=0/0 cum_len=43
[avi @ 0x555f040e1e80] 44: tag=0x63643030 flags=0x0 pos=0x11c33e len=0/0 cum_len=44
[avi @ 0x555f040e1e80] 45: tag=0x63643030 flags=0x0 pos=0x11c346 len=95174/95174 cum_len=45
[avi @ 0x555f040e1e80] 46: tag=0x63643030 flags=0x0 pos=0x133714 len=0/0 cum_len=46
[avi @ 0x555f040e1e80] 47: tag=0x63643030 flags=0x0 pos=0x13371c len=33831/33831 cum_len=47
[avi @ 0x555f040e1e80] 48: tag=0x63643030 flags=0x0 pos=0x13bb4c len=0/0 cum_len=48
[avi @ 0x555f040e1e80] 49: tag=0x63643030 flags=0x0 pos=0x13bb54 len=0/0 cum_len=49
[avi @ 0x555f040e1e80] 50: tag=0x63643030 flags=0x0 pos=0x13bb5c len=0/0 cum_len=50
[avi @ 0x555f040e1e80] 51: tag=0x63643030 flags=0x0 pos=0x13bb64 len=0/0 cum_len=51
[avi @ 0x555f040e1e80] 52: tag=0x63643030 flags=0x0 pos=0x13bb6c len=0/0 cum_len=52
[avi @ 0x555f040e1e80] 53: tag=0x63643030 flags=0x0 pos=0x13bb74 len=45765/45765 cum_len=53
[avi @ 0x555f040e1e80] 54: tag=0x63643030 flags=0x0 pos=0x146e42 len=0/0 cum_len=54
[avi @ 0x555f040e1e80] 55: tag=0x63643030 flags=0x10 pos=0x146e4a len=235326/235326 cum_len=55
[avi @ 0x555f040e1e80] 56: tag=0x63643030 flags=0x0 pos=0x180590 len=0/0 cum_len=56
[avi @ 0x555f040e1e80] 57: tag=0x63643030 flags=0x0 pos=0x180598 len=0/0 cum_len=57
[avi @ 0x555f040e1e80] 58: tag=0x63643030 flags=0x0 pos=0x1805a0 len=0/0 cum_len=58
[avi @ 0x555f040e1e80] 59: tag=0x63643030 flags=0x0 pos=0x1805a8 len=0/0 cum_len=59
[avi @ 0x555f040e1e80] 60: tag=0x63643030 flags=0x0 pos=0x1805b0 len=108513/108513 cum_len=60
[avi @ 0x555f040e1e80] 61: tag=0x63643030 flags=0x0 pos=0x19ad9a len=0/0 cum_len=61
[avi @ 0x555f040e1e80] 62: tag=0x63643030 flags=0x0 pos=0x19ada2 len=0/0 cum_len=62
[avi @ 0x555f040e1e80] 63: tag=0x63643030 flags=0x0 pos=0x19adaa len=37833/37833 cum_len=63
[avi @ 0x555f040e1e80] 64: tag=0x63643030 flags=0x0 pos=0x1a417c len=0/0 cum_len=64
[avi @ 0x555f040e1e80] 65: tag=0x63643030 flags=0x0 pos=0x1a4184 len=0/0 cum_len=65
[avi @ 0x555f040e1e80] 66: tag=0x63643030 flags=0x0 pos=0x1a418c len=0/0 cum_len=66
[avi @ 0x555f040e1e80] 67: tag=0x63643030 flags=0x0 pos=0x1a4194 len=0/0 cum_len=67
[avi @ 0x555f040e1e80] 68: tag=0x63643030 flags=0x0 pos=0x1a419c len=0/0 cum_len=68
[avi @ 0x555f040e1e80] 69: tag=0x63643030 flags=0x0 pos=0x1a41a4 len=43723/43723 cum_len=69
[avi @ 0x555f040e1e80] 70: tag=0x63643030 flags=0x0 pos=0x1aec78 len=0/0 cum_len=70
[avi @ 0x555f040e1e80] 71: tag=0x63643030 flags=0x0 pos=0x1aec80 len=0/0 cum_len=71
[avi @ 0x555f040e1e80] 72: tag=0x63643030 flags=0x0 pos=0x1aec88 len=0/0 cum_len=72
[avi @ 0x555f040e1e80] 73: tag=0x63643030 flags=0x0 pos=0x1aec90 len=0/0 cum_len=73
[avi @ 0x555f040e1e80] 74: tag=0x63643030 flags=0x0 pos=0x1aec98 len=98125/98125 cum_len=74
[avi @ 0x555f040e1e80] 75: tag=0x63643030 flags=0x0 pos=0x1c6bee len=0/0 cum_len=75
[avi @ 0x555f040e1e80] 76: tag=0x63643030 flags=0x0 pos=0x1c6bf6 len=0/0 cum_len=76
[avi @ 0x555f040e1e80] 77: tag=0x63643030 flags=0x0 pos=0x1c6bfe len=39985/39985 cum_len=77
[avi @ 0x555f040e1e80] 78: tag=0x63643030 flags=0x0 pos=0x1d0838 len=0/0 cum_len=78
[avi @ 0x555f040e1e80] 79: tag=0x63643030 flags=0x0 pos=0x1d0840 len=0/0 cum_len=79
[avi @ 0x555f040e1e80] 80: tag=0x63643030 flags=0x0 pos=0x1d0848 len=0/0 cum_len=80
[avi @ 0x555f040e1e80] 81: tag=0x63643030 flags=0x0 pos=0x1d0850 len=39045/39045 cum_len=81
[avi @ 0x555f040e1e80] 82: tag=0x63643030 flags=0x0 pos=0x1da0de len=0/0 cum_len=82
[avi @ 0x555f040e1e80] 83: tag=0x63643030 flags=0x0 pos=0x1da0e6 len=0/0 cum_len=83
[avi @ 0x555f040e1e80] 84: tag=0x63643030 flags=0x0 pos=0x1da0ee len=0/0 cum_len=84
[avi @ 0x555f040e1e80] 85: tag=0x63643030 flags=0x0 pos=0x1da0f6 len=0/0 cum_len=85
[avi @ 0x555f040e1e80] 86: tag=0x63643030 flags=0x10 pos=0x1da0fe len=230537/230537 cum_len=86
[avi @ 0x555f040e1e80] 87: tag=0x63643030 flags=0x0 pos=0x212590 len=0/0 cum_len=87
[avi @ 0x555f040e1e80] 88: tag=0x63643030 flags=0x0 pos=0x212598 len=0/0 cum_len=88
[avi @ 0x555f040e1e80] 89: tag=0x63643030 flags=0x0 pos=0x2125a0 len=29478/29478 cum_len=89
[avi @ 0x555f040e1e80] 90: tag=0x63643030 flags=0x0 pos=0x2198ce len=0/0 cum_len=90
[avi @ 0x555f040e1e80] 91: tag=0x63643030 flags=0x0 pos=0x2198d6 len=0/0 cum_len=91
[avi @ 0x555f040e1e80] 92: tag=0x63643030 flags=0x0 pos=0x2198de len=99591/99591 cum_len=92
[avi @ 0x555f040e1e80] 93: tag=0x63643030 flags=0x0 pos=0x231dee len=0/0 cum_len=93
[avi @ 0x555f040e1e80] 94: tag=0x63643030 flags=0x0 pos=0x231df6 len=0/0 cum_len=94
[avi @ 0x555f040e1e80] 95: tag=0x63643030 flags=0x0 pos=0x231dfe len=34881/34881 cum_len=95
[avi @ 0x555f040e1e80] 96: tag=0x63643030 flags=0x0 pos=0x23a648 len=0/0 cum_len=96
[avi @ 0x555f040e1e80] 97: tag=0x63643030 flags=0x0 pos=0x23a650 len=0/0 cum_len=97
[avi @ 0x555f040e1e80] 98: tag=0x63643030 flags=0x0 pos=0x23a658 len=0/0 cum_len=98
[avi @ 0x555f040e1e80] 99: tag=0x63643030 flags=0x0 pos=0x23a660 len=0/0 cum_len=99
[avi @ 0x555f040e1e80] 100: tag=0x63643030 flags=0x0 pos=0x23a668 len=0/0 cum_len=100
[avi @ 0x555f040e1e80] 101: tag=0x63643030 flags=0x0 pos=0x23a670 len=49046/49046 cum_len=101
[avi @ 0x555f040e1e80] 102: tag=0x63643030 flags=0x0 pos=0x24660e len=0/0 cum_len=102
[avi @ 0x555f040e1e80] 103: tag=0x63643030 flags=0x0 pos=0x246616 len=0/0 cum_len=103
[avi @ 0x555f040e1e80] 104: tag=0x63643030 flags=0x0 pos=0x24661e len=0/0 cum_len=104
[avi @ 0x555f040e1e80] 105: tag=0x63643030 flags=0x0 pos=0x246626 len=0/0 cum_len=105
[avi @ 0x555f040e1e80] 106: tag=0x63643030 flags=0x0 pos=0x24662e len=95747/95747 cum_len=106
[avi @ 0x555f040e1e80] 107: tag=0x63643030 flags=0x0 pos=0x25dc3a len=0/0 cum_len=107
[avi @ 0x555f040e1e80] 108: tag=0x63643030 flags=0x0 pos=0x25dc42 len=27837/27837 cum_len=108
[avi @ 0x555f040e1e80] 109: tag=0x63643030 flags=0x0 pos=0x264908 len=0/0 cum_len=109
[avi @ 0x555f040e1e80] 110: tag=0x63643030 flags=0x0 pos=0x264910 len=0/0 cum_len=110
[avi @ 0x555f040e1e80] 111: tag=0x63643030 flags=0x0 pos=0x264918 len=0/0 cum_len=111
[avi @ 0x555f040e1e80] 112: tag=0x63643030 flags=0x0 pos=0x264920 len=0/0 cum_len=112
[avi @ 0x555f040e1e80] 113: tag=0x63643030 flags=0x10 pos=0x264928 len=226170/226170 cum_len=113
[avi @ 0x555f040e1e80] 114: tag=0x63643030 flags=0x0 pos=0x29bcaa len=0/0 cum_len=114
[avi @ 0x555f040e1e80] 115: tag=0x63643030 flags=0x0 pos=0x29bcb2 len=0/0 cum_len=115
[avi @ 0x555f040e1e80] 116: tag=0x63643030 flags=0x0 pos=0x29bcba len=37541/37541 cum_len=116
[avi @ 0x555f040e1e80] Before avformat_find_stream_info() pos: 5726 bytes read:102056 seeks:4 nb_streams:1
[avi @ 0x555f040e1e80] All info found
[avi @ 0x555f040e1e80] stream 0: start_time: 0.000 duration: 7.800
[avi @ 0x555f040e1e80] format: start_time: 0.000 duration: 7.800 bitrate=2851 kb/s
[avi @ 0x555f040e1e80] After avformat_find_stream_info() pos: 237313 bytes read:300875 seeks:4 frames:1
Input #0, avi, from 'test.avi':
  Metadata:
    encoder         : Lavf56.40.101
  Duration: 00:00:07.80, start: 0.000000, bitrate: 2851 kb/s
    Stream #0:0, 1, 1/15: Video: mpeg4 (Simple Profile), 1 reference frame (FMP4 / 0x34504D46), yuv420p(left), 1920x1080 [SAR 1:1 DAR 16:9], 0/1, 2867 kb/s, 15 fps, 15 tbr, 15 tbn, 15 tbc
Successfully opened the file.
Parsing a group of options: output url out.mp4.
Applying option c:v (codec name) with argument h264_vaapi.
Successfully parsed a group of options.
Opening an output file: out.mp4.
[file @ 0x555f040f5b80] Setting default whitelist 'file,crypto'
Successfully opened the file.
detected 2 logical cores
Stream mapping:
  Stream #0:0 -> #0:0 (mpeg4 (native) -> h264 (h264_vaapi))
Press [q] to stop, [?] for help
cur_dts is invalid (this is harmless if it occurs once at the start per stream)
    Last message repeated 1 times
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000000.
[AVHWFramesContext @ 0x7f1aa8000a60] Direct mapping possible.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000001.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000002.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000003.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000004.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000005.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000006.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000007.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000008.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000009.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000a.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000b.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000c.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000d.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000e.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x400000f.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000010.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000011.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000012.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000013.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000014.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000015.
[AVHWFramesContext @ 0x7f1aa8000a60] Created surface 0x4000016.
[mpeg4 @ 0x555f040fe2e0] Codec mpeg4 profile 0 not supported for hardware decode.
cur_dts is invalid (this is harmless if it occurs once at the start per stream)
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'video_size' to value '1920x1080'
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'pix_fmt' to value '0'
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'time_base' to value '1/15'
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'pixel_aspect' to value '1/1'
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'sws_param' to value 'flags=2'
[graph 0 input from stream 0:0 @ 0x555f0475be80] Setting 'frame_rate' to value '15/1'
[graph 0 input from stream 0:0 @ 0x555f0475be80] w:1920 h:1080 pixfmt:yuv420p tb:1/15 fr:15/1 sar:1/1 sws_param:flags=2
[format @ 0x555f0475c620] compat: called with args=[vaapi_vld]
[format @ 0x555f0475c620] Setting 'pix_fmts' to value 'vaapi_vld'
[auto_scaler_0 @ 0x555f0475c500] Setting 'flags' to value 'bicubic'
[auto_scaler_0 @ 0x555f0475c500] w:iw h:ih flags:'bicubic' interl:0
[format @ 0x555f0475c620] auto-inserting filter 'auto_scaler_0' between the filter 'Parsed_null_0' and the filter 'format'
Impossible to convert between the formats supported by the filter 'Parsed_null_0' and the filter 'auto_scaler_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented
Error while processing the decoded data for stream #0:0
[AVIOContext @ 0x555f040f50c0] Statistics: 0 seeks, 0 writeouts
[AVIOContext @ 0x555f040ea760] Statistics: 366411 bytes read, 4 seeks
Conversion failed!

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Carl Eugen Hoyos-2
2018-06-13 13:26 GMT+02:00, André Hänsel <[hidden email]>:

>> > How should I go about debugging this further?
>>
>> First step is to provide the command line you tested together
>> with the complete, uncut console output.
>>
>> Carl Eugen
>
> See below for another console output, this time with loglevel "trace".
>
> I noticed this line:
>
> [mpeg4 @ 0x555f040fe2e0] Codec mpeg4 profile 0 not supported for hardware
> decode.
>
> So it seems it falls back silently to software decoding, so I need an
> hwupload filter?
>
> Here's the trace output:
>
> # ffmpeg -loglevel trace -hwaccel vaapi -vaapi_device /dev/dri/renderD128
> -hwaccel_output_format vaapi -i test.avi -c:v h264_vaapi out.mp4
> ffmpeg version 3.3.1-1~16.04.york0

I hoped that one of the vaapi developers would comment but in
any case, you should test current FFmpeg git head, many changes
(including to vaapi) have been made in the last year.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Mark Thompson
In reply to this post by André Hänsel
On 13/06/18 11:29, André Hänsel wrote:

> I'm trying to transcode an MPEG4 avi to MP4 with VAAPI, but I'm getting an
> error:
>
> Impossible to convert between the formats supported by the filter
> 'Parsed_null_0' and the filter 'auto_scaler_0'
> Error reinitializing filters!
> Failed to inject frame into filter network: Function not implemented
>
> The failing command is:
> ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
> -hwaccel_output_format vaapi -i test.avi -c:v h264_vaapi out.mp4
>
> Other combinations work just fine, like hardware decoding that same video:
> ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -i test.avi -c:v
> libx264 out.mp4
>
> Hardware transcoding an MPEG2 input video works fine as well:
> ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
> -hwaccel_output_format vaapi -i test.mpg -c:v h264_vaapi out.mp4
>
> Hardware transcoding an H264 video works, too:
> ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128
> -hwaccel_output_format vaapi -i test.mp4 -c:v h264_vaapi out.mp4
>
> How should I go about debugging this further?

Intel devices do not support MPEG-4 part 2 at all.  If you are using the Mesa driver on an AMD device, some MPEG-4 part 2 streams may be supported if you set the environment variable VAAPI_MPEG4_ENABLED to 1, but it's not enabled by default because the implementation is incomplete due to API constraints.

For encoding of streams which may be decoded in hardware or software (but you don't know in advance), see <https://trac.ffmpeg.org/wiki/Hardware/VAAPI#Encoding> - in particular, something like the third example command in that section is probably what you want.

- Mark
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Carl Eugen Hoyos-2
2018-06-17 22:00 GMT+02:00, Mark Thompson <[hidden email]>:

> Intel devices do not support MPEG-4 part 2 at all.  If you are using
> the Mesa driver on an AMD device, some MPEG-4 part 2 streams
> may be supported if you set the environment variable
> VAAPI_MPEG4_ENABLED to 1, but it's not enabled by default
> because the implementation is incomplete due to API constraints.

I know this mail isn't helpful but reading above and remembering how
nice vdpau worked (already) many years ago and remembering how
people said at the time that vaapi is much superior over vdpau I still
wonder if we (FFmpeg) shouldn't have fought vaapi much stronger...

Sorry for the rant, Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Mark Thompson
On 17/06/18 21:30, Carl Eugen Hoyos wrote:

> 2018-06-17 22:00 GMT+02:00, Mark Thompson <[hidden email]>:
>
>> Intel devices do not support MPEG-4 part 2 at all.  If you are using
>> the Mesa driver on an AMD device, some MPEG-4 part 2 streams
>> may be supported if you set the environment variable
>> VAAPI_MPEG4_ENABLED to 1, but it's not enabled by default
>> because the implementation is incomplete due to API constraints.
>
> I know this mail isn't helpful but reading above and remembering how
> nice vdpau worked (already) many years ago and remembering how
> people said at the time that vaapi is much superior over vdpau I still
> wonder if we (FFmpeg) shouldn't have fought vaapi much stronger...

I doubt it would be particularly hard to make it work.  Since Intel didn't implement MPEG-4 part 2 on their supported devices they just cobbled together some set of stream/frame properties which looked sufficient for decoding and  made that the API.  When AMD / Mesa tried to implement it they made some of it work but found that the API was incomplete, and then they gave up.  If you (or anyone else, including AMD) wants it to work then it would be straightforward (if somewhat tedious) to add the necessary properties to VAAPI / libva to get to the point that it matches the working VDPAU behaviour.

- Mark
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

Carl Eugen Hoyos-2
2018-06-17 22:44 GMT+02:00, Mark Thompson <[hidden email]>:

> On 17/06/18 21:30, Carl Eugen Hoyos wrote:
>> 2018-06-17 22:00 GMT+02:00, Mark Thompson <[hidden email]>:
>>
>>> Intel devices do not support MPEG-4 part 2 at all.  If you are using
>>> the Mesa driver on an AMD device, some MPEG-4 part 2 streams
>>> may be supported if you set the environment variable
>>> VAAPI_MPEG4_ENABLED to 1, but it's not enabled by default
>>> because the implementation is incomplete due to API constraints.
>>
>> I know this mail isn't helpful but reading above and remembering how
>> nice vdpau worked (already) many years ago and remembering how
>> people said at the time that vaapi is much superior over vdpau I still
>> wonder if we (FFmpeg) shouldn't have fought vaapi much stronger...
>
> I doubt it would be particularly hard to make it work.  Since Intel didn't
> implement MPEG-4 part 2 on their supported devices they just cobbled
> together some set of stream/frame properties which looked sufficient for
> decoding and made that the API.  When AMD / Mesa tried to implement
> it they made some of it work but found that the API was incomplete, and
> then they gave up. If you (or anyone else, including AMD) wants it to
> work then it would be straightforward (if somewhat tedious) to add the
> necessary properties to VAAPI / libva to get to the point that it matches
> the working VDPAU behaviour.

Sadly that would be far above my capabilities.

Again, sorry for the rant, I am happy for everybody who can use vaapi.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: vaapi: Impossible to convert between the formats

André Hänsel
In reply to this post by Mark Thompson
> Intel devices do not support MPEG-4 part 2 at all.

Then it's clear and no problem at all. May I suggest bumping the loglevel of

[mpeg4 @ 0x555f040fe2e0] Codec mpeg4 profile 0 not supported for hardware decode.

to at least "info", if not "warning"? Then it would have known immediately what the problem was.

_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".