LLWaterParamManager Class Reference

WindLight parameter manager class - what controls all the wind light shaders. More...

#include <llwaterparammanager.h>

Collaboration diagram for LLWaterParamManager:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 LLWaterParamManager ()
 ~LLWaterParamManager ()
void loadAllPresets (const LLString &fileName)
 load a preset file
void loadPreset (const LLString &name)
 load an individual preset into the sky
void savePreset (const LLString &name)
 save the parameter presets to file
void propagateParameters (void)
 send the parameters to the shaders
void update (LLViewerCamera *cam)
 update information for the shader
void updateShaderUniforms (LLGLSLShader *shader)
 Update shader uniforms that have changed.
bool addParamSet (const std::string &name, LLWaterParamSet &param)
 add a param to the list
BOOL addParamSet (const std::string &name, LLSD const &param)
 add a param to the list
bool getParamSet (const std::string &name, LLWaterParamSet &param)
 get a param from the list
bool setParamSet (const std::string &name, LLWaterParamSet &param)
 set the param in the list with a new param
bool setParamSet (const std::string &name, LLSD const &param)
 set the param in the list with a new param
bool removeParamSet (const std::string &name, bool delete_from_disk)
bool setNormalMapID (const LLUUID &img)
 set the normap map we want for water
void setDensitySliderValue (F32 val)
LLUUID getNormalMapID (void)
 getters for all the different things water param manager maintains
LLVector2 getWave1Dir (void)
LLVector2 getWave2Dir (void)
F32 getScaleAbove (void)
F32 getScaleBelow (void)
LLVector3 getNormalScale (void)
F32 getFresnelScale (void)
F32 getFresnelOffset (void)
F32 getBlurMultiplier (void)
F32 getFogDensity (void)
LLColor4 getFogColor (void)

Static Public Member Functions

static void initClass (void)
 Perform global initialization for this class.
static void cleanupClass ()
static LLWaterParamManagerinstance ()

Public Attributes

LLWaterParamSet mCurParams
WaterColorControl mFogColor
 Atmospherics.
WaterExpFloatControl mFogDensity
WaterFloatControl mUnderWaterFogMod
WaterVector3Control mNormalScale
 wavelet scales and directions
WaterVector2Control mWave1Dir
WaterVector2Control mWave2Dir
WaterFloatControl mFresnelScale
WaterFloatControl mFresnelOffset
WaterFloatControl mScaleAbove
WaterFloatControl mScaleBelow
WaterFloatControl mBlurMultiplier
std::map< std::string,
LLWaterParamSet
mParamList
F32 mDensitySliderValue

Private Attributes

LLVector4 mWaterPlane
F32 mWaterFogKS

Static Private Attributes

static LLWaterParamManagersInstance = NULL


Detailed Description

WindLight parameter manager class - what controls all the wind light shaders.

Definition at line 220 of file llwaterparammanager.h.


Constructor & Destructor Documentation

LLWaterParamManager::LLWaterParamManager (  ) 

Definition at line 66 of file llwaterparammanager.cpp.

Referenced by instance().

Here is the caller graph for this function:

LLWaterParamManager::~LLWaterParamManager (  ) 

Definition at line 83 of file llwaterparammanager.cpp.


Member Function Documentation

void LLWaterParamManager::loadAllPresets ( const LLString fileName  ) 

load a preset file

Definition at line 87 of file llwaterparammanager.cpp.

References addParamSet(), LLSD::emptyMap(), gDirUtilp, LLDir::getExpandedFilename(), LLDir::getNextFileInDir(), LL_DEBUGS2, LL_ENDL, LL_INFOS2, LL_PATH_APP_SETTINGS, NULL, and LLSDSerialize::SIZE_UNLIMITED.

Referenced by instance().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLWaterParamManager::loadPreset ( const LLString name  ) 

load an individual preset into the sky

Definition at line 130 of file llwaterparammanager.cpp.

References addParamSet(), LLSD::emptyMap(), gDirUtilp, LLDir::getExpandedFilename(), getParamSet(), LL_PATH_APP_SETTINGS, llendl, llinfos, llwarns, mCurParams, mParamList, NULL, propagateParameters(), setParamSet(), and LLSDSerialize::SIZE_UNLIMITED.

Referenced by LLFloaterWater::onChangePresetName().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLWaterParamManager::savePreset ( const LLString name  ) 

save the parameter presets to file

Definition at line 174 of file llwaterparammanager.cpp.

References LLSD::emptyMap(), gDirUtilp, LLDir::getExpandedFilename(), LL_PATH_APP_SETTINGS, mParamList, NULL, LLSDFormatter::OPTIONS_PRETTY, and propagateParameters().

Referenced by LLFloaterWater::saveAlertCallback().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLWaterParamManager::propagateParameters ( void   ) 

void LLWaterParamManager::update ( LLViewerCamera cam  ) 

void LLWaterParamManager::updateShaderUniforms ( LLGLSLShader shader  ) 

void LLWaterParamManager::initClass ( void   )  [static]

Perform global initialization for this class.

Definition at line 304 of file llwaterparammanager.cpp.

References instance().

Referenced by idle_startup().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLWaterParamManager::cleanupClass ( void   )  [static]

Definition at line 310 of file llwaterparammanager.cpp.

References NULL, and sInstance.

Referenced by LLAppViewer::cleanup().

Here is the caller graph for this function:

bool LLWaterParamManager::addParamSet ( const std::string &  name,
LLWaterParamSet param 
)

add a param to the list

Definition at line 316 of file llwaterparammanager.cpp.

References mParamList.

