summaryrefslogtreecommitdiffstats
path: root/libvo/gl_common.h
diff options
context:
space:
mode:
authorStefano Pigozzi <stefano.pigozzi@gmail.com>2012-10-21 16:25:42 +0200
committerwm4 <wm4@nowhere>2012-10-24 21:56:34 +0200
commit281989d38437d2a54810bf8638073d8a8cd0dfa0 (patch)
tree07c964be9b9c370ea536e77924f02d73056c1bdb /libvo/gl_common.h
parent6bea013e27c705ad0bc39f7da22b4ac4eabd7890 (diff)
downloadmpv-281989d38437d2a54810bf8638073d8a8cd0dfa0.tar.bz2
mpv-281989d38437d2a54810bf8638073d8a8cd0dfa0.tar.xz
vo_corevideo: add screenshot capability
Added screenshot capability to the corevideo VO by sending back the raw data from the CVPixelBuffer. Also added "screenshot window" functionality from the other OpenGL based VOs, which uses glReadPixels to read image data back. This was moved to gl_common to avoid duplication.
Diffstat (limited to 'libvo/gl_common.h')
-rw-r--r--libvo/gl_common.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/libvo/gl_common.h b/libvo/gl_common.h
index fd80b69126..d9f227c6aa 100644
--- a/libvo/gl_common.h
+++ b/libvo/gl_common.h
@@ -33,6 +33,8 @@
#include "video_out.h"
#include "csputils.h"
+#include "libmpcodecs/mp_image.h"
+
#if defined(CONFIG_GL_COCOA) && !defined(CONFIG_GL_X11)
#ifdef GL_VERSION_3_0
#include <OpenGL/gl3.h>
@@ -72,6 +74,7 @@ void glDrawTex(GL *gl, GLfloat x, GLfloat y, GLfloat w, GLfloat h,
int sx, int sy, int rect_tex, int is_yv12, int flip);
int loadGPUProgram(GL *gl, GLenum target, char *prog);
void glCheckError(GL *gl, const char *info);
+mp_image_t *glGetWindowScreenshot(GL *gl);
/** \addtogroup glconversion
* \{ */