Commit graph

8 commits

Author SHA1 Message Date
Matthew Waters 1abd0804f4 gl/caopengllayer: use public GstGLContext instead of Cocoa-specific one
Allows keeping the GstGLCAOpenGLLayer public but not the winsys-specific
context/display/window.
2017-12-09 19:32:31 +00:00
Matthew Waters 63bbe9406a glwindow: add API to request a resize event on the next draw
- glimagesink needs to be able to resize the viewport on aspect ratio
  changes resulting from either caps changes or 3d output mode changes.
- Performing a glViewport outside the GstGLWindow::resize callback
  will not have the winsys' stack of viewports required to correctly
  place the output frame.

Provide a function to request a resize on the next draw event from the
winsys.

Also track size changes inside the base GstGLWindow class rather
than in each subclass.

https://bugzilla.gnome.org/show_bug.cgi?id=755111
2017-12-09 19:32:08 +00:00
Matthew Waters e8e84cf6b3 gl/calayer: provide a current wrapped GstGLContext for callbacks
So that the draw and resize callbacks can get the current GstGLContext.
2017-12-09 19:32:01 +00:00
Matthew Waters 9938fe7fa9 gl/calayer: only start drawing if the parent gl context is ready
otherwise we may try to use GstGLFuncs * that hasn't been set yet
2017-12-09 19:31:54 +00:00
Matthew Waters f3beaecfa0 gstglcaopengllayer: use the correct rectangle type for iOS and OS X 2017-12-09 19:31:54 +00:00
Matthew Waters 200842b3f8 gl/calayer: add resize callback based on the bounds rectangle 2017-12-09 19:31:53 +00:00
Matthew Waters 698f1236a4 cgl/calayer: use a callback instead of hardcoding the draw functionality 2017-12-09 19:31:53 +00:00
Matthew Waters e57fb35bc0 cgl: add a header for the CAOpenGLLayer support 2017-12-09 19:31:53 +00:00