@@ -285,7 +285,6 @@ void vtkF3DRenderer::ReleaseGraphicsResources(vtkWindow* w)
285285void vtkF3DRenderer::Initialize ()
286286{
287287 this ->OriginalLightIntensities .clear ();
288- this ->OriginalBackfaceCulling .clear ();
289288 this ->RemoveAllViewProps ();
290289 this ->RemoveAllLights ();
291290
@@ -2506,6 +2505,20 @@ void vtkF3DRenderer::ConfigureActorsProperties()
25062505
25072506 for (const auto & coloring : this ->Importer ->GetColoringActorsAndMappers ())
25082507 {
2508+ vtkProperty* prop = coloring.Actor ->GetProperty ();
2509+ vtkProperty* origProp = coloring.OriginalActor ->GetProperty ();
2510+
2511+ if (setBackfaceCulling)
2512+ {
2513+ prop->SetBackfaceCulling (backfaceCulling);
2514+ origProp->SetBackfaceCulling (backfaceCulling);
2515+ }
2516+ else
2517+ {
2518+ prop->SetBackfaceCulling (coloring.OriginalProperty ->GetBackfaceCulling ());
2519+ origProp->SetBackfaceCulling (coloring.OriginalProperty ->GetBackfaceCulling ());
2520+ }
2521+
25092522 if (this ->EdgeVisible .has_value ())
25102523 {
25112524 coloring.Actor ->GetProperty ()->SetEdgeVisibility (this ->EdgeVisible .value ());
@@ -2523,25 +2536,6 @@ void vtkF3DRenderer::ConfigureActorsProperties()
25232536 coloring.Actor ->GetProperty ()->SetPointSize (this ->PointSize .value ());
25242537 coloring.OriginalActor ->GetProperty ()->SetPointSize (this ->PointSize .value ());
25252538 }
2526-
2527- vtkProperty* prop = coloring.Actor ->GetProperty ();
2528- vtkProperty* origProp = coloring.OriginalActor ->GetProperty ();
2529- auto it = this ->OriginalBackfaceCulling .find (prop);
2530- if (it == this ->OriginalBackfaceCulling .end ())
2531- {
2532- this ->OriginalBackfaceCulling [prop] = (prop->GetBackfaceCulling () != 0 );
2533- }
2534-
2535- if (setBackfaceCulling)
2536- {
2537- prop->SetBackfaceCulling (backfaceCulling);
2538- origProp->SetBackfaceCulling (backfaceCulling);
2539- }
2540- else
2541- {
2542- prop->SetBackfaceCulling (this ->OriginalBackfaceCulling [prop]);
2543- origProp->SetBackfaceCulling (this ->OriginalBackfaceCulling [prop]);
2544- }
25452539
25462540 if (surfaceColor)
25472541 {
0 commit comments