ECS/Project/Project/Resources/ResourceManager/TextureResourceManager/TextureResourceManager.cpp
//	Add a Texture, specified by name.
Add a Texture, specified by name.
Add a Texture specified by name .
void TextureResourceManager::addTexture(std::string newTextureName, std::shared_ptr<TextureData> newTextureData)
{
	auto textureIterator = mapNameToTextureData.find(newTextureName);
	if (textureIterator != mapNameToTextureData.end())
	{
	}
	else
	{
		mapNameToTextureData.insert(std::make_pair(newTextureName, newTextureData));
		std::shared_ptr<ResourceEvent> newEvent = std::make_shared<ResourceEvent>(ResourceType::TEXTURE_RESOURCE, ResourceEventType::RESOURCE_ADDED, ModuleType::TEXTURE_MANAGER, newTextureName, newTextureData);
		getDispatcher()->dispatchToEventQueue(newEvent);
	}
}
void TextureResourceManager :: addTexture ( std :: string newTextureName , std :: shared_ptr < TextureData > newTextureData ) { auto textureIterator = mapNameToTextureData . find ( newTextureName ) ; if ( textureIterator != mapNameToTextureData . end ( ) ) { } else { mapNameToTextureData . insert ( std :: make_pair ( newTextureName , newTextureData ) ) ; std :: shared_ptr < ResourceEvent > newEvent = std :: make_shared < ResourceEvent > ( ResourceType :: TEXTURE_RESOURCE , ResourceEventType :: RESOURCE_ADDED , ModuleType :: TEXTURE_MANAGER , newTextureName , newTextureData ) ; getDispatcher ( ) -> dispatchToEventQueue ( newEvent ) ; } }
Add a Texture, specified by name.
Add a Texture specified by name .
//	Find the Texture. //	TO DO //	Throw Geometry already present error. //	Insert the Texture Data, under the appropriate name. //	Create the new Texture Resource. //	Dispatch the creation to the EventQueue.