<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<br>
<br>
<br>
<div class="moz-cite-prefix">Den 17.11.2024 11:53, skrev Andrew
Randrianasulu:<br>
</div>
<blockquote type="cite"
cite="mid:CA+rFky5oy1z5ZFwsapqSr-VOdZP53nn_O8te44f3CS_KoeaRxQ@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="auto">
<div><br>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">вс, 17 нояб. 2024 г.,
13:24 Terje J. Hanssen <<a
href="mailto:terjejhanssen@gmail.com"
moz-do-not-send="true" class="moz-txt-link-freetext">terjejhanssen@gmail.com</a>>:<br>
</div>
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div> <br>
<div>Den 16.11.2024 23:24, skrev Terje J. Hanssen:<br>
</div>
<blockquote type="cite"> <br>
<br>
<br>
<div>Den 16.11.2024 22:20, skrev Andrew Randrianasulu:<br>
</div>
<blockquote type="cite">
<div dir="auto">
<div><br>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">вс, 17 нояб.
2024 г., 00:02 Terje J. Hanssen <<a
href="mailto:terjejhanssen@gmail.com"
target="_blank" rel="noreferrer"
moz-do-not-send="true"
class="moz-txt-link-freetext">terjejhanssen@gmail.com</a>>:<br>
</div>
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div> <br>
<br>
<br>
<div>Den 16.11.2024 20:36, skrev Terje J.
Hanssen:<br>
</div>
<blockquote type="cite"> <br>
<br>
<br>
<div>Den 16.11.2024 19:00, skrev Andrew
Randrianasulu:<br>
</div>
<blockquote type="cite">
<div dir="auto">
<div><br>
<br>
<div class="gmail_quote">
<div dir="ltr"
class="gmail_attr">сб, 16
нояб. 2024 г., 20:56 Terje J.
Hanssen via Cin <<a
href="mailto:cin@lists.cinelerra-gg.org" rel="noreferrer noreferrer"
target="_blank"
moz-do-not-send="true"
class="moz-txt-link-freetext">cin@lists.cinelerra-gg.org</a>>:<br>
</div>
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div> Now when 10bit hevc_qsv
and hevc_vaapi accelerated
encoding looks to be in box,
I wonder if something
prohibits us to get
accelerated encoding for av1
and h264?<br>
</div>
</blockquote>
</div>
</div>
<div dir="auto"><br>
</div>
<div dir="auto">I think av1 was
complaining about invalid picture
structure?</div>
<div dir="auto"><br>
</div>
<div dir="auto"><br>
</div>
<div dir="auto">feel free to
experiment. You can also try vp9
....</div>
<div dir="auto"><br>
</div>
<div dir="auto"><br>
</div>
<div dir="auto">
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div> <br>
According to ffmpeg help the
following support should be
available:<br>
<br>
<font
face="Courier New, Courier, monospace">av1_qsv<br>
Supported pixel
formats: nv12 p010le qsv<br>
-profile
<int>
E..V....... (from 0 to
INT_MAX) (default unknown)<br>
unknown
0 E..V.......<br>
main
1 E..V.......<br>
<br>
av1_vaapi<br>
Supported pixel
formats: vaapi<br>
-profile
<int>
E..V....... Set profile
(seq_profile) (from -99 to
255) (default -99)<br>
main
0 E..V.......<br>
high
1 E..V.......<br>
professional
2 E..V.......<br>
</font></div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</blockquote>
<blockquote type="cite">
<blockquote type="cite">
<div dir="auto">
<div>
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<blockquote type="cite">
<blockquote type="cite">
<div dir="auto">
<div dir="auto">
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><font
face="Courier New, Courier, monospace">..........h264 snip</font></div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</blockquote>
<blockquote type="cite">
<blockquote type="cite">
<div dir="auto">
<div>
<div class="gmail_quote">
<blockquote class="gmail_quote"
style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<blockquote type="cite">
=============================<br>
<br>
Starting tests with<br>
<br>
/Cin # bin/cin<br>
Cinelerra Infinity - built: Nov 15 2024
20:29:14<br>
<br>
<br>
<font
face="Courier New, Courier, monospace">1)
AV1_QSV<br>
-----------<br>
</font><br>
<font
face="Courier New, Courier, monospace">av1_qsv.mp4<br>
</font>
<blockquote><font
face="Courier New, Courier, monospace">mp4 av1_qsv</font><br>
<font
face="Courier New, Courier, monospace"># only usable with ext. ffmpeg</font><br>
<font
face="Courier New, Courier, monospace">cin_pix_fmt=nv12<br>
<br>
</font></blockquote>
<font
face="Courier New, Courier, monospace">DV
input renders ok to yuv420p<br>
** rendered 2832 frames in 5.475 secs,
517.260 fps<br>
<br>
HDV input fails:<br>
[av1_qsv @ 0x7ff7cca8b9c0] Current
picture structure is unsupported<br>
[av1_qsv @ 0x7ff7cca8b9c0] some
encoding parameters are not supported
by the QSV runtime. Please double
check the input parameters.<br>
FFMPEG::open_encoder err: Function
not implemented<br>
int FFMPEG::open_encoder(const char*,
const char*):<br>
open failed
av1_qsv:/Videoklipp/QSV/hdv09_04_av1_qsv.mp4<br>
<br>
FHD input fails<br>
[av1_qsv @ 0x7ff7918e82c0] Current
picture structure is unsupported<br>
[av1_qsv @ 0x7ff7918e82c0] some
encoding parameters are not supported
by the QSV runtime. Please double
check the input parameters.<br>
FFMPEG::open_encoder err: Function
not implemented<br>
int FFMPEG::open_encoder(const char*,
const char*):<br>
open failed
av1_qsv:/Videoklipp/QSV/hd01_av1_qsv.mp4<br>
</font><br>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</blockquote>
<br>
<font face="Courier New, Courier, monospace">After this
overview:<br>
<br>
I modified ffmpeg/encode.opts to loglevel=debug and
tried to render HDV (and FHD) again:<br>
<br>
[AVHWDeviceContext @ 0x7f99881fee40] Trying to use DRM
render node for device 0.<br>
[AVHWDeviceContext @ 0x7f99881fee40] libva: VA-API
version 1.22.0<br>
[AVHWDeviceContext @ 0x7f99881fee40] libva: User
requested driver 'iHD'<br>
[AVHWDeviceContext @ 0x7f99881fee40] libva: Trying to
open /usr/lib64/dri/iHD_drv_video.so<br>
[AVHWDeviceContext @ 0x7f99881fee40] libva: Found init
function __vaDriverInit_1_22<br>
[AVHWDeviceContext @ 0x7f99881fee40] libva:
va_openDriver() returns 0<br>
[AVHWDeviceContext @ 0x7f99881fee40] Initialised VAAPI
connection: version 1.22<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x41524742
-> bgra.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x41424752
-> rgba.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x58524742
-> bgr0.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x58424752
-> rgb0.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30335241
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30334241
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30335258
-> x2rgb10le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30334258
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x36314752
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x56555941
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x56555958
-> vuyx.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30303859
-> gray.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x3231564e
-> nv12.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x3132564e
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x32595559
-> yuyv422.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x59565955
-> uyvy422.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x32315659
-> yuv420p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30323449
-> yuv420p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x50313134
-> yuv411p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x48323234
-> yuv422p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x56323234
-> yuv440p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x50343434
-> yuv444p.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x33434d49
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30313050
-> p010le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x32313050
-> p012le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x36313050
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30313259
-> y210le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x32313259
-> y212le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x36313259
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x30313459
-> xv30le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x32313459
-> xv36le.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x36313459
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x50424752
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] Format 0x50524742
-> unknown.<br>
[AVHWDeviceContext @ 0x7f99881fee40] VAAPI driver:
Intel iHD driver for Intel(R) Gen Graphics - 24.4.0
().<br>
[AVHWDeviceContext @ 0x7f99881fee40] Driver not found
in known nonstandard list, using standard behaviour.<br>
[av1_qsv @ 0x7f99880565c0] Initialized an internal MFX
session using hardware accelerated implementation<br>
[av1_qsv @ 0x7f99880565c0] Using the constant
quantization parameter (CQP) by default. Please use
the global_quality option and other options for a
quality-based mode or the b option and other options
for a bitrate-based mode if the default is not the
desired choice.<br>
[av1_qsv @ 0x7f99880565c0] Using the constant
quantization parameter (CQP) ratecontrol method<br>
[av1_qsv @ 0x7f99880565c0] Current picture structure
is unsupported<br>
[av1_qsv @ 0x7f99880565c0] some encoding parameters
are not supported by the QSV runtime. Please double
check the input parameters.<br>
FFMPEG::open_encoder err: Function not implemented<br>
int FFMPEG::open_encoder(const char*, const char*):<br>
open failed
av1_qsv:/Videoklipp/QSV/hdv09_04_av1_qsv.mp4<br>
Render::render_single: Session finished.<br>
</font></div>
</blockquote>
</div>
</div>
<div dir="auto"><br>
</div>
<div dir="auto">Sorry, but even with additional msgs root case
of this problem is not clearer at all for me.</div>
<div dir="auto"><br>
</div>
<div dir="auto">You tried with progressive/deinterlaced source,
with everything set to progressive?</div>
<div dir="auto"><br>
</div>
<div dir="auto">Isn't point of this thread to get 10bit, 10bit +
yuv422 encoder presets working? I suggest to put aside
obviously failing ones for now.</div>
<div dir="auto"><br>
</div>
<div dir="auto"><br>
</div>
</div>
</blockquote>
<br>
I think AV1-10bit yuv422 is only supported by librav1e software
encoding yet.<br>
<br>
But av1_qsv encoding 8bit (nv12) and 10bit 420 (p010) is supported
by ffmpeg.<br>
The following command works for me for me with HDV and FHD
interlaced input:<br>
<br>
<font face="Courier New, Courier, monospace">HDV --> av1_qsv
-global_quality 25<br>
-----------------------------------<br>
ffmpeg -hide_banner -qsv_device /dev/dri/renderD128 -i
hdv09_04.m2t -pix_fmt nv12 -c:v av1_qsv -global_quality 25
hdv09_04_av1_qsv_format_nv12_gq25.mp4<br>
<br>
ffprobe -hide_banner hdv09_04_av1_qsv_format_nv12_gq25.mp4<br>
Stream #0:0[0x1](und): Video: av1 (libdav1d) (Main) (av01 /
0x31307661), yuv420p(tv, bt709, top coded first (swapped)),
1440x1080, 7902 kb/s, SAR 4:3 DAR 16:9, 24.99 fps, 25 tbr, 12800
tbn (default)<br>
</font><br>
<br>
<font face="Courier New, Courier, monospace">FHD --> av1_qsv
-global_quality 25<br>
-----------------------------------<br>
ffmpeg -hide_banner -qsv_device /dev/dri/renderD128 -i cfhd01.mkv
-pix_fmt p010 -c:v av1_qsv -global_quality 25
cfhd01_av1_qsv_format_p010_gq25.mp4<br>
<br>
ffprobe -hide_banner cfhd01_av1_qsv_format_p010_gq25.mp4<br>
Stream #0:0[0x1](eng): Video: av1 (libdav1d) (Main) (av01 /
0x31307661), yuv420p10le(tv, bt709, progressive), 1920x1080, 5761
kb/s, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 12800 tbn (default)<br>
<br>
<br>
ffmpeg output some mpeg warnings in the HDV file, but renders it
seemingly ok<br>
<br>
[mpegts @ 0x560dbed1b800] PES packet size mismatch0:03:56.16
bitrate=8036.6kbits/s speed=22.5x <br>
[mpegts @ 0x560dbed1b800] Packet corrupt (stream = 1, dts =
258142320).<br>
[mpeg2video @ 0x560dbec663c0] ac-tex damaged at 10 61<br>
[mpeg2video @ 0x560dbec663c0] Warning MVs not available<br>
[mpeg2video @ 0x560dbec663c0] concealing 630 DC, 630 AC, 630 MV
errors in P frame<br>
[vist#0:0/mpeg2video @ 0x560dbedd2f40] [dec:mpeg2video @
0x560dbecb4140] corrupt decoded frame<br>
[out#0/mp4 @ 0x560dbec67440] video:230191KiB audio:3787KiB
subtitle:0KiB other streams:0KiB global headers:0KiB muxing
overhead: 0.051687%<br>
frame= 5963 fps=561 q=-0.0 Lsize= 234099KiB time=00:03:58.77
bitrate=8031.5kbits/s speed=22.5x <br>
</font><br>
<br>
I tried to adapt my hevc_qsv preset for av1_qsv as follows<br>
<br>
<font face="Courier New, Courier, monospace">av1_qsv_8b420.mp4<br>
</font>
<blockquote><font face="Courier New, Courier, monospace">mp4 av1_qsv</font><br>
<font face="Courier New, Courier, monospace"># av1_qsv_8b420</font><br>
<font face="Courier New, Courier, monospace"># usable with Pixels:
nv12</font><br>
<font face="Courier New, Courier, monospace">profile=main</font><br>
<font face="Courier New, Courier, monospace">global_quality=25<br>
</font></blockquote>
<font face="Courier New, Courier, monospace"><br>
but attempt to render the same HDV file fails with the following
output<br>
<br>
[av1_qsv @ 0x7fd604299600] Encoder: input is system memory surface<br>
[av1_qsv @ 0x7fd604299600] Use Intel(R) oneVPL to create MFX
session, the required implementation version is 1.1<br>
libva info: VA-API version 1.22.0<br>
libva info: Trying to open /usr/lib64/dri/iHD_drv_video.so<br>
libva info: Found init function __vaDriverInit_1_22<br>
libva info: va_openDriver() returns 0<br>
libva info: VA-API version 1.22.0<br>
libva info: Trying to open /usr/lib64/dri/iHD_drv_video.so<br>
libva info: Found init function __vaDriverInit_1_22<br>
libva info: va_openDriver() returns 0<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Trying to use DRM render node
for device 0.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] libva: VA-API version 1.22.0<br>
[AVHWDeviceContext @ 0x7fd60408bd40] libva: User requested driver
'iHD'<br>
[AVHWDeviceContext @ 0x7fd60408bd40] libva: Trying to open
/usr/lib64/dri/iHD_drv_video.so<br>
[AVHWDeviceContext @ 0x7fd60408bd40] libva: Found init function
__vaDriverInit_1_22<br>
[AVHWDeviceContext @ 0x7fd60408bd40] libva: va_openDriver()
returns 0<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Initialised VAAPI connection:
version 1.22<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x41524742 -> bgra.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x41424752 -> rgba.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x58524742 -> bgr0.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x58424752 -> rgb0.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30335241 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30334241 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30335258 ->
x2rgb10le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30334258 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x36314752 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x56555941 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x56555958 -> vuyx.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30303859 -> gray.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x3231564e -> nv12.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x3132564e ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x32595559 ->
yuyv422.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x59565955 ->
uyvy422.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x32315659 ->
yuv420p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30323449 ->
yuv420p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x50313134 ->
yuv411p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x48323234 ->
yuv422p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x56323234 ->
yuv440p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x50343434 ->
yuv444p.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x33434d49 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30313050 ->
p010le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x32313050 ->
p012le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x36313050 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30313259 ->
y210le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x32313259 ->
y212le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x36313259 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x30313459 ->
xv30le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x32313459 ->
xv36le.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x36313459 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x50424752 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Format 0x50524742 ->
unknown.<br>
[AVHWDeviceContext @ 0x7fd60408bd40] VAAPI driver: Intel iHD
driver for Intel(R) Gen Graphics - 24.4.0 ().<br>
[AVHWDeviceContext @ 0x7fd60408bd40] Driver not found in known
nonstandard list, using standard behaviour.<br>
[av1_qsv @ 0x7fd604299600] Initialized an internal MFX session
using hardware accelerated implementation<br>
[av1_qsv @ 0x7fd604299600] Using the intelligent constant quality
(ICQ) ratecontrol method<br>
[av1_qsv @ 0x7fd604299600] Current picture structure is
unsupported<br>
[av1_qsv @ 0x7fd604299600] some encoding parameters are not
supported by the QSV runtime. Please double check the input
parameters.<br>
FFMPEG::open_encoder err: Function not implemented<br>
int FFMPEG::open_encoder(const char*, const char*):<br>
open failed av1_qsv:/Videoklipp/QSV/hdv09_04_av1_qsv.mp4<br>
Render::render_single: Session finished.<br>
Connection failure: Connection refused<br>
pa_context_connect() failed: Connection refused<br>
<br>
</font><br>
<font face="Courier New, Courier, monospace"><br>
</font><br>
<br>
<br>
</body>
</html>