summaryrefslogtreecommitdiffstats
path: root/video/out/vo_gpu.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2018-02-13 18:07:20 +0100
committerKevin Mitchell <kevmitch@gmail.com>2018-02-13 17:45:29 -0800
commitf17246fec15963e7cc098cf7ba7263ad02877b99 (patch)
tree45689c1cd1200df665969d4ea75d3dab17de1c46 /video/out/vo_gpu.c
parentceca1602e9360564a780036597dfe904566611ff (diff)
downloadmpv-f17246fec15963e7cc098cf7ba7263ad02877b99.tar.bz2
mpv-f17246fec15963e7cc098cf7ba7263ad02877b99.tar.xz
vo_gpu: remove old window screenshot glue code and GL implementation
There is now a better way. Reading the font framebuffer was always a hack. The new code via VOCTRL_SCREENSHOT renders it into a FBO, which does not come with the disadvantages of reading the front buffer (like not being supported by GLES, possibly black regions due to overlapping windows on some systems). For now keep VOCTRL_SCREENSHOT_WIN on the VO level, because there are still some lesser VOs and backends that use it.
Diffstat (limited to 'video/out/vo_gpu.c')
-rw-r--r--video/out/vo_gpu.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/video/out/vo_gpu.c b/video/out/vo_gpu.c
index 70c874fc54..61696af0e4 100644
--- a/video/out/vo_gpu.c
+++ b/video/out/vo_gpu.c
@@ -168,7 +168,6 @@ static void get_and_update_ambient_lighting(struct gpu_priv *p)
static int control(struct vo *vo, uint32_t request, void *data)
{
struct gpu_priv *p = vo->priv;
- struct ra_swapchain *sw = p->ctx->swapchain;
switch (request) {
case VOCTRL_SET_PANSCAN:
@@ -177,17 +176,6 @@ static int control(struct vo *vo, uint32_t request, void *data)
case VOCTRL_SET_EQUALIZER:
vo->want_redraw = true;
return VO_TRUE;
- case VOCTRL_SCREENSHOT_WIN: {
- struct mp_image *screen = NULL;
- if (sw->fns->screenshot)
- screen = sw->fns->screenshot(sw);
- if (!screen)
- break; // redirect to backend
- // set image parameters according to the display, if possible
- screen->params.color = gl_video_get_output_colorspace(p->renderer);
- *(struct mp_image **)data = screen;
- return true;
- }
case VOCTRL_SCREENSHOT: {
struct vo_frame *frame = vo_get_current_vo_frame(vo);
if (frame) {