fix some shapes generation and draw a grid of shapes for an overview

This commit is contained in:
Omar Mohamed Ali Mudhir
2017-01-16 00:22:44 +00:00
parent de17029e0d
commit baaaf213cc
4 changed files with 89 additions and 45 deletions

View File

@@ -21,7 +21,7 @@ public:
template<int div>
bool create(float w, float h)
{
static GLushort idx[div * div * 6 + 4];
static GLushort idx[div * div * 6 + 8];
static vertex_t vertices[(div+1)*(div+1)];
create_impl(w, h, div, idx, vertices);
return create_buffers(idx, vertices, sizeof(idx), sizeof(vertices));