[vlc-commits] opengl: add support for renderbuffers API
Romain Vimont
git at videolan.org
Thu Sep 10 15:41:45 CEST 2020
vlc | branch: master | Romain Vimont <rom1v at videolabs.io> | Tue Jul 7 12:33:52 2020 +0200| [c10bbd2f9a3fe143c4ea234c1f0f23ea5e1c2a15] | committer: Alexandre Janniaux
opengl: add support for renderbuffers API
Co-authored-by: Alexandre Janniaux <ajanni at videolabs.io>
Signed-off-by: Alexandre Janniaux <ajanni at videolabs.io>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c10bbd2f9a3fe143c4ea234c1f0f23ea5e1c2a15
---
modules/video_output/opengl/gl_api.c | 5 +++++
modules/video_output/opengl/gl_common.h | 10 ++++++++++
2 files changed, 15 insertions(+)
diff --git a/modules/video_output/opengl/gl_api.c b/modules/video_output/opengl/gl_api.c
index 6bead1cb6b..bdfd9c030b 100644
--- a/modules/video_output/opengl/gl_api.c
+++ b/modules/video_output/opengl/gl_api.c
@@ -119,6 +119,11 @@ vlc_gl_api_Init(struct vlc_gl_api *api, vlc_gl_t *gl)
GET_PROC_ADDR(DeleteBuffers);
GET_PROC_ADDR_OPTIONAL(GetFramebufferAttachmentParameteriv);
+ GET_PROC_ADDR_OPTIONAL(GenFramebuffers);
+ GET_PROC_ADDR_OPTIONAL(DeleteFramebuffers);
+ GET_PROC_ADDR_OPTIONAL(BindFramebuffer);
+ GET_PROC_ADDR_OPTIONAL(FramebufferTexture2D);
+ GET_PROC_ADDR_OPTIONAL(CheckFramebufferStatus);
GET_PROC_ADDR_OPTIONAL(BufferSubData);
GET_PROC_ADDR_OPTIONAL(BufferStorage);
diff --git a/modules/video_output/opengl/gl_common.h b/modules/video_output/opengl/gl_common.h
index 26ff00d7cc..a1dd060dff 100644
--- a/modules/video_output/opengl/gl_common.h
+++ b/modules/video_output/opengl/gl_common.h
@@ -243,6 +243,11 @@ typedef void (APIENTRY *PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLs
# define PFNGLBUFFERSUBDATAPROC typeof(glBufferSubData)*
# define PFNGLDELETEBUFFERSPROC typeof(glDeleteBuffers)*
# define PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC typeof(glGetFramebufferAttachmentParameteriv)*
+# define PFNGLGENFRAMEBUFFERSPROC typeof(glGenFramebuffers)*
+# define PFNGLDELETEFRAMEBUFFERSPROC typeof(glDeleteFramebuffers)*
+# define PFNGLBINDFRAMEBUFFERPROC typeof(glBindFramebuffer)*
+# define PFNGLFRAMEBUFFERTEXTURE2DPROC typeof(glFramebufferTexture2D)*
+# define PFNGLCHECKFRAMEBUFFERSTATUSPROC typeof(glCheckFramebufferStatus)*
#if defined(__APPLE__)
# import <CoreFoundation/CoreFoundation.h>
#endif
@@ -343,6 +348,11 @@ typedef struct {
/* Framebuffers commands */
PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC GetFramebufferAttachmentParameteriv;
+ PFNGLGENFRAMEBUFFERSPROC GenFramebuffers;
+ PFNGLDELETEFRAMEBUFFERSPROC DeleteFramebuffers;
+ PFNGLBINDFRAMEBUFFERPROC BindFramebuffer;
+ PFNGLFRAMEBUFFERTEXTURE2DPROC FramebufferTexture2D;
+ PFNGLCHECKFRAMEBUFFERSTATUSPROC CheckFramebufferStatus;
/* Commands used for PBO and/or Persistent mapping */
PFNGLBUFFERSUBDATAPROC BufferSubData; /* can be NULL */
More information about the vlc-commits
mailing list