changed texture formats to float

This commit is contained in:
itsmattkc
2019-03-20 15:04:14 +11:00
parent c5a64adc40
commit 4c1bc0d3c8
2 changed files with 7 additions and 3 deletions
+5 -1
View File
@@ -61,8 +61,12 @@ void FramebufferObject::Create(QOpenGLContext *ctx, int width, int height)
ctx->functions()->glBindTexture(GL_TEXTURE_2D, texture_);
// allocate storage for texture
ctx->functions()->glTexImage2D(
/*ctx->functions()->glTexImage2D(
GL_TEXTURE_2D, 0, GL_RGBA8, width, height, 0, GL_RGBA, GL_UNSIGNED_BYTE, nullptr
);*/
ctx->functions()->glTexImage2D(
GL_TEXTURE_2D, 0, GL_RGBA32F, width, height, 0, GL_RGBA, GL_FLOAT, nullptr
);
// set texture filtering to bilinear