From 661073576254a203fa497fb4c2f550dc269cd5de Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Tue, 4 Oct 2016 11:34:44 +0300 Subject: [PATCH] Add new matrix manipulation functions to VertexBuilder For symmetry with Renderer. --- source/vertexbuilder.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/source/vertexbuilder.h b/source/vertexbuilder.h index 998f7a6c..49f0dcf5 100644 --- a/source/vertexbuilder.h +++ b/source/vertexbuilder.h @@ -33,6 +33,16 @@ public: virtual ~VertexBuilder() { } + void set_matrix(const Matrix &m) + { mtx = m; } + + void transform(const Matrix &m) + { mtx *= m; } + + const Matrix &get_matrix() const + { return mtx.top(); } + + // Deprecated MatrixStack &matrix() { return mtx; } -- 2.43.0