summaryrefslogtreecommitdiffstats
path: root/video/out/gl_utils.h
diff options
context:
space:
mode:
Diffstat (limited to 'video/out/gl_utils.h')
-rw-r--r--video/out/gl_utils.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/video/out/gl_utils.h b/video/out/gl_utils.h
index 482c88a0fa..514b873dbe 100644
--- a/video/out/gl_utils.h
+++ b/video/out/gl_utils.h
@@ -66,4 +66,18 @@ void gl_vao_bind(struct gl_vao *vao);
void gl_vao_unbind(struct gl_vao *vao);
void gl_vao_bind_attribs(struct gl_vao *vao, GLuint program);
+struct fbotex {
+ GL *gl;
+ GLuint fbo;
+ GLuint texture;
+ int tex_w, tex_h; // size of .texture
+ int vp_x, vp_y, vp_w, vp_h; // viewport of fbo / used part of the texture
+};
+
+bool fbotex_init(struct fbotex *fbo, GL *gl, struct mp_log *log, int w, int h,
+ GLenum gl_target, GLenum gl_filter, GLenum iformat);
+void fbotex_uninit(struct fbotex *fbo);
+
+void gl_matrix_ortho2d(float m[3][3], float x0, float x1, float y0, float y1);
+
#endif