vapostproc or videoscale: when doing resolution conversion, it is cropped or not cover full screen
Describe your issue
When using vapostproc or videoscale doing video scaling, it seems keeping original aspect ratio causing the image cropped or not full covered. This is not happening with vaapipostproc.
Expected Behavior
It will scale to the expected resolution mentioned
Observed Behavior
Either cropped or it does not cover full screen.
Setup
- Ubuntu 22.04
- Machine with 1920x1080 display output
- Gstreamer 1.22.2
- gst-launch-1.0 -v videotestsrc num-buffers=300 ! video/x-raw,format=NV12,width=800,height=600 ! videoscale ! video/x-raw,format=NV12,width=1920,height=1080 ! waylandsink or gst-launch-1.0 -v videotestsrc num-buffers=300 ! video/x-raw,format=NV12,width=640,height=320 ! vapostproc ! video/x-raw,format=NV12,width=1920,height=1080 ! waylandsink
Steps to reproduce the bug
- open terminal
- run the command above. You can use glimagesink under X11 and will see the same behavior.
How reproducible is the bug?
Always
Screenshots if relevant
Solutions you have tried
using vaapipostproc will have not this issue.
gst-launch-1.0 videotestsrc num-buffers=300 ! video/x-raw,format=NV12,width=800,height=600 ! vaapipostproc ! video/x-raw,format=NV12,width=1920,height=1080 ! waylandsink
gst-launch-1.0 videotestsrc num-buffers=300 ! video/x-raw,format=NV12,width=640,height=320 ! vaapipostproc ! video/x-raw,format=NV12,width=1920,height=1080 ! waylandsink