diff options
author | Yann Herklotz <ymherklotz@gmail.com> | 2017-12-30 19:57:11 +0000 |
---|---|---|
committer | Yann Herklotz <ymherklotz@gmail.com> | 2017-12-30 19:57:11 +0000 |
commit | 943e3a5bc98ebcc2aa1b1d576700f7c4010c143c (patch) | |
tree | 7af8e73021375a9f4cae7d8fcc4c98f57ad8a215 /yage/data/texture.h | |
parent | 3ebcb9c134aabd33c1b165a263b1c8c80c5266f6 (diff) | |
download | YAGE-943e3a5bc98ebcc2aa1b1d576700f7c4010c143c.tar.gz YAGE-943e3a5bc98ebcc2aa1b1d576700f7c4010c143c.zip |
[Code] Adding support for multiple textures.
Diffstat (limited to 'yage/data/texture.h')
-rw-r--r-- | yage/data/texture.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/yage/data/texture.h b/yage/data/texture.h index aec7b906..81b2f004 100644 --- a/yage/data/texture.h +++ b/yage/data/texture.h @@ -18,11 +18,13 @@ struct Texture { GLuint id; int width; int height; + int x; + int y; - Texture() : id(0), width(0), height(0) {} + Texture() : id(0), width(0), height(0), x(0), y(0) {} - Texture(GLuint id_i, int width_i, int height_i) - : id(id_i), width(width_i), height(height_i) + Texture(GLuint id_i, int width_i, int height_i, int x_i = 1, int y_i = 1) + : id(id_i), width(width_i), height(height_i), x(x_i), y(y_i) { } }; |