mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-24 17:10:36 +00:00
a (slow) vertices_texture implemented with CAP_VERTEXBUFFER
This commit is contained in:
parent
1a411f0ebf
commit
b4e700c455
@ -734,7 +734,13 @@ void vertices(const vector<glvertex>& v, 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!
|
||||
int q = min(isize(v)-vshift, isize(t)-tshift);
|
||||
vector<textured_vertex> tv(q);
|
||||
for(int i=0; i<q; i++)
|
||||
tv[i].coords = v[vshift+i],
|
||||
tv[i].texture[0] = t[tshift+i][0],
|
||||
tv[i].texture[1] = t[tshift+i][1];
|
||||
prepare(tv);
|
||||
#else
|
||||
vertices(v, vshift);
|
||||
WITHSHADER(
|
||||
|
Loading…
Reference in New Issue
Block a user