@@ -66,8 +66,8 @@ void CLightProjector::set_object (IRenderable* O)
6666 return ;
6767 }
6868
69- const vis_data &vis = O->renderable .visual ->getVisData ();
70- Fvector C; O->renderable .xform .transform_tiny (C,vis.sphere .P );
69+ const vis_data &vis = O->GetRenderData () .visual ->getVisData ();
70+ Fvector C; O->GetRenderData () .xform .transform_tiny (C,vis.sphere .P );
7171 float R = vis.sphere .R ;
7272 float D = C.distance_to (Device.vCameraPosition )+R;
7373
@@ -102,7 +102,7 @@ void CLightProjector::setup (int id)
102102 return ;
103103 }
104104 recv& R = cache[id];
105- float Rd = R.O ->renderable .visual ->getVisData ().sphere .R ;
105+ float Rd = R.O ->GetRenderData () .visual ->getVisData ().sphere .R ;
106106 float dist = R.C .distance_to (Device.vCameraPosition )+Rd;
107107 float factor = _sqr (dist/clipD (Rd))*(1 -ps_r1_lmodel_lerp) + ps_r1_lmodel_lerp;
108108 RCache.set_c (c_xform, R.UVgen );
@@ -145,7 +145,7 @@ void CLightProjector::calculate ()
145145 else if (cache[slot].O !=O) bValid = FALSE ; // not the same object
146146 else {
147147 // seems to be valid
148- Fbox bb; bb.xform (O->renderable .visual ->getVisData ().box ,O->renderable .xform );
148+ Fbox bb; bb.xform (O->GetRenderData () .visual ->getVisData ().box ,O->GetRenderData () .xform );
149149 if (cache[slot].BB .contains (bb)) {
150150 // inside, but maybe timelimit exceeded?
151151 if (Device.dwTimeGlobal > cache[slot].dwTimeValid ) bValid = FALSE ; // timeout
@@ -178,25 +178,25 @@ void CLightProjector::calculate ()
178178 int tid = taskid.back (); taskid.pop_back ();
179179 recv& R = cache [c_it];
180180 IRenderable* O = receivers [tid];
181- const vis_data& vis = O->renderable .visual ->getVisData ();
181+ const vis_data& vis = O->GetRenderData () .visual ->getVisData ();
182182 CROS_impl* LT = (CROS_impl*)O->renderable_ROS ();
183- VERIFY2 (_valid (O->renderable .xform )," Invalid object transformation" );
183+ VERIFY2 (_valid (O->GetRenderData () .xform )," Invalid object transformation" );
184184 VERIFY2 (_valid (vis.sphere .P )," Invalid object's visual sphere" );
185185
186- Fvector C; O->renderable .xform .transform_tiny (C,vis.sphere .P );
186+ Fvector C; O->GetRenderData () .xform .transform_tiny (C,vis.sphere .P );
187187 R.O = O;
188188 R.C = C;
189189 R.C .y += vis.sphere .R *0 .1f ; // . YURA: 0.1 can be more
190- R.BB .xform (vis.box ,O->renderable .xform ).scale (0 .1f );
190+ R.BB .xform (vis.box ,O->GetRenderData () .xform ).scale (0 .1f );
191191 R.dwTimeValid = Device.dwTimeGlobal + ::Random.randI (time_min,time_max);
192192 LT->shadow_recv_slot = c_it;
193193
194194 // Msg ("[%f,%f,%f]-%f",C.C.x,C.C.y,C.C.z,C.O->renderable.visual->vis.sphere.R);
195195 // calculate projection-matrix
196196 Fmatrix mProject ;
197- float p_R = R.O ->renderable .visual ->getVisData ().sphere .R * 1 .1f ;
197+ float p_R = R.O ->GetRenderData () .visual ->getVisData ().sphere .R * 1 .1f ;
198198 // VERIFY2 (p_R>EPS_L,"Object has no physical size");
199- VERIFY3 (p_R>EPS_L," Object has no physical size" , R.O ->renderable .visual ->getDebugName ().c_str ());
199+ VERIFY3 (p_R>EPS_L," Object has no physical size" , R.O ->GetRenderData () .visual ->getDebugName ().c_str ());
200200 float p_hat = p_R/P_cam_dist;
201201 float p_asp = 1 .f ;
202202 float p_near = P_cam_dist-EPS_L;
0 commit comments