From 36933614220f4751a65ee0d299b4e5517cc012e9 Mon Sep 17 00:00:00 2001 From: vro Date: Tue, 17 Dec 2013 12:27:29 +0400 Subject: [PATCH] 0024166: Unable to create file with "Save" menu of voxeldemo Qt sample Turning on the light to display the shapes of the sample. --- samples/qt/VoxelDemo/src/Viewer.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/samples/qt/VoxelDemo/src/Viewer.cpp b/samples/qt/VoxelDemo/src/Viewer.cpp index 9d4d20a1e6..f4615df138 100644 --- a/samples/qt/VoxelDemo/src/Viewer.cpp +++ b/samples/qt/VoxelDemo/src/Viewer.cpp @@ -15,6 +15,8 @@ #include #include #include +#include +#include static Handle(Graphic3d_GraphicDriver) Viewer_aGraphicDriver; @@ -72,6 +74,9 @@ Viewer::Viewer(QWidget* parent):QWidget(parent) setFocusPolicy( Qt::StrongFocus ); setAttribute( Qt::WA_PaintOnScreen ); setAttribute( Qt::WA_NoSystemBackground ); + + aViewer->SetLightOn(new V3d_DirectionalLight(aViewer, V3d_XnegYnegZneg, Quantity_NOC_WHITE, Standard_True)); + aViewer->SetLightOn(new V3d_AmbientLight(aViewer, Quantity_NOC_WHITE)); } Viewer::~Viewer()