diff --git a/src/Graphics/FramebufferTextureFormats.h b/src/Graphics/FramebufferTextureFormats.h index c15b6295e..ec14150e4 100644 --- a/src/Graphics/FramebufferTextureFormats.h +++ b/src/Graphics/FramebufferTextureFormats.h @@ -31,10 +31,11 @@ namespace graphics { DatatypeParam lutType; u32 lutFormatBytes; - InternalColorFormatParam noiseInternalFormat; - ColorFormatParam noiseFormat; - DatatypeParam noiseType; - u32 noiseFormatBytes; + // Used for font atlas + InternalColorFormatParam fontInternalFormat; + ColorFormatParam fontFormat; + DatatypeParam fontType; + u32 fontFormatBytes; virtual ~FramebufferTextureFormats() {} }; diff --git a/src/Graphics/OpenGLContext/opengl_BufferManipulationObjectFactory.cpp b/src/Graphics/OpenGLContext/opengl_BufferManipulationObjectFactory.cpp index 61de0845b..ffbcde6a0 100644 --- a/src/Graphics/OpenGLContext/opengl_BufferManipulationObjectFactory.cpp +++ b/src/Graphics/OpenGLContext/opengl_BufferManipulationObjectFactory.cpp @@ -282,10 +282,10 @@ struct FramebufferTextureFormatsGLES2 : public graphics::FramebufferTextureForma colorFormatBytes = 2; } - noiseInternalFormat = graphics::internalcolorFormat::LUMINANCE; - noiseFormat = graphics::colorFormat::LUMINANCE; - noiseType = GL_UNSIGNED_BYTE; - noiseFormatBytes = 1; + fontInternalFormat = graphics::internalcolorFormat::LUMINANCE; + fontFormat = graphics::colorFormat::LUMINANCE; + fontType = GL_UNSIGNED_BYTE; + fontFormatBytes = 1; } }; @@ -339,10 +339,10 @@ struct FramebufferTextureFormatsGLES3 : public graphics::FramebufferTextureForma lutType = GL_UNSIGNED_INT; lutFormatBytes = 4; - noiseInternalFormat = GL_R8; - noiseFormat = GL_RED; - noiseType = GL_UNSIGNED_BYTE; - noiseFormatBytes = 1; + fontInternalFormat = GL_R8; + fontFormat = GL_RED; + fontType = GL_UNSIGNED_BYTE; + fontFormatBytes = 1; } }; @@ -379,10 +379,10 @@ struct FramebufferTextureFormatsOpenGL : public graphics::FramebufferTextureForm lutType = GL_UNSIGNED_INT; lutFormatBytes = 4; - noiseInternalFormat = GL_R8; - noiseFormat = GL_RED; - noiseType = GL_UNSIGNED_BYTE; - noiseFormatBytes = 1; + fontInternalFormat = GL_R8; + fontFormat = GL_RED; + fontType = GL_UNSIGNED_BYTE; + fontFormatBytes = 1; } }; diff --git a/src/TextDrawer.cpp b/src/TextDrawer.cpp index c5b39dd79..1c1043fcc 100644 --- a/src/TextDrawer.cpp +++ b/src/TextDrawer.cpp @@ -111,16 +111,16 @@ struct Atlas { m_pTexture->mirrorT = 0; m_pTexture->width = w; m_pTexture->height = h; - m_pTexture->textureBytes = m_pTexture->width * m_pTexture->height * fbTexFormats.noiseFormatBytes; + m_pTexture->textureBytes = m_pTexture->width * m_pTexture->height * fbTexFormats.fontFormatBytes; Context::InitTextureParams initParams; initParams.handle = m_pTexture->name; initParams.textureUnitIndex = textureIndices::Tex[0]; initParams.width = w; initParams.height = h; - initParams.internalFormat = fbTexFormats.noiseInternalFormat; - initParams.format = fbTexFormats.noiseFormat; - initParams.dataType = fbTexFormats.noiseType; + initParams.internalFormat = fbTexFormats.fontInternalFormat; + initParams.format = fbTexFormats.fontFormat; + initParams.dataType = fbTexFormats.fontType; gfxContext.init2DTexture(initParams); Context::TexParameters setParams;