From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ@public.gmane.org Subject: [Bug 110679] New: va-api scaling with nv50-class cards incomplete? Date: Wed, 15 May 2019 05:51:41 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1662467974==" Return-path: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: nouveau-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Sender: "Nouveau" To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org List-Id: nouveau.vger.kernel.org --===============1662467974== Content-Type: multipart/alternative; boundary="15578995010.3dcFbdEB.26563" Content-Transfer-Encoding: 7bit --15578995010.3dcFbdEB.26563 Date: Wed, 15 May 2019 05:51:40 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated https://bugs.freedesktop.org/show_bug.cgi?id=3D110679 Bug ID: 110679 Summary: va-api scaling with nv50-class cards incomplete? Product: Mesa Version: git Hardware: x86 (IA32) OS: Linux (All) Status: NEW Severity: normal Priority: medium Component: Drivers/DRI/nouveau Assignee: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Reporter: randrik-JGs/UdohzUI@public.gmane.org QA Contact: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Created attachment 144278 --> https://bugs.freedesktop.org/attachment.cgi?id=3D144278&action=3Dedit ffmpeg's output and command line Hello! I was trying to find answer to 'good ffmpeg commandline showing how to use scale_vaapi filter' [1], but unfortunately none of my attempts worked for = me :/ Mesa/va state tarcker: glxinfo | grep OpenGL OpenGL vendor string: nouveau OpenGL renderer string: NV92 OpenGL core profile version string: 3.3 (Core Profile) Mesa 19.2.0-devel (git-4fd8161773) OpenGL core profile shading language version string: 3.30 OpenGL core profile context flags: (none) OpenGL core profile profile mask: core profile OpenGL core profile extensions: OpenGL version string: 3.3 (Compatibility Profile) Mesa 19.2.0-devel (git-4fd8161773) OpenGL shading language version string: 3.30 OpenGL context flags: (none) OpenGL profile mask: compatibility profile OpenGL extensions: OpenGL ES profile version string: OpenGL ES 3.0 Mesa 19.2.0-devel (git-4fd8161773) OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.00 OpenGL ES profile extensions: vainfo: vainfo libva info: VA-API version 0.40.0 libva info: va_getDriverName() returns 0 libva info: Trying to open /usr/X11R7/lib/dri/nouveau_drv_video.so libva info: Found init function __vaDriverInit_0_40 libva info: va_openDriver() returns 0 vainfo: VA-API version: 0.40 (libva ) vainfo: Driver version: Mesa Gallium driver 19.2.0-devel for NV92 vainfo: Supported profile and entrypoints VAProfileMPEG2Simple : VAEntrypointVLD VAProfileMPEG2Simple : VAEntrypointEncSlice VAProfileMPEG2Main : VAEntrypointVLD VAProfileMPEG2Main : VAEntrypointEncSlice VAProfileNone : VAEntrypointVideoProc First, I think EncSlice lines are invalid (or mesa can magically (shaders?) _encode_ mpeg2 videos?) Second .. ffmpeg command failed for me :/ ffmpeg -vaapi_device /dev/dri/renderD128 -benchmark -c:v libdav1d -i /mnt/sdb1/Stream2_AV1_720p_3.2mbps.webm -vf format=3Dnv12,hwupload,scale_vaapi=3Dw=3D240:h=3D120 -map 0:v:0 -v trace -f= null - ffmpeg version N-93862-gf49cec2ba8 Copyright (c) 2000-2019 the FFmpeg developers built with gcc 5.5.0 (GCC) [skip] Applying option vaapi_device (set VAAPI hardware device (DRM path or X11 display name)) with argument /dev/dri/renderD128. [AVHWDeviceContext @ 0xaef7d00] Opened VA display via DRM device /dev/dri/renderD128. libva info: VA-API version 0.40.0 libva info: va_getDriverName() returns 0 libva info: Trying to open /usr/X11R7/lib/dri/nouveau_drv_video.so libva info: Found init function __vaDriverInit_0_40 libva info: va_openDriver() returns 0 [AVHWDeviceContext @ 0xaef7d00] Initialised VAAPI connection: version 0.40 [AVHWDeviceContext @ 0xaef7d00] Format 0x3231564e -> nv12. [AVHWDeviceContext @ 0xaef7d00] Format 0x30313050 -> p010le. [AVHWDeviceContext @ 0xaef7d00] Format 0x36313050 -> unknown. [AVHWDeviceContext @ 0xaef7d00] Format 0x32315659 -> yuv420p. [AVHWDeviceContext @ 0xaef7d00] Format 0x56595559 -> unknown. [AVHWDeviceContext @ 0xaef7d00] Format 0x59565955 -> uyvy422. [AVHWDeviceContext @ 0xaef7d00] Format 0x41524742 -> bgra. [AVHWDeviceContext @ 0xaef7d00] Format 0x41424752 -> rgba. [AVHWDeviceContext @ 0xaef7d00] Format 0x58524742 -> bgr0. [AVHWDeviceContext @ 0xaef7d00] Format 0x58424752 -> rgb0. [AVHWDeviceContext @ 0xaef7d00] VAAPI driver: Mesa Gallium driver 19.2.0-de= vel for NV92. [AVHWDeviceContext @ 0xaef7d00] Driver not found in known nonstandard list, using standard behaviour. [skip] [Parsed_format_0 @ 0xaf4dcc0] Setting 'pix_fmts' to value 'nv12' [Parsed_scale_vaapi_2 @ 0xb005a40] Setting 'w' to value '240' [Parsed_scale_vaapi_2 @ 0xb005a40] Setting 'h' to value '120' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'video_size' to value '1280x720' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'pix_fmt' to value '0' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'time_base' to value '1/1000' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'pixel_aspect' to value '1/1' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'sws_param' to value 'flags=3D2' [graph 0 input from stream 0:0 @ 0xb006300] Setting 'frame_rate' to value '25/1' [graph 0 input from stream 0:0 @ 0xb006300] w:1280 h:720 pixfmt:yuv420p tb:1/1000 fr:25/1 sar:1/1 sws_param:flags=3D2 [auto_scaler_0 @ 0xb007b40] Setting 'flags' to value 'bicubic' [auto_scaler_0 @ 0xb007b40] w:iw h:ih flags:'bicubic' interl:0 [Parsed_format_0 @ 0xaf4dcc0] auto-inserting filter 'auto_scaler_0' between= the filter 'graph 0 input from stream 0:0' and the filter 'Parsed_format_0' [AVFilterGraph @ 0xaf3ed00] query_formats: 5 queried, 3 merged, 1 already d= one, 0 delayed [auto_scaler_0 @ 0xb007b40] w:1280 h:720 fmt:yuv420p sar:1/1 -> w:1280 h:720 fmt:nv12 sar:1/1 flags:0x4 [hwupload @ 0xaf4e200] Surface format is nv12. [AVHWFramesContext @ 0xaf4e4c0] Created surface 0x1. [AVHWFramesContext @ 0xaf4e4c0] Direct mapping disabled: deriving image does not work: 1 (operation failed). [AVHWFramesContext @ 0xb08d2c0] Created surface 0x3. [AVHWFramesContext @ 0xb08d2c0] Direct mapping disabled: deriving image does not work: 1 (operation failed). [AVHWFramesContext @ 0xb08d2c0] Created surface 0x4. [AVHWFramesContext @ 0xb08d2c0] Created surface 0x5. [AVHWFramesContext @ 0xb08d2c0] Created surface 0x6. [AVHWFramesContext @ 0xb08d2c0] Created surface 0x7. [AVHWFramesContext @ 0xb08d2c0] Created surface 0x8. [AVHWFramesContext @ 0xb08d2c0] Created surface 0x9. [AVHWFramesContext @ 0xb08d2c0] Created surface 0xa. [AVHWFramesContext @ 0xb08d2c0] Created surface 0xb. [AVHWFramesContext @ 0xb08d2c0] Created surface 0xc. [AVHWFramesContext @ 0xaf4e4c0] Map surface 0x1. [AVHWFramesContext @ 0xaf4e4c0] Unmap surface 0x1. [Parsed_scale_vaapi_2 @ 0xb005a40] Filter input: vaapi_vld, 1280x720 (0). [Parsed_scale_vaapi_2 @ 0xb005a40] Using surface 0x1 for scale input. [Parsed_scale_vaapi_2 @ 0xb005a40] Using surface 0xc for scale output. [Parsed_scale_vaapi_2 @ 0xb005a40] Pipeline parameter buffer is 0xe. [Parsed_scale_vaapi_2 @ 0xb005a40] Failed to render parameter buffer: 2 (resource allocation failed). Error while filtering: Input/output error Failed to inject frame into filter network: Input/output error Error while processing the decoded data for stream #0:0 bench: maxrss=3D106420kB [AVIOContext @ 0xaf40640] Statistics: 759514 bytes read, 0 seeks Conversion failed! Ow :( [full log attached] Note, i use libva1: libva-1.8.3 Can libva2 be installed in parallel with libva1 ? [1] - https://lists.cinelerra-gg.org/pipermail/cin/2019-May/000665.html --=20 You are receiving this mail because: You are the assignee for the bug. You are the QA Contact for the bug.= --15578995010.3dcFbdEB.26563 Date: Wed, 15 May 2019 05:51:41 +0000 MIME-Version: 1.0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated
Bug ID 110679
Summary va-api scaling with nv50-class cards incomplete?
Product Mesa
Version git
Hardware x86 (IA32)
OS Linux (All)
Status NEW
Severity normal
Priority medium
Component Drivers/DRI/nouveau
Assignee nouveau@lists.freedesktop.org
Reporter randrik@mail.ru
QA Contact nouveau@lists.freedesktop.org

