updated makefile for supporting different target architectures
use "ARCH=arch_name make" restructured project folder, implementations and headers together under sources/
This commit is contained in:
82
NOTES/COMPATIBILITY
Normal file
82
NOTES/COMPATIBILITY
Normal file
@@ -0,0 +1,82 @@
|
||||
in molte unità si usano delle chiamate disponibili solo da GL4 / GLES3.1
|
||||
|
||||
# include <GL/glew.h>
|
||||
|
||||
diventa
|
||||
|
||||
# include <GLES2/gl2.h>
|
||||
|
||||
più l'opzionale
|
||||
# include <GLES2/gl2ext.h>
|
||||
|
||||
|
||||
anzichè riscrivere le funzioni mancanti rinominandole alla precedente versione d'estensione, si introducano delle macro da aliasing
|
||||
|
||||
ma si potrebbe anche usare la guardia per racchiudere delle semplici definizioni
|
||||
|
||||
void glDrawBuffers(GLsizei n, const GLenum *bufs){
|
||||
glDrawBuffersEXT( n, bufs);
|
||||
}
|
||||
|
||||
|
||||
|
||||
#define GL_GLEXT_PROTOTYPES
|
||||
#include <GLES2/gl2ext.h>
|
||||
|
||||
#ifndef glGenVertexArrays
|
||||
#define glGenVertexArrays( n, arrays_ptr) { \
|
||||
glGenVertexArraysOES( n, arrays_ptr); \
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifndef glBindVertexArray
|
||||
#define glBindVertexArray( array_ptr) { \
|
||||
glBindVertexArrayOES( array_ptr); \
|
||||
}
|
||||
#endif
|
||||
|
||||
ifndef glDrawBuffers
|
||||
define glDrawBuffers ( n, buffers_ptr) { \
|
||||
glDrawBuffersEXT( n, bufs); \
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
sarebbe ancora meglio wrappare tutto attorno a (o un test più sofisticato per dire GL4 o GLES3.1)
|
||||
#ifndef GL_ES_VERSION_3_1
|
||||
...
|
||||
#endif
|
||||
Reference in New Issue
Block a user