From 47036d4fd4059b14dcf0e906656656f6074fc3de Mon Sep 17 00:00:00 2001 From: Prashant Date: Wed, 25 May 2016 18:09:13 +0530 Subject: [PATCH] BugFix: viewAngle reset in static camera mode --- .../graphics/runTimePostProcessing/scene.C | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/postProcessing/functionObjects/graphics/runTimePostProcessing/scene.C b/src/postProcessing/functionObjects/graphics/runTimePostProcessing/scene.C index 727300d077..d471f7981e 100644 --- a/src/postProcessing/functionObjects/graphics/runTimePostProcessing/scene.C +++ b/src/postProcessing/functionObjects/graphics/runTimePostProcessing/scene.C @@ -237,6 +237,15 @@ void Foam::scene::initialise(vtkRenderer* renderer, const word& outputName) renderer->ResetCamera(); + // Restore viewAngle (it might be reset by clipping) + vtkCamera* camera = renderer->GetActiveCamera(); + + if (!parallelProjection_) + { + camera->SetViewAngle(cameraViewAngle_->value(position())); + } + camera->Modified(); + clipActor->VisibilityOff(); } }