Created attachm=
ent 144278 [details]
ffmpeg's output and command line

Hello!

I was trying to find answer to 'good ffmpeg commandline showing how to use
scale_vaapi filter' [1], but unfortunately none of my attempts worked  for =
me
:/

Mesa/va state tarcker:
glxinfo | grep OpenGL
OpenGL vendor string: nouveau
OpenGL renderer string: NV92
OpenGL core profile version string: 3.3 (Core Profile) Mesa 19.2.0-devel
(git-4fd8161773)
OpenGL core profile shading language version string: 3.30
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.3 (Compatibility Profile) Mesa 19.2.0-devel
(git-4fd8161773)
OpenGL shading language version string: 3.30
OpenGL context flags: (none)
OpenGL profile mask: compatibility profile
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.0 Mesa 19.2.0-devel
(git-4fd8161773)
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.00
OpenGL ES profile extensions:


vainfo:
vainfo
libva info: VA-API version 0.40.0
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/X11R7/lib/dri/nouveau_drv_video.so
libva info: Found init function __vaDriverInit_0_40
libva info: va_openDriver() returns 0
vainfo: VA-API version: 0.40 (libva )
vainfo: Driver version: Mesa Gallium driver 19.2.0-devel for NV92
vainfo: Supported profile and entrypoints
      VAProfileMPEG2Simple            : VAEntrypointVLD
      VAProfileMPEG2Simple            : VAEntrypointEncSlice
      VAProfileMPEG2Main              : VAEntrypointVLD
      VAProfileMPEG2Main              : VAEntrypointEncSlice
      VAProfileNone                   : VAEntrypointVideoProc


