mirror of
https://github.com/mpv-player/mpv
synced 2024-12-23 15:22:09 +00:00
vo_opengl: remove some more Cocoa resize leftovers
This commit is contained in:
parent
0468a4ea47
commit
7e21f6fd00
@ -107,13 +107,6 @@ typedef struct MPGLContext {
|
||||
// version is not available, and newer versions are incompatible.)
|
||||
bool (*config_window)(struct MPGLContext *ctx, int flags);
|
||||
|
||||
// An optional function to register a resize callback in the backend that
|
||||
// can be called on separate thread to handle resize events immediately
|
||||
// (without waiting for vo_check_events, which will come later for the
|
||||
// proper resize)
|
||||
void (*register_resize_callback)(struct vo *vo,
|
||||
void (*cb)(struct vo *vo, int w, int h));
|
||||
|
||||
// Optional callback on the beginning of a frame. The frame will be finished
|
||||
// with swapGlBuffers(). This returns false if use of the OpenGL context
|
||||
// should be avoided.
|
||||
|
@ -2690,18 +2690,6 @@ static int validate_window_opt(struct mp_log *log, const m_option_t *opt,
|
||||
return r;
|
||||
}
|
||||
|
||||
|
||||
// Resize and redraw the contents of the window without further configuration.
|
||||
// Intended to be used in situations where the frontend can't really be
|
||||
// involved with reconfiguring the VO properly.
|
||||
// gl_video_resize() should be called when user interaction is done.
|
||||
void gl_video_resize_redraw(struct gl_video *p, int w, int h)
|
||||
{
|
||||
p->vp_w = w;
|
||||
p->vp_h = h;
|
||||
gl_video_render_frame(p, 0, NULL);
|
||||
}
|
||||
|
||||
float gl_video_scale_ambient_lux(float lmin, float lmax,
|
||||
float rmin, float rmax, float lux)
|
||||
{
|
||||
|
@ -93,7 +93,6 @@ struct mp_csp_equalizer *gl_video_eq_ptr(struct gl_video *p);
|
||||
void gl_video_eq_update(struct gl_video *p);
|
||||
|
||||
void gl_video_set_debug(struct gl_video *p, bool enable);
|
||||
void gl_video_resize_redraw(struct gl_video *p, int w, int h);
|
||||
|
||||
float gl_video_scale_ambient_lux(float lmin, float lmax,
|
||||
float rmin, float rmax, float lux);
|
||||
|
@ -211,13 +211,6 @@ static int query_format(struct vo *vo, int format)
|
||||
return 1;
|
||||
}
|
||||
|
||||
static void video_resize_redraw_callback(struct vo *vo, int w, int h)
|
||||
{
|
||||
struct gl_priv *p = vo->priv;
|
||||
gl_video_resize_redraw(p->renderer, w, -h);
|
||||
|
||||
}
|
||||
|
||||
static int reconfig(struct vo *vo, struct mp_image_params *params, int flags)
|
||||
{
|
||||
struct gl_priv *p = vo->priv;
|
||||
@ -229,10 +222,6 @@ static int reconfig(struct vo *vo, struct mp_image_params *params, int flags)
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (p->glctx->register_resize_callback) {
|
||||
p->glctx->register_resize_callback(vo, video_resize_redraw_callback);
|
||||
}
|
||||
|
||||
resize(p);
|
||||
|
||||
gl_video_config(p->renderer, params);
|
||||
|
Loading…
Reference in New Issue
Block a user