Beispiel #1
0
void LLFloaterWater::onExpFloatControlMoved(LLUICtrl* ctrl, void* userData)
{
	LLSliderCtrl* sldrCtrl = static_cast<LLSliderCtrl*>(ctrl);
	WaterExpFloatControl * expFloatControl = static_cast<WaterExpFloatControl *>(userData);

	F32 val = sldrCtrl->getValueF32();
	expFloatControl->mExp = val;
	LLWaterParamManager::instance()->setDensitySliderValue(val);

	expFloatControl->update(LLWaterParamManager::instance()->mCurParams);
	LLWaterParamManager::instance()->propagateParameters();
}
Beispiel #2
0
void LLFloaterEnvSettings::onChangeWaterFogDensity(LLUICtrl* ctrl, void* userData)
{
	LLSliderCtrl* sldr;
	sldr = sEnvSettings->getChild<LLSliderCtrl>("EnvWaterFogSlider");
	
	if(NULL == userData)
	{
		return;
	}

	WaterExpFloatControl * expFloatControl = static_cast<WaterExpFloatControl *>(userData);
	
	F32 val = sldr->getValueF32();
	expFloatControl->mExp = val;
	LLWaterParamManager::instance()->setDensitySliderValue(val);

	expFloatControl->update(LLWaterParamManager::instance()->mCurParams);
	LLWaterParamManager::instance()->propagateParameters();
}