First, I think EncSlice lines are invalid (or mesa can magically (shaders?)
_encode_ mpeg2 videos?)

Second .. ffmpeg command failed for me :/
ffmpeg -vaapi_device /dev/dri/renderD128 -benchmark -c:v libdav1d   -i
/mnt/sdb1/Stream2_AV1_720p_3.2mbps.webm  -vf
format=3Dnv12,hwupload,scale_vaapi=3Dw=3D240:h=3D120 -map 0:v:0 -v trace -f=
 null -
ffmpeg version N-93862-gf49cec2ba8 Copyright (c) 2000-2019 the FFmpeg
developers
  built with gcc 5.5.0 (GCC)

[skip]

Applying option vaapi_device (set VAAPI hardware device (DRM path or X11
display name)) with argument /dev/dri/renderD128.
[AVHWDeviceContext @ 0xaef7d00] Opened VA display via DRM device
/dev/dri/renderD128.
libva info: VA-API version 0.40.0
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/X11R7/lib/dri/nouveau_drv_video.so
libva info: Found init function __vaDriverInit_0_40
libva info: va_openDriver() returns 0
[AVHWDeviceContext @ 0xaef7d00] Initialised VAAPI connection: version 0=
.40
[AVHWDeviceContext @ 0xaef7d00] Format 0x3231564e -> nv12.
[AVHWDeviceContext @ 0xaef7d00] Format 0x30313050 -> p010le.
[AVHWDeviceContext @ 0xaef7d00] Format 0x36313050 -> unknown.
[AVHWDeviceContext @ 0xaef7d00] Format 0x32315659 -> yuv420p.
[AVHWDeviceContext @ 0xaef7d00] Format 0x56595559 -> unknown.
[AVHWDeviceContext @ 0xaef7d00] Format 0x59565955 -> uyvy422.
[AVHWDeviceContext @ 0xaef7d00] Format 0x41524742 -> bgra.
[AVHWDeviceContext @ 0xaef7d00] Format 0x41424752 -> rgba.
[AVHWDeviceContext @ 0xaef7d00] Format 0x58524742 -> bgr0.
[AVHWDeviceContext @ 0xaef7d00] Format 0x58424752 -> rgb0.
[AVHWDeviceContext @ 0xaef7d00] VAAPI driver: Mesa Gallium driver 19.2.=
0-devel
for NV92.
[AVHWDeviceContext @ 0xaef7d00] Driver not found in known nonstandard l=
ist,
using standard behaviour.

