GNOME Bugzilla – Bug 769147
playbin: Add videoflip/glvideoflip or similar to the video-sink
Last modified: 2018-11-03 11:48:20 UTC
Created attachment 332099 [details]
2 second video of a door, portrait mode.
I attach a 2-second video taken on an iPhone 4S. It's a portrait mode video of a normal upright door. I can double-click it on Windows 10 or Mac 10.0 and it plays correctly as portrait mode. However GStreamer displays it in landscape mode with the door on its side. I've tried:
gst-launch-1.0 filesrc location=door_rotn.mov ! decodebin ! videoconvert ! autovideosink
Linux GST 1.2.4
Windows GST 1.8.2
Mac GST 1.8.2
Obviously it's easy enough to put a rotation into the GStreamer pipeline to correct it, but it shouldn't be necessary.
With videoflip method=auto or the same with glvideoflip, this already does the right thing. It's just not in playbin yet.
If you do a manual pipeline, you will have to add videoflip or glvideoflip yourself though.
Thanks for this. Is there any way to determine the rotation required and then I can specify it to videoflip explicitly? This would have 2 advantages for me:
1) It might well work on GST 1.2.4 which does not have the "automatic" videoflip method. And there is lots of 1.2.4 still out there, e.g. Ubuntu 14.04 LTS.
2) I already offer my users the option of flipping, so if I use "automatic" videoflip then I would have to follow it with a second videoflip for user-requested flipping. I presume it would be more efficient to combine the two operations in a single flip.
The rotation is given in a tag, GST_TAG_IMAGE_ORIENTATION
Thanks again, I'll try it.
Incidentally I think my 2nd point above is invalid - I don't think you can execute a 90 degree rotation followed by a horizontal or vertical flip in one operation can you? I don't think any of the available flip modes do this.
Actually I think they do, sorry I'll shut up.
Are you planning to work on this?
-- GitLab Migration Automatic Message --
This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.
You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/issues/279.