aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
m---------depends/mgl0
-rw-r--r--include/mglpp/graphics/Sprite.hpp1
-rw-r--r--src/graphics/Sprite.cpp4
3 files changed, 5 insertions, 0 deletions
diff --git a/depends/mgl b/depends/mgl
-Subproject 1de5e22423bee66769966f21a4c256a0011aba8
+Subproject f680ab5c3798b730e2e4efb7363ca15074e0499
diff --git a/include/mglpp/graphics/Sprite.hpp b/include/mglpp/graphics/Sprite.hpp
index 67f7cad..6fc7938 100644
--- a/include/mglpp/graphics/Sprite.hpp
+++ b/include/mglpp/graphics/Sprite.hpp
@@ -25,6 +25,7 @@ namespace mgl {
void set_scale(vec2f scale);
void set_scale(float scale);
void set_size(vec2f size);
+ void set_width(float width);
void set_height(float height);
void set_rotation(float degrees);
void set_origin(vec2f origin);
diff --git a/src/graphics/Sprite.cpp b/src/graphics/Sprite.cpp
index de9e96c..4d5d181 100644
--- a/src/graphics/Sprite.cpp
+++ b/src/graphics/Sprite.cpp
@@ -51,6 +51,10 @@ namespace mgl {
mgl_sprite_set_size(&sprite, *(mgl_vec2f*)&size);
}
+ void Sprite::set_width(float width) {
+ mgl_sprite_set_width(&sprite, width);
+ }
+
void Sprite::set_height(float height) {
mgl_sprite_set_height(&sprite, height);
}