[skip]

[Parsed_format_0 @ 0xaf4dcc0] Setting 'pix_fmts' to value 'nv12'
[Parsed_scale_vaapi_2 @ 0xb005a40] Setting 'w' to value '240'
[Parsed_scale_vaapi_2 @ 0xb005a40] Setting 'h' to value '120'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'video_size' to val=
ue
'1280x720'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'pix_fmt' to value =
'0'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'time_base' to value
'1/1000'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'pixel_aspect' to v=
alue
'1/1'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'sws_param' to value
'flags=3D2'
[graph 0 input from stream 0:0 @ 0xb006300] Setting 'frame_rate' to val=
ue
'25/1'
[graph 0 input from stream 0:0 @ 0xb006300] w:1280 h:720 pixfmt:yuv420p
tb:1/1000 fr:25/1 sar:1/1 sws_param:flags=3D2
[auto_scaler_0 @ 0xb007b40] Setting 'flags' to value 'bicubic'
[auto_scaler_0 @ 0xb007b40] w:iw h:ih flags:'bicubic' interl:0
[Parsed_format_0 @ 0xaf4dcc0] auto-inserting filter 'auto_scaler_0' bet=
ween the
filter 'graph 0 input from stream 0:0' and the filter 'Parsed_format_0'
[AVFilterGraph @ 0xaf3ed00] query_formats: 5 queried, 3 merged, 1 alrea=
dy done,
0 delayed
[auto_scaler_0 @ 0xb007b40] w:1280 h:720 fmt:yuv420p sar:1/1 -> w:12=
80 h:720
fmt:nv12 sar:1/1 flags:0x4
[hwupload @ 0xaf4e200] Surface format is nv12.
[AVHWFramesContext @ 0xaf4e4c0] Created surface 0x1.
[AVHWFramesContext @ 0xaf4e4c0] Direct mapping disabled: deriving image=
 does
not work: 1 (operation failed).
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x3.
[AVHWFramesContext @ 0xb08d2c0] Direct mapping disabled: deriving image=
 does
not work: 1 (operation failed).
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x4.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x5.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x6.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x7.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x8.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0x9.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0xa.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0xb.
[AVHWFramesContext @ 0xb08d2c0] Created surface 0xc.
[AVHWFramesContext @ 0xaf4e4c0] Map surface 0x1.
[AVHWFramesContext @ 0xaf4e4c0] Unmap surface 0x1.
[Parsed_scale_vaapi_2 @ 0xb005a40] Filter input: vaapi_vld, 1280x720 (0=
).
[Parsed_scale_vaapi_2 @ 0xb005a40] Using surface 0x1 for scale input.
[Parsed_scale_vaapi_2 @ 0xb005a40] Using surface 0xc for scale output.
[Parsed_scale_vaapi_2 @ 0xb005a40] Pipeline parameter buffer is 0xe.
[Parsed_scale_vaapi_2 @ 0xb005a40] Failed to render parameter buffer: 2
(resource allocation failed).
Error while filtering: Input/output error
Failed to inject frame into filter network: Input/output error
Error while processing the decoded data for stream #0:0
bench: maxrss=3D106420kB
[AVIOContext @ 0xaf40640] Statistics: 759514 bytes read, 0 seeks
Conversion failed!

Ow :( [full log attached]

Note, i use libva1:

libva-1.8.3

Can libva2 be installed in parallel with libva1 ?

[1] - https://lists.cinelerra-gg.org/pipermail/cin/2019-May/000665.html<=
/a>


You are receiving this mail because:
  • You are the assignee for the bug.
  • You are the QA Contact for the bug.
= --15578995010.3dcFbdEB.26563-- --===============1662467974== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KTm91dmVhdSBt YWlsaW5nIGxpc3QKTm91dmVhdUBsaXN0cy5mcmVlZGVza3RvcC5vcmcKaHR0cHM6Ly9saXN0cy5m cmVlZGVza3RvcC5vcmcvbWFpbG1hbi9saXN0aW5mby9ub3V2ZWF1 --===============1662467974==--