Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame^] | 1 | From 377a67af6c3f7c38f6f7ba24f042ba1a6cfd3f24 Mon Sep 17 00:00:00 2001 |
| 2 | From: Vincent Davis Jr <vince@underview.tech> |
| 3 | Date: Fri, 9 Dec 2022 00:21:43 -0600 |
| 4 | Subject: [PATCH] use GLESv2 headers over GL headers |
| 5 | |
| 6 | Upstream-Status: Inappropriate |
| 7 | |
| 8 | RPI-Distro repo forks original vlc and applies patches to enable |
| 9 | raspiberry pi support. |
| 10 | |
| 11 | We utilize GLESv2 during compilation. Patches ensures |
| 12 | we utilize headers for it. |
| 13 | |
| 14 | Signed-off-by: Vincent Davis Jr <vince@underview.tech> |
| 15 | --- |
| 16 | modules/video_output/opengl/converter.h | 12 +++--------- |
| 17 | modules/visualization/glspectrum.c | 4 +++- |
| 18 | 2 files changed, 6 insertions(+), 10 deletions(-) |
| 19 | |
| 20 | diff --git a/modules/video_output/opengl/converter.h b/modules/video_output/opengl/converter.h |
| 21 | index 7000e1f38..a3fe32671 100644 |
| 22 | --- a/modules/video_output/opengl/converter.h |
| 23 | +++ b/modules/video_output/opengl/converter.h |
| 24 | @@ -41,15 +41,9 @@ |
| 25 | # include <OpenGLES/ES2/glext.h> |
| 26 | # endif |
| 27 | #else /* !defined (__APPLE__) */ |
| 28 | -# if defined (USE_OPENGL_ES2) |
| 29 | -# include <GLES2/gl2.h> |
| 30 | -# include <GLES2/gl2ext.h> |
| 31 | -# else |
| 32 | -# ifdef _WIN32 |
| 33 | -# include <GL/glew.h> |
| 34 | -# endif |
| 35 | -# include <GL/gl.h> |
| 36 | -# endif |
| 37 | +#define USE_OPENGL_ES2 |
| 38 | +#include <GLES2/gl2.h> |
| 39 | +#include <GLES2/gl2ext.h> |
| 40 | #endif |
| 41 | |
| 42 | #define VLCGL_PICTURE_MAX 128 |
| 43 | diff --git a/modules/visualization/glspectrum.c b/modules/visualization/glspectrum.c |
| 44 | index 06f8d1bdf..470080b1a 100644 |
| 45 | --- a/modules/visualization/glspectrum.c |
| 46 | +++ b/modules/visualization/glspectrum.c |
| 47 | @@ -37,7 +37,9 @@ |
| 48 | #ifdef __APPLE__ |
| 49 | # include <OpenGL/gl.h> |
| 50 | #else |
| 51 | -# include <GL/gl.h> |
| 52 | +#define USE_OPENGL_ES2 |
| 53 | +#include <GLES2/gl2.h> |
| 54 | +#include <GLES2/gl2ext.h> |
| 55 | #endif |
| 56 | |
| 57 | #include <math.h> |
| 58 | -- |
| 59 | 2.38.1 |
| 60 | |