summaryrefslogtreecommitdiffstats
path: root/video/out/gl_common.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-01-22 18:29:37 +0100
committerwm4 <wm4@nowhere>2015-01-22 18:31:10 +0100
commit5bb24980ae3a111cb7b905631c3fc7e79ca84ccc (patch)
treec953ad84e692cb86b8e0e21fe793847c46a6a37a /video/out/gl_common.h
parent16cc429eb8ba74da9a774186e25b171e416d99a6 (diff)
downloadmpv-5bb24980ae3a111cb7b905631c3fc7e79ca84ccc.tar.bz2
mpv-5bb24980ae3a111cb7b905631c3fc7e79ca84ccc.tar.xz
vo_opengl: simplify screenshot code
Instead of reading back the image from textures, keep a reference to the original image, and return that. The main reason this was done this way was that originally, images weren't refcounted, and would be deallocated or overwritten as soon as the VO's draw call returned. But now there isn't really a good reason for this anymore. One possibly _could_ argue that it was better because other code could reuse the image sooner (e.g. for the cache), but on the other hand, the VO runs already on a different thread, and filtering and decoding each run on other threads too, so this argument probably wouldn't hold up.
Diffstat (limited to 'video/out/gl_common.h')
-rw-r--r--video/out/gl_common.h3
1 files changed, 0 insertions, 3 deletions
diff --git a/video/out/gl_common.h b/video/out/gl_common.h
index 7c9fbc0045..24c6091ade 100644
--- a/video/out/gl_common.h
+++ b/video/out/gl_common.h
@@ -59,8 +59,6 @@ void glUploadTex(GL *gl, GLenum target, GLenum format, GLenum type,
int x, int y, int w, int h, int slice);
void glClearTex(GL *gl, GLenum target, GLenum format, GLenum type,
int x, int y, int w, int h, uint8_t val, void **scratch);
-void glDownloadTex(GL *gl, GLenum target, GLenum format, GLenum type,
- void *dataptr, int stride);
void glCheckError(GL *gl, struct mp_log *log, const char *info);
mp_image_t *glGetWindowScreenshot(GL *gl);
@@ -200,7 +198,6 @@ struct GL {
void (GLAPIENTRY *TexSubImage2D)(GLenum, GLint, GLint, GLint,
GLsizei, GLsizei, GLenum, GLenum,
const GLvoid *);
- void (GLAPIENTRY *GetTexImage)(GLenum, GLint, GLenum, GLenum, GLvoid *);
void (GLAPIENTRY *TexParameteri)(GLenum, GLenum, GLint);
void (GLAPIENTRY *GetIntegerv)(GLenum, GLint *);
void (GLAPIENTRY *GetBooleanv)(GLenum, GLboolean *);