glshim updated, added latest changes by ptitSeb
This commit is contained in:
@@ -700,7 +700,7 @@ void glshim_glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid
|
||||
list = glstate.list.active;
|
||||
|
||||
normalize_indices(sindices, &max, &min, count);
|
||||
list = arrays_to_renderlist(list, mode, min, max + 1 + min);
|
||||
list = arrays_to_renderlist(list, mode, 0, max + 1 - min);
|
||||
list->indices = sindices;
|
||||
list->ilen = count;
|
||||
list->indice_cap = count;
|
||||
@@ -715,7 +715,7 @@ void glshim_glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid
|
||||
GLsizei min, max;
|
||||
|
||||
normalize_indices(sindices, &max, &min, count);
|
||||
list = arrays_to_renderlist(list, mode, min, max + 1 + min);
|
||||
list = arrays_to_renderlist(list, mode, 0, max + 1 - min);
|
||||
list->indices = sindices;
|
||||
list->ilen = count;
|
||||
list->indice_cap = count;
|
||||
|
||||
@@ -109,6 +109,7 @@ typedef enum {
|
||||
} statbatch_enabled_t;
|
||||
|
||||
typedef struct {
|
||||
int active_tex_changed;
|
||||
GLenum active_tex; // only 1 active texture for now
|
||||
GLenum bound_targ;
|
||||
GLenum bound_tex;
|
||||
|
||||
@@ -1494,13 +1494,13 @@ void glshim_glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type
|
||||
|
||||
void glshim_glActiveTexture( GLenum texture ) {
|
||||
if (glstate.list.active && (glstate.gl_batch && !glstate.list.compiling)) {
|
||||
if ((glstate.statebatch.active_tex == texture))
|
||||
return; // nothing to do...
|
||||
if (!glstate.statebatch.active_tex) {
|
||||
glstate.statebatch.active_tex = texture;
|
||||
} else {
|
||||
if (glstate.statebatch.active_tex_changed) {
|
||||
if(glstate.statebatch.active_tex == texture)
|
||||
return; // nothing to do...
|
||||
flush();
|
||||
}
|
||||
glstate.statebatch.active_tex = texture;
|
||||
glstate.statebatch.active_tex_changed = 1;
|
||||
}
|
||||
if (glstate.list.active) {
|
||||
NewStage(glstate.list.active, STAGE_ACTIVETEX);
|
||||
|
||||
Reference in New Issue
Block a user