1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-16 10:08:36 +03:00

0024188: Doubling the number of light sources in Qt samples.

This commit is contained in:
dbp 2013-09-18 14:20:42 +04:00 committed by bugmaster
parent 5d99f2c887
commit c7b6656812

View File

@ -104,14 +104,17 @@ void V3d_Viewer::DelLight( const Handle(V3d_Light)& TheLight ) {
MyDefinedLights.Remove(TheLight); MyDefinedLights.Remove(TheLight);
} }
void V3d_Viewer::SetDefaultLights () { void V3d_Viewer::SetDefaultLights()
// SetLightOn ( new V3d_DirectionalLight(this,V3d_XposYpos)); {
// SetLightOn ( new V3d_DirectionalLight(this,V3d_Zpos)); while (MyDefinedLights.Extent() > 0)
// SetLightOn ( new V3d_DirectionalLight(this,V3d_XnegYneg)); {
// SetLightOn ( new V3d_DirectionalLight(this,V3d_Zneg)); DelLight ((Handle(V3d_Light)&)MyDefinedLights.First());
SetLightOn( new V3d_DirectionalLight(this, V3d_Zneg, Quantity_NOC_WHITE, Standard_True) ); }
SetLightOn ( new V3d_AmbientLight(this));
SetLightOn (new V3d_DirectionalLight (this, V3d_Zneg, Quantity_NOC_WHITE, Standard_True));
SetLightOn (new V3d_AmbientLight (this));
} }
void V3d_Viewer::Init() { void V3d_Viewer::Init() {
MyDefaultPerspectiveView = new V3d_PerspectiveView(this); MyDefaultPerspectiveView = new V3d_PerspectiveView(this);
MyDefaultOrthographicView = new V3d_OrthographicView(this); MyDefaultOrthographicView = new V3d_OrthographicView(this);