| 203 | } |
| 204 | |
| 205 | void LightDescription::submitLight( LightState *state, const MatrixF &xfm, LightManager *lm, SimObject *object ) |
| 206 | { |
| 207 | LightInfo *li = state->lightInfo; |
| 208 | |
| 209 | li->setRange( range ); |
| 210 | li->setColor( color ); |
| 211 | li->setCastShadows( castShadows ); |
| 212 | li->setStaticRefreshFreq(mStaticRefreshFreq); |
| 213 | li->setDynamicRefreshFreq(mDynamicRefreshFreq); |
| 214 | li->setTransform( xfm ); |
| 215 | |
| 216 | if ( animationData ) |
| 217 | { |
| 218 | LightAnimState *animState = &state->animState; |
| 219 | |
| 220 | animState->brightness = brightness; |
| 221 | animState->transform = xfm; |
| 222 | animState->color = color; |
| 223 | animState->animationPeriod = animationPeriod; |
| 224 | animState->animationPhase = animationPhase; |
| 225 | |
| 226 | animationData->animate( li, animState ); |
| 227 | } |
| 228 | |
| 229 | lm->registerGlobalLight( li, object ); |
| 230 | } |
| 231 | |
| 232 | void LightDescription::prepRender( SceneRenderState *sceneState, LightState *lightState, const MatrixF &xfm ) |
| 233 | { |
no test coverage detected