[GStreamer] video orientation support
[WebKit-https.git] / Source / WebCore / platform / graphics / gstreamer / MediaPlayerPrivateGStreamerBase.h
index b50aa01..d6bd904 100644 (file)
@@ -34,6 +34,9 @@
 #include <wtf/Condition.h>
 #include <wtf/Forward.h>
 #include <wtf/RunLoop.h>
+#if USE(TEXTURE_MAPPER_GL)
+#include "TextureMapperGL.h"
+#endif
 
 typedef struct _GstBaseSink GstBaseSink;
 typedef struct _GstMessage GstMessage;
@@ -57,6 +60,13 @@ class MediaPlayerPrivateGStreamerBase : public MediaPlayerPrivateInterface
 {
 
 public:
+    enum VideoSourceRotation {
+        NoVideoSourceRotation,
+        VideoSourceRotation90,
+        VideoSourceRotation180,
+        VideoSourceRotation270
+    };
+
     virtual ~MediaPlayerPrivateGStreamerBase();
 
     FloatSize naturalSize() const override;
@@ -117,6 +127,8 @@ public:
     NativeImagePtr nativeImageForCurrentTime() override;
 #endif
 
+    void setVideoSourceRotation(VideoSourceRotation);
+
 protected:
     MediaPlayerPrivateGStreamerBase(MediaPlayer*);
     virtual GstElement* createVideoSink();
@@ -194,6 +206,11 @@ protected:
     Condition m_drawCondition;
     Lock m_drawMutex;
 #endif
+
+    VideoSourceRotation m_videoSourceRotation;
+#if USE(TEXTURE_MAPPER_GL)
+    TextureMapperGL::Flags m_textureMapperRotationFlag;
+#endif
 };
 }