LLWaterParamSet Class Reference

A class representing a set of parameter values for the Water shaders. More...

#include <llwaterparamset.h>

Collaboration diagram for LLWaterParamSet:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 LLWaterParamSet ()
void update (LLGLSLShader *shader) const
 Bind this set of parameter values to the uniforms of a particular shader.
void setAll (const LLSD &val)
 set the total llsd
const LLSDgetAll ()
 get the total llsd
void set (const char *paramName, float x)
void set (const char *paramName, float x, float y)
void set (const char *paramName, float x, float y, float z)
void set (const char *paramName, float x, float y, float z, float w)
void set (const char *paramName, const float *val)
void set (const char *paramName, const LLVector4 &val)
void set (const char *paramName, const LLColor4 &val)
LLVector4 getVector4 (const char *paramName, bool &error)
LLVector3 getVector3 (const char *paramName, bool &error)
LLVector2 getVector2 (const char *paramName, bool &error)
F32 getFloat (const char *paramName, bool &error)
void mix (LLWaterParamSet &src, LLWaterParamSet &dest, F32 weight)

Public Attributes

LLString mName

Private Attributes

LLSD mParamValues

Friends

class LLWaterParamManager


Detailed Description

A class representing a set of parameter values for the Water shaders.

Definition at line 46 of file llwaterparamset.h.


Constructor & Destructor Documentation

LLWaterParamSet::LLWaterParamSet ( void   ) 

Definition at line 49 of file llwaterparamset.cpp.

References LLSD::append(), DEFAULT_WATER_NORMAL, LLSD::emptyArray(), LLSD::insert(), and mParamValues.

Here is the call graph for this function:


Member Function Documentation

void LLWaterParamSet::update ( LLGLSLShader shader  )  const

Bind this set of parameter values to the uniforms of a particular shader.

void LLWaterParamSet::setAll ( const LLSD val  )  [inline]

set the total llsd

Definition at line 140 of file llwaterparamset.h.

References LLSD::beginMap(), LLSD::endMap(), LLSD::isMap(), and mParamValues.

Here is the call graph for this function:

const LLSD & LLWaterParamSet::getAll (  )  [inline]

get the total llsd

Definition at line 151 of file llwaterparamset.h.

References mParamValues.

void LLWaterParamSet::set ( const char *  paramName,
float  x 
)

Set a float parameter.

Parameters:
paramName The name of the parameter to set.
x The float value to set.

Definition at line 90 of file llwaterparamset.cpp.

References mParamValues.

Referenced by WaterExpFloatControl::update(), WaterFloatControl::update(), WaterVector2Control::update(), WaterVector3Control::update(), and WaterColorControl::update().

Here is the caller graph for this function:

void LLWaterParamSet::set ( const char *  paramName,
float  x,
float  y 
)

Set a float2 parameter.

Parameters:
paramName The name of the parameter to set.
x The x component's value to set.
y The y component's value to set.

Definition at line 106 of file llwaterparamset.cpp.

References mParamValues.

void LLWaterParamSet::set ( const char *  paramName,
float  x,
float  y,
float  z 
)

Set a float3 parameter.

Parameters:
paramName The name of the parameter to set.
x The x component's value to set.
y The y component's value to set.
z The z component's value to set.

Definition at line 111 of file llwaterparamset.cpp.

References mParamValues.

void LLWaterParamSet::set ( const char *  paramName,
float  x,
float  y,
float  z,
float  w 
)

Set a float4 parameter.

Parameters:
paramName The name of the parameter to set.
x The x component's value to set.
y The y component's value to set.
z The z component's value to set.
w The w component's value to set.

Definition at line 118 of file llwaterparamset.cpp.

References mParamValues.

void LLWaterParamSet::set ( const char *  paramName,
const float *  val 
)

Set a float4 parameter.

Parameters:
paramName The name of the parameter to set.
val An array of the 4 float values to set the parameter to.

Definition at line 126 of file llwaterparamset.cpp.

References mParamValues.

void LLWaterParamSet::set ( const char *  paramName,
const LLVector4 val 
)

Set a float4 parameter.

Parameters:
paramName The name of the parameter to set.
val A struct of the 4 float values to set the parameter to.

Definition at line 134 of file llwaterparamset.cpp.

References mParamValues, and LLVector4::mV.

void LLWaterParamSet::set ( const char *  paramName,
const LLColor4 val 
)

Set a float4 parameter.

Parameters:
paramName The name of the parameter to set.
val A struct of the 4 float values to set the parameter to.

Definition at line 142 of file llwaterparamset.cpp.

References mParamValues, and LLColor4::mV.

LLVector4 LLWaterParamSet::getVector4 ( const char *  paramName,
bool &  error 
)

Get a float4 parameter.

Parameters:
paramName The name of the parameter to set.
error A flag to set if it's not the proper return type

Definition at line 150 of file llwaterparamset.cpp.

References LLSD::get(), LLSD::isArray(), mParamValues, LLVector4::mV, and LLSD::size().

Referenced by LLWaterParamManager::getFogColor(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector3 LLWaterParamSet::getVector3 ( const char *  paramName,
bool &  error 
)

Get a float3 parameter.

Parameters:
paramName The name of the parameter to set.
error A flag to set if it's not the proper return type

Definition at line 171 of file llwaterparamset.cpp.

References LLSD::get(), LLSD::isArray(), mParamValues, LLVector3::mV, and LLSD::size().

Referenced by LLWaterParamManager::getNormalScale(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector2 LLWaterParamSet::getVector2 ( const char *  paramName,
bool &  error 
)

Get a float2 parameter.

Parameters:
paramName The name of the parameter to set.
error A flag to set if it's not the proper return type

Definition at line 191 of file llwaterparamset.cpp.

References LLSD::get(), LLSD::isArray(), mParamValues, LLVector2::mV, and LLSD::size().

Referenced by LLWaterParamManager::getWave1Dir(), LLWaterParamManager::getWave2Dir(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLWaterParamSet::getFloat ( const char *  paramName,
bool &  error 
)

Get an integer parameter

Parameters:
paramName The name of the parameter to set.
error A flag to set if it's not the proper return type

Definition at line 211 of file llwaterparamset.cpp.

References LLSD::asReal(), LLSD::get(), LLSD::isArray(), LLSD::isReal(), mParamValues, and LLSD::size().

Referenced by LLWaterParamManager::getBlurMultiplier(), LLWaterParamManager::getFogDensity(), LLWaterParamManager::getFresnelOffset(), LLWaterParamManager::getFresnelScale(), LLWaterParamManager::getScaleAbove(), LLWaterParamManager::getScaleBelow(), LLWaterParamManager::propagateParameters(), and LLFloaterWater::syncMenu().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLWaterParamSet::mix ( LLWaterParamSet src,
LLWaterParamSet dest,
F32  weight 
)

interpolate two parameter sets

Parameters:
src The parameter set to start with
dest The parameter set to end with
weight The amount to interpolate


Friends And Related Function Documentation

friend class LLWaterParamManager [friend]

Definition at line 48 of file llwaterparamset.h.


Member Data Documentation


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

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