Referenced by loadAllPresets(), and loadPreset().

Here is the caller graph for this function:

BOOL LLWaterParamManager::addParamSet ( const std::string &  name,
LLSD const &  param 
)

add a param to the list

Definition at line 329 of file llwaterparammanager.cpp.

References FALSE, mParamList, and TRUE.

bool LLWaterParamManager::getParamSet ( const std::string &  name,
LLWaterParamSet param 
)

get a param from the list

Definition at line 344 of file llwaterparammanager.cpp.

References LLWaterParamSet::mName, and mParamList.

Referenced by instance(), and loadPreset().

Here is the caller graph for this function:

bool LLWaterParamManager::setParamSet ( const std::string &  name,
LLWaterParamSet param 
)

set the param in the list with a new param

Definition at line 358 of file llwaterparammanager.cpp.

References mParamList.

Referenced by loadPreset(), and LLFloaterWater::saveAlertCallback().

Here is the caller graph for this function:

bool LLWaterParamManager::setParamSet ( const std::string &  name,
LLSD const &  param 
)

set the param in the list with a new param

Definition at line 365 of file llwaterparammanager.cpp.

References LLSD::isMap(), and mParamList.

Here is the call graph for this function:

bool LLWaterParamManager::removeParamSet ( const std::string &  name,
bool  delete_from_disk 
)

gets rid of a parameter and any references to it returns true if successful

Definition at line 378 of file llwaterparammanager.cpp.

References LLDir::deleteFilesInDir(), gDirUtilp, LLDir::getExpandedFilename(), LL_PATH_APP_SETTINGS, mParamList, and NULL.

Referenced by LLFloaterWater::deleteAlertCallback().

Here is the call graph for this function:

Here is the caller graph for this function:

bool LLWaterParamManager::setNormalMapID ( const LLUUID img  )  [inline]

set the normap map we want for water

Definition at line 339 of file llwaterparammanager.h.

References mCurParams, and LLWaterParamSet::mParamValues.

Referenced by LLFloaterWater::onNormalMapPicked().

Here is the caller graph for this function:

void LLWaterParamManager::setDensitySliderValue ( F32  val  )  [inline]

LLUUID LLWaterParamManager::getNormalMapID ( void   )  [inline]

getters for all the different things water param manager maintains

Definition at line 334 of file llwaterparammanager.h.

References LLSD::asUUID(), mCurParams, and LLWaterParamSet::mParamValues.

Referenced by LLDrawPoolWater::shade(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector2 LLWaterParamManager::getWave1Dir ( void   )  [inline]

Definition at line 345 of file llwaterparammanager.h.

References LLWaterParamSet::getVector2(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector2 LLWaterParamManager::getWave2Dir ( void   )  [inline]

Definition at line 351 of file llwaterparammanager.h.

References LLWaterParamSet::getVector2(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getScaleAbove ( void   )  [inline]

Definition at line 357 of file llwaterparammanager.h.

References LLWaterParamSet::getFloat(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getScaleBelow ( void   )  [inline]

Definition at line 363 of file llwaterparammanager.h.

References LLWaterParamSet::getFloat(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector3 LLWaterParamManager::getNormalScale ( void   )  [inline]

Definition at line 369 of file llwaterparammanager.h.

References LLWaterParamSet::getVector3(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getFresnelScale ( void   )  [inline]

Definition at line 375 of file llwaterparammanager.h.

References LLWaterParamSet::getFloat(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getFresnelOffset ( void   )  [inline]

Definition at line 381 of file llwaterparammanager.h.

References LLWaterParamSet::getFloat(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getBlurMultiplier ( void   )  [inline]

Definition at line 387 of file llwaterparammanager.h.

References LLWaterParamSet::getFloat(), and mCurParams.

Referenced by LLDrawPoolWater::shade().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamManager::getFogDensity ( void   ) 

Definition at line 403 of file llwaterparammanager.cpp.

References gAgent, LLAgent::getCameraPositionAgent(), LLWaterParamSet::getFloat(), LLAgent::getRegion(), LLViewerRegion::getWaterHeight(), mCurParams, and LLVector3::mV.

Referenced by LLDrawPoolWater::shade(), LLVOSky::updateFog(), and updateShaderUniforms().

Here is the call graph for this function:

Here is the caller graph for this function:

LLColor4 LLWaterParamManager::getFogColor ( void   )  [inline]

Definition at line 393 of file llwaterparammanager.h.

References LLWaterParamSet::getVector4(), and mCurParams.

Referenced by LLDrawPoolWater::prerender(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

LLWaterParamManager * LLWaterParamManager::instance ( void   )  [static]


Member Data Documentation

Atmospherics.

Definition at line 296 of file llwaterparammanager.h.

Referenced by LLFloaterWater::initCallbacks(), and LLFloaterWater::syncMenu().

wavelet scales and directions

Definition at line 301 of file llwaterparammanager.h.

Referenced by LLFloaterWater::initCallbacks(), and LLFloaterWater::syncMenu().

Definition at line 315 of file llwaterparammanager.h.

Referenced by setDensitySliderValue(), and LLDrawPoolWater::shade().

Definition at line 318 of file llwaterparammanager.h.

Referenced by update(), and updateShaderUniforms().

Definition at line 319 of file llwaterparammanager.h.

Referenced by update(), and updateShaderUniforms().

Definition at line 322 of file llwaterparammanager.h.

Referenced by cleanupClass(), and instance().


The documentation for this class was generated from the following files:

Generated on Fri May 16 09:39:02 2008 for SecondLife by  doxygen 1.5.5