#include <llwlparamset.h>
Public Member Functions | |
LLWLParamSet () | |
void | update (LLGLSLShader *shader) const |
Update this set of shader uniforms from the parameter values. | |
void | setAll (const LLSD &val) |
set the total llsd | |
const LLSD & | getAll () |
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 | getVector (const char *paramName, bool &error) |
F32 | getFloat (const char *paramName, bool &error) |
void | setStarBrightness (F32 val) |
F32 | getStarBrightness () |
get the star brightness value; | |
void | setSunAngle (F32 val) |
F32 | getSunAngle () |
void | setEastAngle (F32 val) |
F32 | getEastAngle () |
void | setEnableCloudScrollX (bool val) |
bool | getEnableCloudScrollX () |
get the scroll x enable value; | |
void | setEnableCloudScrollY (bool val) |
bool | getEnableCloudScrollY () |
get the scroll enable y value; | |
void | setCloudScrollX (F32 val) |
F32 | getCloudScrollX () |
get the scroll x enable value; | |
void | setCloudScrollY (F32 val) |
F32 | getCloudScrollY () |
get the scroll enable y value; | |
void | mix (LLWLParamSet &src, LLWLParamSet &dest, F32 weight) |
void | updateCloudScrolling (void) |
Public Attributes | |
LLString | mName |
Private Attributes | |
LLSD | mParamValues |
float | mCloudScrollXOffset |
float | mCloudScrollYOffset |
Friends | |
class | LLWLParamManager |
Definition at line 46 of file llwlparamset.h.
LLWLParamSet::LLWLParamSet | ( | void | ) |
Definition at line 46 of file llwlparamset.cpp.
void LLWLParamSet::update | ( | LLGLSLShader * | shader | ) | const |
Update this set of shader uniforms from the parameter values.
Definition at line 77 of file llwlparamset.cpp.
References LLSD::beginMap(), LLSD::endMap(), i, mCloudScrollXOffset, mCloudScrollYOffset, mParamValues, LLVector4::mV, and LLGLSLShader::uniform4fv().
Referenced by LLWLParamManager::updateShaderUniforms().
void LLWLParamSet::setAll | ( | const LLSD & | val | ) | [inline] |
set the total llsd
Definition at line 181 of file llwlparamset.h.
References LLSD::isMap(), and mParamValues.
const LLSD & LLWLParamSet::getAll | ( | ) | [inline] |
void LLWLParamSet::set | ( | const char * | paramName, | |
float | x | |||
) |
Set a float parameter.
paramName | The name of the parameter to set. | |
x | The float value to set. |
Definition at line 133 of file llwlparamset.cpp.
References mParamValues.
Referenced by LLFloaterEnvSettings::onChangeCloudCoverage(), LLWLParamManager::propagateParameters(), WLFloatControl::update(), and WLColorControl::update().
void LLWLParamSet::set | ( | const char * | paramName, | |
float | x, | |||
float | y | |||
) |
Set a float2 parameter.
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 149 of file llwlparamset.cpp.
References mParamValues.
void LLWLParamSet::set | ( | const char * | paramName, | |
float | x, | |||
float | y, | |||
float | z | |||
) |
Set a float3 parameter.
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 154 of file llwlparamset.cpp.
References mParamValues.
void LLWLParamSet::set | ( | const char * | paramName, | |
float | x, | |||
float | y, | |||
float | z, | |||
float | w | |||
) |
Set a float4 parameter.
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 161 of file llwlparamset.cpp.
References mParamValues.
void LLWLParamSet::set | ( | const char * | paramName, | |
const float * | val | |||
) |
Set a float4 parameter.
paramName | The name of the parameter to set. | |
val | An array of the 4 float values to set the parameter to. |
Definition at line 169 of file llwlparamset.cpp.
References mParamValues.
void LLWLParamSet::set | ( | const char * | paramName, | |
const LLVector4 & | val | |||
) |
Set a float4 parameter.
paramName | The name of the parameter to set. | |
val | A struct of the 4 float values to set the parameter to. |
Definition at line 177 of file llwlparamset.cpp.
References mParamValues, and LLVector4::mV.
void LLWLParamSet::set | ( | const char * | paramName, | |
const LLColor4 & | val | |||
) |
Set a float4 parameter.
paramName | The name of the parameter to set. | |
val | A struct of the 4 float values to set the parameter to. |
Definition at line 185 of file llwlparamset.cpp.
References mParamValues, and LLColor4::mV.
LLVector4 LLWLParamSet::getVector | ( | const char * | paramName, | |
bool & | error | |||
) |
Get a float4 parameter.
paramName | The name of the parameter to set. | |
error | A flag to set if it's not the proper return type |
Definition at line 193 of file llwlparamset.cpp.
References LLSD::get(), LLSD::isArray(), mParamValues, and LLVector4::mV.
Referenced by LLVOSky::initAtmospherics(), and LLFloaterWindLight::syncMenu().
F32 LLWLParamSet::getFloat | ( | const char * | paramName, | |
bool & | error | |||
) |
Get an integer parameter
paramName | The name of the parameter to set. | |
error | A flag to set if it's not the proper return type |
Definition at line 214 of file llwlparamset.cpp.
References LLSD::asReal(), LLSD::get(), LLSD::isArray(), LLSD::isReal(), mParamValues, and LLSD::size().
Referenced by LLDrawPoolWLSky::renderStars(), and LLFloaterWindLight::syncMenu().
void LLWLParamSet::setStarBrightness | ( | F32 | val | ) | [inline] |
set the star's brightness
val | brightness value |
Definition at line 193 of file llwlparamset.h.
References mParamValues.
Referenced by mix(), and LLFloaterWindLight::onStarAlphaMoved().
F32 LLWLParamSet::getStarBrightness | ( | ) | [inline] |
get the star brightness value;
Definition at line 197 of file llwlparamset.h.
References LLSD::asReal(), and mParamValues.
Referenced by mix(), and LLFloaterWindLight::syncMenu().
void LLWLParamSet::setSunAngle | ( | F32 | val | ) |
Definition at line 237 of file llwlparamset.cpp.
References F_TWO_PI, and mParamValues.
Referenced by mix(), and LLFloaterWindLight::onSunMoved().
F32 LLWLParamSet::getSunAngle | ( | ) | [inline] |
Definition at line 201 of file llwlparamset.h.
References LLSD::asReal(), and mParamValues.
Referenced by mix(), LLFloaterWindLight::onSunMoved(), and LLWLParamManager::propagateParameters().
void LLWLParamSet::setEastAngle | ( | F32 | val | ) |
Definition at line 251 of file llwlparamset.cpp.
References F_TWO_PI, and mParamValues.
Referenced by mix(), and LLFloaterWindLight::onSunMoved().
F32 LLWLParamSet::getEastAngle | ( | ) | [inline] |
Definition at line 205 of file llwlparamset.h.
References LLSD::asReal(), and mParamValues.
Referenced by mix(), LLFloaterWindLight::onSunMoved(), and LLWLParamManager::propagateParameters().
void LLWLParamSet::setEnableCloudScrollX | ( | bool | val | ) | [inline] |
set the cloud scroll x enable value
val | scroll x value |
Definition at line 210 of file llwlparamset.h.
References mParamValues.
Referenced by LLFloaterWindLight::onCloudScrollXToggled().
bool LLWLParamSet::getEnableCloudScrollX | ( | ) | [inline] |
get the scroll x enable value;
Definition at line 214 of file llwlparamset.h.
References LLSD::asBoolean(), and mParamValues.
Referenced by LLFloaterWindLight::syncMenu(), and updateCloudScrolling().
void LLWLParamSet::setEnableCloudScrollY | ( | bool | val | ) | [inline] |
set the star's brightness
val | scroll y bool value |
Definition at line 218 of file llwlparamset.h.
References mParamValues.
Referenced by LLFloaterWindLight::onCloudScrollYToggled().
bool LLWLParamSet::getEnableCloudScrollY | ( | ) | [inline] |
get the scroll enable y value;
Definition at line 222 of file llwlparamset.h.
References LLSD::asBoolean(), and mParamValues.
Referenced by LLFloaterWindLight::syncMenu(), and updateCloudScrolling().
void LLWLParamSet::setCloudScrollX | ( | F32 | val | ) | [inline] |
set the cloud scroll x enable value
val | scroll x value |
Definition at line 227 of file llwlparamset.h.
References mParamValues.
Referenced by LLFloaterWindLight::onCloudScrollXMoved().
F32 LLWLParamSet::getCloudScrollX | ( | ) | [inline] |
get the scroll x enable value;
Definition at line 231 of file llwlparamset.h.
References LLSD::asReal(), and mParamValues.
Referenced by LLFloaterWindLight::syncMenu(), and updateCloudScrolling().
void LLWLParamSet::setCloudScrollY | ( | F32 | val | ) | [inline] |
set the star's brightness
val | scroll y bool value |
Definition at line 235 of file llwlparamset.h.
References mParamValues.
Referenced by LLFloaterWindLight::onCloudScrollYMoved().
F32 LLWLParamSet::getCloudScrollY | ( | ) | [inline] |
get the scroll enable y value;
Definition at line 239 of file llwlparamset.h.
References LLSD::asReal(), and mParamValues.
Referenced by LLFloaterWindLight::syncMenu(), and updateCloudScrolling().
void LLWLParamSet::mix | ( | LLWLParamSet & | src, | |
LLWLParamSet & | dest, | |||
F32 | weight | |||
) |
interpolate two parameter sets
src | The parameter set to start with | |
dest | The parameter set to end with | |
weight | The amount to interpolate |
TODO masking will do this later
Definition at line 265 of file llwlparamset.cpp.
References LLSD::asReal(), LLSD::beginMap(), LLSD::endMap(), F_PI, getEastAngle(), getStarBrightness(), getSunAngle(), LLSD::has(), i, llassert, mParamValues, setEastAngle(), setStarBrightness(), setSunAngle(), and LLSD::size().
Referenced by LLWLAnimator::update().
void LLWLParamSet::updateCloudScrolling | ( | void | ) |
Definition at line 389 of file llwlparamset.cpp.
References getCloudScrollX(), getCloudScrollY(), LLTimer::getElapsedTimeAndResetF64(), getEnableCloudScrollX(), getEnableCloudScrollY(), mCloudScrollXOffset, and mCloudScrollYOffset.
Referenced by LLWLParamManager::update().
friend class LLWLParamManager [friend] |
Definition at line 48 of file llwlparamset.h.
Definition at line 51 of file llwlparamset.h.
Referenced by LLWLParamManager::getParamSet(), LLFloaterWindLight::onSavePreset(), and LLFloaterWindLight::saveAlertCallback().
LLSD LLWLParamSet::mParamValues [private] |
Definition at line 55 of file llwlparamset.h.
Referenced by getAll(), getCloudScrollX(), getCloudScrollY(), getEastAngle(), getEnableCloudScrollX(), getEnableCloudScrollY(), getFloat(), getStarBrightness(), getSunAngle(), getVector(), mix(), set(), setAll(), setCloudScrollX(), setCloudScrollY(), setEastAngle(), setEnableCloudScrollX(), setEnableCloudScrollY(), setStarBrightness(), setSunAngle(), and update().
float LLWLParamSet::mCloudScrollXOffset [private] |
float LLWLParamSet::mCloudScrollYOffset [private] |