2
--------------------------------------------------------------------------------
3
This source file is part of Hydrax.
6
Copyright (C) 2008 Xavier Vergu�n Gonz�lez <xavierverguin@hotmail.com>
9
This program is free software; you can redistribute it and/or modify it under
10
the terms of the GNU Lesser General Public License as published by the Free Software
11
Foundation; either version 2 of the License, or (at your option) any later
14
This program is distributed in the hope that it will be useful, but WITHOUT
15
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
16
FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
18
You should have received a copy of the GNU Lesser General Public License along with
19
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
20
Place - Suite 330, Boston, MA 02111-1307, USA, or go to
21
http://www.gnu.org/copyleft/lesser.txt.
22
--------------------------------------------------------------------------------
27
namespace Hydrax{namespace Noise
29
Noise::Noise(const Ogre::String &Name, const bool& GPUNormalMapSupported)
32
, mGPUNormalMapSupported(GPUNormalMapSupported)
33
, mGPUNormalMapResourcesCreated(false)
51
bool Noise::createGPUNormalMapResources(GPUNormalMapManager *g)
53
if (mGPUNormalMapSupported && !mGPUNormalMapResourcesCreated)
55
mGPUNormalMapResourcesCreated = true;
65
void Noise::removeGPUNormalMapResources(GPUNormalMapManager *g)
67
if (mGPUNormalMapSupported && mGPUNormalMapResourcesCreated)
69
mGPUNormalMapResourcesCreated = false;
75
void Noise::saveCfg(Ogre::String &Data)
77
Data += "#Noise options\n";
78
Data += "Noise="+mName+"\n\n";
81
bool Noise::loadCfg(const Ogre::ConfigFile &CfgFile)
83
if (CfgFile.getSetting("Noise") == mName)
b'\\ No newline at end of file'