Opened 11 months ago

Last modified 6 months ago

#10443 new defect

VPP_QSV: Output distorted when the crop offset (cx/cy) is an odd value

Reported by: NLE-Chipcraft Owned by:
Priority: normal Component: avfilter
Version: git-master Keywords: Intel, VPP_QSV, Crop
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description (last modified by NLE-Chipcraft)

The output frame will be distorted, if the crop offset (cx/cy parameter) of the VPP_QSV filter is not divisible by two. When the crop offset IS an even value, the output matches of the one from AVFilter crop-function.

Tested with:

  • Intel(R) HD Graphics Gen11 (DeviceID 4E71h) w/ 31.0.101.2125 driver
  • Windows 10 Pro 22H2 19045.3086
  • FFMpeg git-master built with gcc 13.1.0 (Rev7, Built by MSYS2 project)
  • MFX_Dispatch master-branch: https://github.com/lu-zero/mfx_dispatch

Examples:

ffmpeg -s 1920x1080 -i Sample.yuv -vf crop=1920:1040:0:20 LAVFI_Even.PNG // Reference - Even.

ffmpeg -s 1920x1080 -i Sample.yuv -vf crop=1920:1038:0:21 LAVFI_Odd.PNG // Reference - Odd.

ffmpeg -hwaccel qsv -hwaccel_output_format qsv -init_hw_device qsv=hw,child_device_type=d3d11va -filter_hw_device hw -s 1920x1080 -i Sample.yuv -vf vpp_qsv=cw=1920:ch=1040:cx=0:cy=20 QSV_Even.PNG // QSV - No distortion, matches LAVFI output.

ffmpeg -hwaccel qsv -hwaccel_output_format qsv -init_hw_device qsv=hw,child_device_type=d3d11va -filter_hw_device hw -s 1920x1080 -i Sample.yuv -vf vpp_qsv=cw=1920:ch=1038:cx=0:cy=21 QSV_Odd.PNG // QSV - Distorted output relative to LAVFI.

Samples uploaded using the "VideoLAN File Uploader", with reference to this ticket number.

Change History (3)

comment:1 by NLE-Chipcraft, 11 months ago

Description: modified (diff)

comment:2 by NLE-Chipcraft, 11 months ago

Description: modified (diff)

comment:3 by wenbin,chen, 6 months ago

Considering the U V plane, the coordinates should better be even. The "crop" filter align w and h to even. If you want to do exact crop, you can add option "crop=1920:1038:0:21:exact=1", but vpp_qsv doesn't support this feature.

Note: See TracTickets for help on using tickets.