From fd09071c29452bdfea2c519f0defbffebee42f4c Mon Sep 17 00:00:00 2001 From: Piotr Dziwinski Date: Sat, 22 Sep 2012 14:40:13 +0200 Subject: Data dir paths - changed access to paths in data directory in CApplication - models now load from data directory --- src/graphics/engine/engine.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'src/graphics/engine/engine.cpp') diff --git a/src/graphics/engine/engine.cpp b/src/graphics/engine/engine.cpp index b737555..beb7508 100644 --- a/src/graphics/engine/engine.cpp +++ b/src/graphics/engine/engine.cpp @@ -210,7 +210,6 @@ CEngine::CEngine(CInstanceManager *iMan, CApplication *app) m_lastFrameTime = CreateTimeStamp(); m_currentFrameTime = CreateTimeStamp(); - m_texPath = "textures/"; m_defaultTexParams.format = TEX_IMG_AUTO; m_defaultTexParams.mipmap = true; m_defaultTexParams.minFilter = TEX_MIN_FILTER_LINEAR_MIPMAP_LINEAR; @@ -497,11 +496,6 @@ Math::IntPoint CEngine::InterfaceToWindowSize(Math::Point size) static_cast(size.y * m_size.y)); } -std::string CEngine::GetTextureDir() -{ - return m_texPath; -} - void CEngine::AddStatisticTriangle(int count) { m_statisticTriangle += count; @@ -2108,7 +2102,7 @@ Texture CEngine::CreateTexture(const std::string& texName, const TextureCreatePa // TODO: detect alpha channel? CImage img; - if (! img.Load(m_app->GetDataFilePath(m_texPath, texName))) + if (! img.Load(m_app->GetDataFilePath(DIR_TEXTURE, texName))) { std::string error = img.GetError(); GetLogger()->Error("Couldn't load texture '%s': %s, blacklisting\n", texName.c_str(), error.c_str()); -- cgit v1.2.3-1-g7c22