Support for "maintain aspect ratio"/"letterbox" in Gst-nvdspreprocess

Hi,

In our gstreamer video pipeline, we would like to add black padding to the video to maintain the aspect ratio of the actual video.

We found that nvstreammux can satisfy our needs by setting enable-padding to 1. But the framerate of the output is not very stable using VIC, and using GPU will lead to some weird lines in the video. Also, as enable-padding is deprecated in Gst-nvstreammux New, it won’t be a good option for us.

On the other hand, it seems that nvinfer and nvinferserver has support for letterbox by allowing the user to set maintain_aspect_ratio to 1. But we don’t need the inference part of the plugins.

Therefore, could you please tell us

  • if letterbox is supported in any nvidia gstreamer plugins,
  • or it is a planned feature which will be implemented in, for example, Gst-nvdspreprocess (Alpha)

We currently use videobox add-boarder=true as a workaround since it is a CPU-based solution. Could it bring performance gain if we do this directly on GPU?

I appreciate your help in advance!

Kind regards,
Zhongpin Wang

Basically, the preprocess cannot support this. You can refer this link, we’ll consider implement it in the nvstreammux in the future.
https://forums.developer.nvidia.com/t/nvvideoconvert-different-resolutions-support-input-and-output/230047/7

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.