After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 617506 - [videoscale] Add support for adding black borders if necessary to keep the DAR
[videoscale] Add support for adding black borders if necessary to keep the DAR
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Linux
: Normal enhancement
: 0.10.31
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on: 371108
Blocks: 613416
 
 
Reported: 2010-05-03 09:23 UTC by Edward Hervey
Modified: 2010-07-18 13:46 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Edward Hervey 2010-05-03 09:23:20 UTC
Currently there is no *automatic* way to resize a video while adding black borders. That is:
* keep DAR (see bug #371108 regarding videoscale)
* maximize usage of downstream caps by adding black borders

One can of course do this manually (by setting the values on videobox), but requires outside intervention to parse upstream/downstream caps and decide what values to set.

Ideally we shouldn't need videobox for this use case, but instead have a 'add-black-borders' mode on videoscale which respects the two points at the top of this comment.

To demonstrate what's needed, you should be able to use the following pipeline and when you resize the output window, the video should be scaled as much as possible, and have black borders added if/where neeeded :
videotestsrc ! video/x-raw-yuv,width=320,height=240 ! videoscale add-black-borders=True ! ximagesink
Comment 1 Sebastian Dröge (slomo) 2010-05-03 09:51:07 UTC
You need a way to select the color IMHO, maybe you want white instead of black or some other color. Other than that this is definitely a useful feature... and we really need to fix DAR handling in videoscale ;)
Comment 2 Edward Hervey 2010-05-03 09:54:58 UTC
Selecting the color would definitely be a bonus... and for alpha formats leave it transparent also.
Comment 3 Sebastian Dröge (slomo) 2010-05-13 10:28:00 UTC
I'll work on this.
Comment 4 Sebastian Dröge (slomo) 2010-07-18 13:44:40 UTC
commit 52e711b11d5aaca5e52390259b9c76fa7b816932
Author: Sebastian Dröge <sebastian.droege@collabora.co.uk>
Date:   Sat Jul 17 20:24:18 2010 +0200

    videoscale: Add support for adding black borders to keep the DAR if necessar
    
    Fixes bug #617506.