| 215 | } |
| 216 | |
| 217 | void FillTextureFromBGRABlock(const TextureRef& texture_ref, const TextCanvas::MemoryBlock& bgra_block, int width, int height) { |
| 218 | Textures::Instance()->bindTexture(texture_ref); |
| 219 | glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, width, height, GL_RGBA, GL_UNSIGNED_BYTE, &bgra_block[0]); |
| 220 | Textures::Instance()->GenerateMipmap(texture_ref); |
| 221 | } |
| 222 | |
| 223 | void TextCanvasTexture::UploadTextCanvasToTexture() { |
| 224 | TextCanvas& text_canvas = impl_->text_canvas; |
no test coverage detected