Skip to content
This repository has been archived by the owner on Oct 3, 2020. It is now read-only.

OpenGL doesn't like textures being pushed around #11

Open
luitzenhietkamp opened this issue Mar 20, 2019 · 0 comments
Open

OpenGL doesn't like textures being pushed around #11

luitzenhietkamp opened this issue Mar 20, 2019 · 0 comments

Comments

@luitzenhietkamp
Copy link

luitzenhietkamp commented Mar 20, 2019

The solution is to change the loadTexture function. The following should do the trick:

void TextureManager::loadTexture(const std::string& name, const std::string& filename) {
	/* Create the texture in the std::map, then load the texture */
	textures.emplace(name, sf::Texture());
	this->textures[name].loadFromFile(filename);

	return;
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant