added camera pan for parallax and improved line drawing with preview line

This commit is contained in:
2017-05-06 23:22:34 +01:00
parent 427dd66976
commit f800df6cf5
10 changed files with 183 additions and 22 deletions

View File

@@ -47,6 +47,20 @@ protected:
}
};
class LineSegment : public Shape
{
void create_impl(GLushort* idx, vertex_t* vertices);
public:
bool create()
{
static GLushort idx[2];
static vertex_t vertices[2];
create_impl(idx, vertices);
return create_buffers(idx, vertices, sizeof(idx), sizeof(vertices));
}
void update_vertices(const glm::vec4 data[2]);
};
class Plane : public Shape
{
void create_impl(float w, float h, int div, GLushort* idx, vertex_t* vertices);