gldraw:: offset and texture_offset are now separate

This commit is contained in:
Zeno Rogue
2019-09-12 22:38:47 +02:00
parent eed92c5b96
commit 5116d745c4
5 changed files with 13 additions and 26 deletions
+3 -3
View File
@@ -661,15 +661,15 @@ void vertices(const vector<glvertex>& v, int vshift = 0) {
#endif
}
void vertices_texture(const vector<glvertex>& v, const vector<glvertex>& t, int vshift = 0) {
void vertices_texture(const vector<glvertex>& v, const vector<glvertex>& t, int vshift = 0, int tshift = 0) {
#if CAP_VERTEXBUFFER
// not implemented!
#else
vertices(v, vshift);
#if CAP_SHADER
glVertexAttribPointer(aTexture, SHDIM, GL_FLOAT, GL_FALSE, sizeof(glvertex), &t[0]);
glVertexAttribPointer(aTexture, SHDIM, GL_FLOAT, GL_FALSE, sizeof(glvertex), &t[tshift]);
#else
glTexCoordPointer(SHDIM, GL_FLOAT, 0, &v[0]);
glTexCoordPointer(SHDIM, GL_FLOAT, 0, &t[tshift]);
#endif
#endif
}