| 757 | } |
| 758 | |
| 759 | void Textures::subImage(const TextureRef& tex_ref, void* data) { |
| 760 | if (tex_ref.valid()) { |
| 761 | bindTexture(tex_ref); |
| 762 | Texture& texture = textures[tex_ref.id]; |
| 763 | |
| 764 | glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, texture.width, texture.height, texture.format, GL_UNSIGNED_BYTE, data); |
| 765 | } else { |
| 766 | LOGE << "Unable to load data to texture." << std::endl; |
| 767 | } |
| 768 | } |
| 769 | |
| 770 | void Textures::subImage(const TextureRef& destination, const TextureRef& source, int xoffset, int yoffset) { |
| 771 | if (destination.valid() && source.valid()) { |
no test coverage detected