X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FOCCViewer%2FOCCViewer_ViewPort3d.cxx;h=49c2250e7c91bce111e96b342ad2a9a7c1222272;hb=ebe38156f99322f96cfe86347908c7a55f340afe;hp=3f546a855b9a2eef241d2355c185b85273e522e9;hpb=6878ef4d7381638ec39d1ca9d03afc21a69401aa;p=modules%2Fgui.git diff --git a/src/OCCViewer/OCCViewer_ViewPort3d.cxx b/src/OCCViewer/OCCViewer_ViewPort3d.cxx old mode 100755 new mode 100644 index 3f546a855..49c2250e7 --- a/src/OCCViewer/OCCViewer_ViewPort3d.cxx +++ b/src/OCCViewer/OCCViewer_ViewPort3d.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2023 CEA, EDF, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -28,6 +28,8 @@ #include #include +#include +#include #include #include @@ -36,23 +38,18 @@ #include #include #include +#include +#include -#include -#include - -#if OCC_VERSION_LARGE > 0x06070100 +#include #include -#else -#include -#include -#endif #include "utilities.h" #if defined WIN32 #include #else -#include +//#include #endif static double rx = 0.; @@ -68,27 +65,21 @@ static Standard_Boolean zRotation = Standard_False; */ OCCViewer_ViewPort3d::OCCViewer_ViewPort3d( QWidget* parent, const Handle( V3d_Viewer)& viewer, V3d_TypeOfView type ) : OCCViewer_ViewPort( parent ), - myScale( 1.0 ), myBusy( true ), - myIsAdvancedZoomingEnabled( false ) + myScale( 1.0 ), + myIsAdvancedZoomingEnabled( false ), + myIsRotating( false ), + myRotAngle( 0.0 ) { // VSR: 01/07/2010 commented to avoid SIGSEGV at SALOME exit //selectVisualId(); -#if OCC_VERSION_LARGE > 0x06070100 myActiveView = new V3d_View( viewer, type ); -#else - if ( type == V3d_ORTHOGRAPHIC ) { - myOrthoView = new V3d_OrthographicView( viewer ); - myActiveView = myOrthoView; - myPerspView = 0; - } else { - myPerspView = new V3d_PerspectiveView( viewer ); - myActiveView = myPerspView; - } -#endif - setBackground( Qtx::BackgroundData( Qt::black ) ); // set default background + setDefaultParams(); + + myCursor = NULL; + myRotTimer = NULL; } /*! @@ -96,7 +87,20 @@ OCCViewer_ViewPort3d::OCCViewer_ViewPort3d( QWidget* parent, const Handle( V3d_V */ OCCViewer_ViewPort3d::~OCCViewer_ViewPort3d() { - emit vpClosed(); + if ( myRotTimer ) + { + myRotTimer->stop(); + delete myRotTimer; + myRotTimer = NULL; + } + + if ( myCursor ) + { + delete myCursor; + myCursor = NULL; + } + + emit vpClosed(this); Handle(V3d_View) aView = activeView(); if (!aView.IsNull()) aView->Remove(); @@ -134,17 +138,7 @@ bool OCCViewer_ViewPort3d::mapView( const Handle(V3d_View)& view ) view->View()->Deactivate(); } - /* create static trihedron (16551: EDF PAL 501) */ - OCCViewer_ViewWindow* aVW = dynamic_cast( parentWidget()->parentWidget()->parentWidget() ); - if ( aVW ) { - OCCViewer_Viewer* aViewModel = dynamic_cast( aVW->getViewManager()->getViewModel() ); - if ( aViewModel && aViewModel->isStaticTrihedronDisplayed() ){ - view->ZBufferTriedronSetup(); - view->TriedronDisplay( Aspect_TOTP_LEFT_LOWER, Quantity_NOC_WHITE, 0.05, V3d_ZBUFFER ); - } - } - - emit( vpMapped() ); + emit( vpMapped(this) ); return true; } @@ -234,40 +228,16 @@ bool OCCViewer_ViewPort3d::syncronize( const OCCViewer_ViewPort3d* ref ) refView->Up( x, y, z ); tgtView->SetUp( x, y, z ); refView->Eye( x, y, z ); tgtView->SetEye( x, y, z ); refView->Proj( x, y, z ); tgtView->SetProj( x, y, z ); -#if OCC_VERSION_LARGE <= 0x06070100 - refView->Center( x, y ); tgtView->SetCenter( x, y ); -#endif tgtView->SetScale( refView->Scale() ); tgtView->SetTwist( refView->Twist() ); /* update */ tgtView->Update(); tgtView->SetImmediateUpdate( Standard_True ); - tgtView->ZFitAll(); - return true; -} -/*! - Returns Z-size of this view. [ public ] -*/ -double OCCViewer_ViewPort3d::getZSize() const -{ - if ( !activeView().IsNull() ) - return activeView()->ZSize(); - return 0; + return true; } -/*! - Sets Z-size of this view ( for both orthographic and perspective ). [ public ] -*/ -void OCCViewer_ViewPort3d::setZSize( double zsize ) -{ - myActiveView->SetZSize( zsize ); - /* if ( !myOrthoView.IsNull() ) - myOrthoView->SetZSize( zsize ); - if ( !myPerspView.IsNull() ) - myPerspView->SetZSize( zsize );*/ -} /*! Get axial scale to the view @@ -323,22 +293,6 @@ void OCCViewer_ViewPort3d::updateBackground() if ( activeView().IsNull() ) return; if ( !myBackground.isValid() ) return; - // VSR: Important note on below code. - // In OCCT (in version 6.5.2), things about the background drawing - // are not straightforward and not clearly understandable: - // - Horizontal gradient is drawn vertically (!), well ok, from top side to bottom one. - // - Vertical gradient is drawn horizontally (!), from right side to left one (!!!). - // - First and second diagonal gradients are confused. - // - Image texture, once set, can not be removed (!). - // - Texture image fill mode Aspect_FM_NONE is not taken into account (and means the same - // as Aspect_FM_CENTERED). - // - The only way to cancel gradient background (and get back to single colored) is to - // set gradient background style to Aspect_GFM_NONE while passing two colors is also needed - // (see V3d_View::SetBgGradientColors() function). - // - Also, it is impossible to draw texture image above the gradiented background (only above - // single-colored). - // In OCCT 6.5.3 all above mentioned problems are fixed; so, above comment should be removed as soon - // as SALOME is migrated to OCCT 6.5.3. The same concerns #ifdef statements in the below code switch ( myBackground.mode() ) { case Qtx::ColorBackground: { @@ -347,13 +301,8 @@ void OCCViewer_ViewPort3d::updateBackground() // Unset texture should be done here // ... Quantity_Color qCol( c.red()/255., c.green()/255., c.blue()/255., Quantity_TOC_RGB ); -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 activeView()->SetBgGradientStyle( Aspect_GFM_NONE ); // cancel gradient background activeView()->SetBgImageStyle( Aspect_FM_NONE ); // cancel texture background -#else - // cancel gradient background (in OCC before v6.5.3 the only way to do this is to set it to NONE type passing arbitrary colors as parameters) - activeView()->SetBgGradientColors( qCol, qCol, Aspect_GFM_NONE ); -#endif // then change background color activeView()->SetBackgroundColor( qCol ); // update viewer @@ -375,38 +324,16 @@ void OCCViewer_ViewPort3d::updateBackground() activeView()->SetBgImageStyle( Aspect_FM_NONE ); // cancel texture background switch ( type ) { case OCCViewer_Viewer::HorizontalGradient: -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_HOR, Standard_True ); -#else - // in OCCT before v6.5.3, to draw horizontal gradient it's necessary to use Aspect_GFM_VER type - // and interchange the colors - activeView()->SetBgGradientColors( qCol2, qCol1, Aspect_GFM_VER, Standard_True ); -#endif break; case OCCViewer_Viewer::VerticalGradient: -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_VER, Standard_True ); -#else - // in OCCT before v6.5.3, to draw vertical gradient it's necessary to use Aspect_GFM_HOR type - activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_HOR, Standard_True ); -#endif break; case OCCViewer_Viewer::Diagonal1Gradient: -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_DIAG1, Standard_True ); -#else - // in OCCT before v6.5.3, to draw 1st dialognal gradient it's necessary to use Aspect_GFM_DIAG2 type - // and interchange the colors - activeView()->SetBgGradientColors( qCol2, qCol1, Aspect_GFM_DIAG2, Standard_True ); -#endif break; case OCCViewer_Viewer::Diagonal2Gradient: -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_DIAG2, Standard_True ); -#else - // in OCCT before v6.5.3, to draw 2nd dialognal gradient it's necessary to use Aspect_GFM_DIAG1 type - activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_DIAG1, Standard_True ); -#endif break; case OCCViewer_Viewer::Corner1Gradient: activeView()->SetBgGradientColors( qCol1, qCol2, Aspect_GFM_CORNER1, Standard_True ); @@ -434,9 +361,6 @@ void OCCViewer_ViewPort3d::updateBackground() default: break; } -#if OCC_VERSION_LARGE > 0x06050200 // available since OCCT 6.5.3 - // VSR: In OCCT before v6.5.3 below code can't be used because of very ugly bug - it has been impossible to - // clear the background texture image as soon as it was once set to the viewer. if ( myBackground.isTextureShown() ) { QString fileName; int textureMode = myBackground.texture( fileName ); @@ -445,13 +369,13 @@ void OCCViewer_ViewPort3d::updateBackground() // set texture image: file name and fill mode switch ( textureMode ) { case Qtx::CenterTexture: - activeView()->SetBackgroundImage( fi.absoluteFilePath().toLatin1().constData(), Aspect_FM_CENTERED ); + activeView()->SetBackgroundImage( fi.absoluteFilePath().toUtf8().constData(), Aspect_FM_CENTERED ); break; case Qtx::TileTexture: - activeView()->SetBackgroundImage( fi.absoluteFilePath().toLatin1().constData(), Aspect_FM_TILED ); + activeView()->SetBackgroundImage( fi.absoluteFilePath().toUtf8().constData(), Aspect_FM_TILED ); break; case Qtx::StretchTexture: - activeView()->SetBackgroundImage( fi.absoluteFilePath().toLatin1().constData(), Aspect_FM_STRETCH ); + activeView()->SetBackgroundImage( fi.absoluteFilePath().toUtf8().constData(), Aspect_FM_STRETCH ); break; default: break; @@ -459,7 +383,6 @@ void OCCViewer_ViewPort3d::updateBackground() activeView()->Update(); } } -#endif } /*! @@ -487,10 +410,11 @@ void OCCViewer_ViewPort3d::fitRect( const QRect& rect ) */ void OCCViewer_ViewPort3d::startZoomAtPoint( int x, int y ) { -#if OCC_VERSION_LARGE > 0x0603000A // available only with OCC-6.3-sp11 and higher version + // if (myIsRotating) + // stopRotation(); + if ( !activeView().IsNull() && isAdvancedZoomingEnabled() ) activeView()->StartZoomAtPoint( x, y ); -#endif } /*! @@ -498,15 +422,16 @@ void OCCViewer_ViewPort3d::startZoomAtPoint( int x, int y ) */ void OCCViewer_ViewPort3d::zoom( int x0, int y0, int x, int y ) { + // if (myIsRotating) + // stopRotation(); + if ( !activeView().IsNull() ) { // as OCCT respects a sign of only dx, // but we want both signes to be taken into account //activeView()->Zoom( x0, y0, x, y ); -#if OCC_VERSION_LARGE > 0x0603000A // available only with OCC-6.3-sp11 and higher version if ( isAdvancedZoomingEnabled() ) activeView()->ZoomAtPoint( x0, y0, x, y ); else -#endif activeView()->Zoom( x0 + y0, 0, x + y, 0 ); emit vpTransformed( this ); } @@ -517,6 +442,9 @@ void OCCViewer_ViewPort3d::zoom( int x0, int y0, int x, int y ) */ void OCCViewer_ViewPort3d::setCenter( int x, int y ) { + if (myIsRotating) + stopRotation(); + if ( !activeView().IsNull() ) { activeView()->Place( x, y, myScale ); emit vpTransformed( this ); @@ -528,6 +456,9 @@ void OCCViewer_ViewPort3d::setCenter( int x, int y ) */ void OCCViewer_ViewPort3d::pan( int dx, int dy ) { + if (myIsRotating) + stopRotation(); + if ( !activeView().IsNull() ) { activeView()->Pan( dx, dy, 1.0 ); emit vpTransformed( this ); @@ -541,28 +472,36 @@ void OCCViewer_ViewPort3d::startRotation( int x, int y, int theRotationPointType, const gp_Pnt& theSelectedPoint ) { + if (myIsRotating) + stopRotation(); + if ( !activeView().IsNull() ) { - //double gx, gy, gz; - //double gx = activeView()->gx; - //activeView()->Gravity(gx,gy,gz); + + Standard_Real zRotationThreshold, X, Y; + sx = x; sy = y; + activeView()->Size(X,Y); + rx = Standard_Real(activeView()->Convert(X)); + ry = Standard_Real(activeView()->Convert(Y)); + gp_Pnt centerPnt; switch ( theRotationPointType ) { - case OCCViewer_ViewWindow::GRAVITY: + case OCCViewer_ViewWindow::BBCENTER: + centerPnt = activeView()->GravityPoint(); + zRotation = Standard_False; + zRotationThreshold = 0.45; + if( zRotationThreshold > 0. ) { + Standard_Real dx = Abs(sx - rx/2.); + Standard_Real dy = Abs(sy - ry/2.); + Standard_Real dd = zRotationThreshold * (rx + ry)/2.; + if( dx > dd || dy > dd ) zRotation = Standard_True; + } activeView()->StartRotation( x, y, 0.45 ); break; case OCCViewer_ViewWindow::SELECTED: - sx = x; sy = y; - - double X,Y; - activeView()->Size(X,Y); - rx = Standard_Real(activeView()->Convert(X)); - ry = Standard_Real(activeView()->Convert(Y)); - activeView()->Rotate( 0., 0., 0., theSelectedPoint.X(),theSelectedPoint.Y(), theSelectedPoint.Z(), Standard_True ); - Quantity_Ratio zRotationThreshold; zRotation = Standard_False; zRotationThreshold = 0.45; if( zRotationThreshold > 0. ) { @@ -575,7 +514,8 @@ void OCCViewer_ViewPort3d::startRotation( int x, int y, default: break; } - activeView()->DepthFitAll(); + // VSR: 10.06.2015: next line commented out - causes ugly blinking on starting rotation with Perspective projection mode + //activeView()->DepthFitAll(); } } @@ -588,7 +528,7 @@ void OCCViewer_ViewPort3d::rotate( int x, int y, { if ( !activeView().IsNull() ) { switch ( theRotationPointType ) { - case OCCViewer_ViewWindow::GRAVITY: + case OCCViewer_ViewWindow::BBCENTER: activeView()->Rotation( x, y ); break; case OCCViewer_ViewWindow::SELECTED: @@ -622,15 +562,75 @@ void OCCViewer_ViewPort3d::rotate( int x, int y, void OCCViewer_ViewPort3d::endRotation() { if ( !activeView().IsNull() ) { - activeView()->ZFitAll( 1.0 ); -#if OCC_VERSION_LARGE <= 0x06070100 - activeView()->SetZSize( 0.0 ); -#endif activeView()->Update(); emit vpTransformed( this ); } } +/*! + Set the rotation axis and start automatic rotation +*/ +void OCCViewer_ViewPort3d::setRotationAxis(const gp_Vec& theAxis, double theAngle, double theZAngle) +{ + myRotAxis.SetLocation(activeView()->GravityPoint()); + if (zRotation) { + gp_Dir anAxisDir = activeView()->Camera()->Direction(); + myRotAxis.SetDirection(anAxisDir.Reversed()); + myRotAngle = theZAngle; + } + else { + myRotAxis.SetDirection(gp_Dir(theAxis)); + myRotAngle = theAngle; + } + if (!myRotTimer) { + myRotTimer = new QTimer(this); + myRotTimer->setSingleShot(true); + connect(myRotTimer, SIGNAL(timeout()), this, SLOT(updateRotation())); + } + else + myRotTimer->stop(); + + myIsRotating = true; + myLastRender = QDateTime::currentMSecsSinceEpoch(); + Handle(Graphic3d_Camera) aCamera = activeView()->Camera(); + gp_Trsf trsfRot; + trsfRot.SetRotation (myRotAxis, myRotAngle); + aCamera->Transform(trsfRot); + activeView()->SetCamera(aCamera); + myRotTimer->start(20); +} + +/*! + Stop the automatic rotation +*/ +void OCCViewer_ViewPort3d::stopRotation() +{ + myIsRotating = false; + if (myRotTimer) + myRotTimer->stop(); +} + +/*! + Update the automatic rotation animation +*/ +void OCCViewer_ViewPort3d::updateRotation() +{ + if (!myIsRotating) + return; + + qint64 curTime = QDateTime::currentMSecsSinceEpoch(); + double angle = myRotAngle * (curTime - myLastRender) / 100.; + Handle(Graphic3d_Camera) aCamera = activeView()->Camera(); + gp_Trsf trsfRot; + trsfRot.SetRotation(myRotAxis, angle); + aCamera->Transform(trsfRot); + activeView()->SetCamera(aCamera); + + myLastRender = curTime; + if (myRotTimer) + myRotTimer->start(20); +} + /*! Repaints the viewport. [ virtual protected ] */ @@ -642,10 +642,9 @@ void OCCViewer_ViewPort3d::paintEvent( QPaintEvent* e ) mapView( activeView() ); #endif if ( !myWindow.IsNull() ) { - QApplication::syncX(); - QRect rc = e->rect(); - if ( !myPaintersRedrawing ) - activeView()->Redraw( rc.x(), rc.y(), rc.width(), rc.height() ); + if ( !myPaintersRedrawing ) { + activeView()->Redraw(); + } } OCCViewer_ViewPort::paintEvent( e ); myBusy = false; @@ -656,37 +655,41 @@ void OCCViewer_ViewPort3d::paintEvent( QPaintEvent* e ) */ void OCCViewer_ViewPort3d::resizeEvent( QResizeEvent* e ) { -#ifdef WIN32 - /* Win32 : map before first show to avoid flicker */ + /* Map before first show to avoid flicker */ if ( !mapped( activeView() ) ) mapView( activeView() ); -#endif - QApplication::syncX(); - if ( !activeView().IsNull() ) + QTimer::singleShot( 0, this, SLOT( repaintViewAfterMove() ) ); + emit vpResizeEvent( e ); +} + +/*! + Moved the viewport +*/ +void OCCViewer_ViewPort3d::repaintViewAfterMove( ) +{ + if ( !activeView().IsNull() ){ activeView()->MustBeResized(); + } } /*! Fits all objects in view. [ virtual protected ] */ -void OCCViewer_ViewPort3d::fitAll( bool keepScale, bool withZ, bool upd ) +void OCCViewer_ViewPort3d::fitAll( bool keepScale, bool /*withZ*/, bool upd ) { if ( activeView().IsNull() ) return; + if (myIsRotating) + stopRotation(); + if ( keepScale ) myScale = activeView()->Scale(); Standard_Real margin = 0.01; -#if OCC_VERSION_LARGE > 0x06070100 activeView()->FitAll( margin, upd ); - if(withZ) - activeView()->ZFitAll(); -#else - activeView()->FitAll( margin, withZ, upd ); -#endif - activeView()->SetZSize(0.); + emit vpTransformed( this ); } @@ -695,6 +698,9 @@ void OCCViewer_ViewPort3d::fitAll( bool keepScale, bool withZ, bool upd ) */ void OCCViewer_ViewPort3d::reset() { + if (myIsRotating) + stopRotation(); + // double zsize = getZSize(); if ( !activeView().IsNull() ) { activeView()->Reset(); @@ -711,6 +717,9 @@ void OCCViewer_ViewPort3d::rotateXY( double degrees ) if ( activeView().IsNull() ) return; + if (myIsRotating) + stopRotation(); + int x = width()/2, y = height()/2; double X, Y, Z; activeView()->Convert( x, y, X, Y, Z ); @@ -794,13 +803,7 @@ bool OCCViewer_ViewPort3d::synchronize( OCCViewer_ViewPort* view ) Handle(V3d_View) aView3d = getView(); Handle(V3d_View) aRefView3d = vp3d->getView(); aView3d->SetImmediateUpdate( Standard_False ); -#if OCC_VERSION_LARGE > 0x06070100 aView3d->Camera()->Copy( aRefView3d->Camera() ); -#else - aView3d->SetViewMapping( aRefView3d->ViewMapping() ); - aView3d->SetViewOrientation( aRefView3d->ViewOrientation() ); -#endif - aView3d->ZFitAll(); aView3d->SetImmediateUpdate( Standard_True ); aView3d->Update(); blockSignals( blocked ); @@ -812,18 +815,58 @@ bool OCCViewer_ViewPort3d::synchronize( OCCViewer_ViewPort* view ) /* * Show/Hide static triedron */ -void OCCViewer_ViewPort3d::updateStaticTriedronVisibility() { - OCCViewer_ViewWindow* aVW = dynamic_cast( parentWidget()->parentWidget()->parentWidget() ); - if ( aVW ) { - OCCViewer_Viewer* aViewModel = dynamic_cast( aVW->getViewManager()->getViewModel() ); - Handle(V3d_View) aView = activeView(); - if ( aViewModel ){ - if(aViewModel->isStaticTrihedronDisplayed()) { - aView->TriedronDisplay( Aspect_TOTP_LEFT_LOWER, Quantity_NOC_WHITE, 0.05, V3d_ZBUFFER ); - } else { - aView->TriedronErase(); - } - aView->Update(); - } +void OCCViewer_ViewPort3d::showStaticTrihedron( bool on ) +{ + Handle(V3d_View) aView = activeView(); + if ( !aView ) return; + + if ( on ) { + aView->ZBufferTriedronSetup(); + aView->TriedronDisplay( Aspect_TOTP_LEFT_LOWER, Quantity_NOC_WHITE, 0.05, V3d_ZBUFFER ); + } else { + aView->TriedronErase(); } + aView->Update(); +} + +/* + * Create default cursor with a specific shape + */ +void OCCViewer_ViewPort3d::setDefaultCursor( Qt::CursorShape theCursorShape ) +{ + if ( !myCursor ) + myCursor = new QCursor(); + + myCursor->setShape( theCursorShape ); +} + +/* + * Get default cursor with a specific shape + */ +QCursor* OCCViewer_ViewPort3d::getDefaultCursor() const +{ + return myCursor; +} + +/* + * Set default parameters from preferences + */ +void OCCViewer_ViewPort3d::setDefaultParams() +{ + setBackground( Qtx::BackgroundData( Qt::black ) ); // set default background + + // get ray tracing parameters from preferences + int aDepth = SUIT_Session::session()->resourceMgr()->integerValue( "OCCViewer", "rt_depth", 3 ); + bool aReflection = SUIT_Session::session()->resourceMgr()->booleanValue( "OCCViewer", "rt_reflection", true ); + bool anAntialiasing = SUIT_Session::session()->resourceMgr()->booleanValue( "OCCViewer", "rt_antialiasing", false ); + bool aShadow = SUIT_Session::session()->resourceMgr()->booleanValue( "OCCViewer", "rt_shadow", true ); + bool aTransparentShadow = SUIT_Session::session()->resourceMgr()->booleanValue( "OCCViewer", "rt_trans_shadow", true ); + + Graphic3d_RenderingParams& aParams = myActiveView->ChangeRenderingParams(); + aParams.RaytracingDepth = aDepth; + aParams.IsReflectionEnabled = aReflection; + aParams.IsAntialiasingEnabled = anAntialiasing; + aParams.IsShadowEnabled = aShadow; + aParams.IsTransparentShadowEnabled = aTransparentShadow; + myActiveView->Redraw(); }