diff --git a/src/Texture.h b/src/Texture.h index a0540d47f..18c2003e1 100644 --- a/src/Texture.h +++ b/src/Texture.h @@ -108,10 +108,13 @@ template class Texture { /** * @brief Constructor + * @param target Target, e.g. GL_TEXTURE_2D. If not set, target is + * based on dimension count (GL_TEXTURE_1D, GL_TEXTURE_2D, + * GL_TEXTURE_3D). * * Creates one OpenGL texture. */ - inline Texture(): target(GL_TEXTURE_1D + dimensions - 1) { + inline Texture(GLenum target = GL_TEXTURE_1D + dimensions - 1): target(target) { glGenTextures(1, &texture); }