Forcing stride to full size.

This commit is contained in:
Rinnegatamante
2020-10-21 10:22:59 +02:00
parent ba0bd2a200
commit fecea9f821
2 changed files with 5 additions and 7 deletions
+2 -2
View File
@@ -187,9 +187,9 @@ defaultInstanceCB(Geometry *geo, InstanceDataHeader *header, bool32 reinstance)
a->type = GL_FLOAT; a->type = GL_FLOAT;
a->normalized = GL_FALSE; a->normalized = GL_FALSE;
a->offset = stride; a->offset = stride;
stride += 12;
a++; a++;
} }
stride += 12;
// Prelighting // Prelighting
if(isPrelit){ if(isPrelit){
@@ -198,9 +198,9 @@ defaultInstanceCB(Geometry *geo, InstanceDataHeader *header, bool32 reinstance)
a->type = GL_UNSIGNED_BYTE; a->type = GL_UNSIGNED_BYTE;
a->normalized = GL_TRUE; a->normalized = GL_TRUE;
a->offset = stride; a->offset = stride;
stride += 4;
a++; a++;
} }
stride += 4;
// Texture coordinates // Texture coordinates
for(int32 n = 0; n < geo->numTexCoordSets; n++){ for(int32 n = 0; n < geo->numTexCoordSets; n++){
+3 -5
View File
@@ -18,8 +18,6 @@
#include "rwgl3impl.h" #include "rwgl3impl.h"
extern float *gVertexBuffer;
namespace rw { namespace rw {
namespace gl3 { namespace gl3 {
@@ -65,10 +63,10 @@ skinInstanceCB(Geometry *geo, InstanceDataHeader *header, bool32 reinstance)
a->type = GL_FLOAT; a->type = GL_FLOAT;
a->normalized = GL_FALSE; a->normalized = GL_FALSE;
a->offset = stride; a->offset = stride;
stride += 12;
a++; a++;
} }
stride += 12;
// Prelighting // Prelighting
if(isPrelit){ if(isPrelit){
a->index = ATTRIB_COLOR; a->index = ATTRIB_COLOR;
@@ -76,9 +74,9 @@ skinInstanceCB(Geometry *geo, InstanceDataHeader *header, bool32 reinstance)
a->type = GL_UNSIGNED_BYTE; a->type = GL_UNSIGNED_BYTE;
a->normalized = GL_TRUE; a->normalized = GL_TRUE;
a->offset = stride; a->offset = stride;
stride += 4;
a++; a++;
} }
stride += 4;
// Texture coordinates // Texture coordinates
for(int32 n = 0; n < geo->numTexCoordSets; n++){ for(int32 n = 0; n < geo->numTexCoordSets; n++){