| 89 | } |
| 90 | |
| 91 | void TextureAtlas::DrawToAtlasNode(const std::string& rel_path, const AtlasNodeTree::AtlasNode& node) { |
| 92 | TextureAssetRef tex = Engine::Instance()->GetAssetManager()->LoadSync<TextureAsset>(rel_path); |
| 93 | |
| 94 | if (!rel_path.empty()) { |
| 95 | Textures::Instance()->subImage(atlas_texture, tex->GetTextureRef(), node.pos[0], node.pos[1]); |
| 96 | } else { |
| 97 | // Texture::Instance()->subImageTestPattern( atlas_texture, node.pos[0], node.pos[1] ); |
| 98 | } |
| 99 | } |
| 100 | |
| 101 | void TextureAtlas::Draw() { |
| 102 | // Let's load one texture per frame to even out the load a little between frames. |
nothing calls this directly
no test coverage detected