// This file is generated by WOK (CPPExt). // Please do not edit this file; modify original file instead. // The copyright and license terms as defined for the original file apply to // this header file considered to be the "object code" form of the original source. #ifndef _V3d_View_HeaderFile #define _V3d_View_HeaderFile #ifndef _Standard_HeaderFile #include #endif #ifndef _Standard_DefineHandle_HeaderFile #include #endif #ifndef _Handle_V3d_View_HeaderFile #include #endif #ifndef _V3d_TypeOfView_HeaderFile #include #endif #ifndef _V3d_ViewerPointer_HeaderFile #include #endif #ifndef _V3d_ListOfTransient_HeaderFile #include #endif #ifndef _Handle_Visual3d_View_HeaderFile #include #endif #ifndef _Visual3d_ViewMapping_HeaderFile #include #endif #ifndef _Visual3d_ViewOrientation_HeaderFile #include #endif #ifndef _Visual3d_ContextView_HeaderFile #include #endif #ifndef _Aspect_Background_HeaderFile #include #endif #ifndef _Aspect_GradientBackground_HeaderFile #include #endif #ifndef _Graphic3d_Vector_HeaderFile #include #endif #ifndef _Graphic3d_Vertex_HeaderFile #include #endif #ifndef _Handle_Aspect_Window_HeaderFile #include #endif #ifndef _Handle_Graphic3d_Plotter_HeaderFile #include #endif #ifndef _TColStd_ListIteratorOfListOfTransient_HeaderFile #include #endif #ifndef _Standard_Integer_HeaderFile #include #endif #ifndef _Standard_Real_HeaderFile #include #endif #ifndef _Standard_Boolean_HeaderFile #include #endif #ifndef _Handle_Aspect_Grid_HeaderFile #include #endif #ifndef _gp_Ax3_HeaderFile #include #endif #ifndef _Handle_V3d_LayerMgr_HeaderFile #include #endif #ifndef _TColStd_Array2OfReal_HeaderFile #include #endif #ifndef _Handle_Graphic3d_Structure_HeaderFile #include #endif #ifndef _Handle_Graphic3d_Group_HeaderFile #include #endif #ifndef _V3d_TypeOfProjectionModel_HeaderFile #include #endif #ifndef _Viewer_View_HeaderFile #include #endif #ifndef _V3d_Viewer_HeaderFile #include #endif #ifndef _Handle_V3d_View_HeaderFile #include #endif #ifndef _Handle_V3d_Viewer_HeaderFile #include #endif #ifndef _Aspect_RenderingContext_HeaderFile #include #endif #ifndef _Aspect_GraphicCallbackProc_HeaderFile #include #endif #ifndef _Standard_Address_HeaderFile #include #endif #ifndef _Quantity_TypeOfColor_HeaderFile #include #endif #ifndef _Quantity_Parameter_HeaderFile #include #endif #ifndef _Quantity_NameOfColor_HeaderFile #include #endif #ifndef _Aspect_GradientFillMethod_HeaderFile #include #endif #ifndef _Standard_CString_HeaderFile #include #endif #ifndef _Aspect_FillMethod_HeaderFile #include #endif #ifndef _V3d_Coordinate_HeaderFile #include #endif #ifndef _V3d_TypeOfShadingModel_HeaderFile #include #endif #ifndef _V3d_TypeOfSurfaceDetail_HeaderFile #include #endif #ifndef _Handle_Graphic3d_TextureEnv_HeaderFile #include #endif #ifndef _V3d_TypeOfVisualization_HeaderFile #include #endif #ifndef _Quantity_Length_HeaderFile #include #endif #ifndef _V3d_TypeOfZclipping_HeaderFile #include #endif #ifndef _Handle_V3d_Light_HeaderFile #include #endif #ifndef _Handle_V3d_Plane_HeaderFile #include #endif #ifndef _Aspect_TypeOfTriedronPosition_HeaderFile #include #endif #ifndef _Aspect_TypeOfTriedronEcho_HeaderFile #include #endif #ifndef _OSD_FontAspect_HeaderFile #include #endif #ifndef _TCollection_ExtendedString_HeaderFile #include #endif #ifndef _Quantity_Color_HeaderFile #include #endif #ifndef _TCollection_AsciiString_HeaderFile #include #endif #ifndef _Handle_Aspect_ColorScale_HeaderFile #include #endif #ifndef _Quantity_PlaneAngle_HeaderFile #include #endif #ifndef _V3d_TypeOfAxe_HeaderFile #include #endif #ifndef _Quantity_Factor_HeaderFile #include #endif #ifndef _V3d_TypeOfOrientation_HeaderFile #include #endif #ifndef _Quantity_Coefficient_HeaderFile #include #endif #ifndef _Quantity_Ratio_HeaderFile #include #endif #ifndef _Handle_PlotMgt_PlotterDriver_HeaderFile #include #endif #ifndef _Image_TypeOfImage_HeaderFile #include #endif #ifndef _Aspect_FormatOfSheetPaper_HeaderFile #include #endif #ifndef _Aspect_Handle_HeaderFile #include #endif #ifndef _Aspect_PrintAlgo_HeaderFile #include #endif #ifndef _Handle_Image_PixMap_HeaderFile #include #endif #ifndef _V3d_TypeOfBackfacingModel_HeaderFile #include #endif class Visual3d_View; class Aspect_Window; class Graphic3d_Plotter; class Aspect_Grid; class V3d_LayerMgr; class Graphic3d_Structure; class Graphic3d_Group; class Viewer_BadValue; class Standard_TypeMismatch; class Standard_MultiplyDefined; class V3d_UnMapped; class V3d_Viewer; class Quantity_Color; class Graphic3d_TextureEnv; class V3d_Light; class V3d_Plane; class TCollection_ExtendedString; class TCollection_AsciiString; class Aspect_ColorScale; class Visual3d_ViewOrientation; class Visual3d_ViewMapping; class Aspect_GradientBackground; class Graphic3d_Vector; class TColStd_Array2OfReal; class Graphic3d_Vertex; class gp_Ax3; class PlotMgt_PlotterDriver; class Image_PixMap; //! Defines the application object VIEW for the
//! VIEWER application.
//! The methods of this class allow the editing
//! and inquiring the parameters linked to the view.
//! (Projection,Mapping,Zclipping,DepthCueing,AntiAliasing
//! et Conversions) .
//! Warning: The default parameters are defined by the class
//! Viewer (Example : SetDefaultViewSize()).
//! Certain methods are mouse oriented, and it is
//! necessary to know the difference between the start and
//! the continuation of this gesture in putting the method
//! into operation.
//! Example : Shifting the eye-view along the screen axes.
class V3d_View : public Viewer_View { public: //! Activates the view in the window specified and Map the
//! Window to the screen.
//! Warning! raises MultiplyDefined from Standard
//! if the view is already activated in a window.
//! Warning: The view is centered and resized to preserve
//! the height/width ratio of the window.
Standard_EXPORT void SetWindow(const Handle(Aspect_Window)& IdWin) ; //! Activates the view in the specified Window
//! If is not NULL the graphic context is used
//! to draw something in this view.
//! Otherwise an internal graphic context is created.
//! If is not NULL then a user display CB is
//! call at the end of the OCC graphic traversal and just
//! before the swap of buffers. The is pass
//! to this call back.
//! Warning! raises MultiplyDefined from Standard
//! if the view is already activated in a window.
//! Warning: The view is centered and resized to preserve
//! the height/width ratio of the window.
Standard_EXPORT void SetWindow(const Handle(Aspect_Window)& aWindow,const Aspect_RenderingContext aContext,const Aspect_GraphicCallbackProc& aDisplayCB,const Standard_Address aClientData) ; Standard_EXPORT void SetMagnify(const Handle(Aspect_Window)& IdWin,const Handle(V3d_View)& aPreviousView,const Standard_Integer x1,const Standard_Integer y1,const Standard_Integer x2,const Standard_Integer y2) ; //! Destroys the view.
Standard_EXPORT void Remove() const; //! Updates the display of the view.
//! Must be called to update the view
//! when the update mode is deferred (WAIT) .
Standard_EXPORT void Update() const; //! Redisplays the view even if there has not
//! been any modification.
//! Must be called if the view is shown.
//! (Ex: DeIconification ) .
Standard_EXPORT void Redraw() const; //! Redisplays the view area after esxposure.
//! [x,y] define the min xy area position
//! [width,height] the size of the area in pixel unit.
Standard_EXPORT void Redraw(const Standard_Integer x,const Standard_Integer y,const Standard_Integer width,const Standard_Integer height) const; //! Must be called when the window supporting the
//! view changes size.
//! if the view is not mapped on a window.
//! Warning: The view is centered and resized to preserve
//! the height/width ratio of the window.
Standard_EXPORT void MustBeResized() ; //! Must be called when the window supporting the
//! view is mapped or unmapped.
Standard_EXPORT void DoMapping() ; //! Returns the status of the view regarding
//! the displayed structures inside
//! Returns True is The View is empty
Standard_EXPORT Standard_Boolean IsEmpty() const; //! Updates the lights of the view. The view is redrawn.
Standard_EXPORT void UpdateLights() const; //! Defines the background colour of the view
//! by supplying :
//! the colour definition type,
//! and the three corresponding values.
Standard_EXPORT void SetBackgroundColor(const Quantity_TypeOfColor Type,const Quantity_Parameter V1,const Quantity_Parameter V2,const Quantity_Parameter V3) ; //! Defines the background colour of the view
//! by supplying :
//! the colour object.
Standard_EXPORT void SetBackgroundColor(const Quantity_Color& Color) ; //! Defines the background colour of the view
//! by supplying :
//! the colour name in the form Quantity_NOC_xxxx .
Standard_EXPORT void SetBackgroundColor(const Quantity_NameOfColor Name) ; //! Defines the gradient background colours of the view
//! by supplying :
//! the colour objects.
Standard_EXPORT void SetBgGradientColors(const Quantity_Color& Color1,const Quantity_Color& Color2,const Aspect_GradientFillMethod FillStyle = Aspect_GFM_HOR,const Standard_Boolean update = Standard_False) ; //! Defines the gradient background colours of the view
//! by supplying :
//! the colour names in the form Quantity_NOC_xxxx .
Standard_EXPORT void SetBgGradientColors(const Quantity_NameOfColor Color1,const Quantity_NameOfColor Color2,const Aspect_GradientFillMethod FillStyle = Aspect_GFM_HOR,const Standard_Boolean update = Standard_False) ; //! Defines the gradient background fill method of the view
Standard_EXPORT void SetBgGradientStyle(const Aspect_GradientFillMethod AMethod = Aspect_GFM_HOR,const Standard_Boolean update = Standard_False) const; Standard_EXPORT void SetBackgroundImage(const Standard_CString FileName,const Aspect_FillMethod FillStyle = Aspect_FM_CENTERED,const Standard_Boolean update = Standard_False) ; Standard_EXPORT void SetBgImageStyle(const Aspect_FillMethod FillStyle,const Standard_Boolean update = Standard_False) ; //! Definition of an axis from its origin and
//! its orientation .
//! This will be the current axis for rotations and movements.
//! Warning! raises BadValue from Viewer if the vector normal is NULL. .
Standard_EXPORT void SetAxis(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,const Quantity_Parameter Vx,const Quantity_Parameter Vy,const Quantity_Parameter Vz) ; //! Defines the shading model for the
//! visualisation ZBUFFER mode.
//! Various models are available.
Standard_EXPORT void SetShadingModel(const V3d_TypeOfShadingModel Model) ; //! select the kind of rendering for texture mapping
//! no texture mapping by default
Standard_EXPORT void SetSurfaceDetail(const V3d_TypeOfSurfaceDetail SurfaceDetail) ; //! set the environment texture to use
//! no environment texture by default
Standard_EXPORT void SetTextureEnv(const Handle(Graphic3d_TextureEnv)& ATexture) ; //! Defines the visualisation mode in the view.
Standard_EXPORT void SetVisualization(const V3d_TypeOfVisualization Mode) ; //! Activates antialiasing in the view.
Standard_EXPORT void SetAntialiasingOn() ; //! Desactivates antialiasing in the view.
Standard_EXPORT void SetAntialiasingOff() ; //! Defines the depth of the medium clipping plane.
Standard_EXPORT void SetZClippingDepth(const Quantity_Length Depth) ; //! Defines the thicknes around the medium clippling plane. .
Standard_EXPORT void SetZClippingWidth(const Quantity_Length Width) ; //! Defines the type of ZClipping.
Standard_EXPORT void SetZClippingType(const V3d_TypeOfZclipping Type) ; //! Defines the depth of the medium plane.
Standard_EXPORT void SetZCueingDepth(const Quantity_Length Depth) ; //! Defines the thickness around the medium plane.
Standard_EXPORT void SetZCueingWidth(const Quantity_Length Width) ; //! Activates ZCueing in the view.
Standard_EXPORT void SetZCueingOn() ; //! Desactivates ZCueing in the view.
Standard_EXPORT void SetZCueingOff() ; //! Activates MyLight in the view.
Standard_EXPORT void SetLightOn(const Handle(V3d_Light)& MyLight) ; //! Activates all the lights defined in this view.
Standard_EXPORT void SetLightOn() ; //! Desactivate MyLight in this view.
Standard_EXPORT void SetLightOff(const Handle(V3d_Light)& MyLight) ; //! Deactivate all the Lights defined in this view.
Standard_EXPORT void SetLightOff() ; //! Returns TRUE when the light is active in this view.
Standard_EXPORT Standard_Boolean IsActiveLight(const Handle(V3d_Light)& aLight) const; //! Activate/Deactivate the transparency in this view.
Standard_EXPORT void SetTransparency(const Standard_Boolean AnActivity = Standard_False) ; //! Activates the clipping plane in this view.
//! If No More Plane can be activated in MyView .
Standard_EXPORT void SetPlaneOn(const Handle(V3d_Plane)& MyPlane) ; //! Activate all the clipping planes defined in
//! this view.
//! If No More Plane can be activated in MyView .
Standard_EXPORT void SetPlaneOn() ; //! Desactivates the clipping plane defined
//! in this view.
Standard_EXPORT void SetPlaneOff(const Handle(V3d_Plane)& MyPlane) ; //! Deactivate all clipping planes defined
//! in this view.
Standard_EXPORT void SetPlaneOff() ; //! Returns TRUE when the plane is active in this view.
Standard_EXPORT Standard_Boolean IsActivePlane(const Handle(V3d_Plane)& aPlane) const; //! Customization of the ZBUFFER Triedron.
//! XColor,YColor,ZColor - colors of axis
//! SizeRatio - ratio of decreasing of the trihedron size when its phisical
//! position comes out of the view
//! AxisDiametr - diameter relatively to axis length
//! NbFacettes - number of facettes of cylinders and cones
Standard_EXPORT void ZBufferTriedronSetup(const Quantity_NameOfColor XColor = Quantity_NOC_RED,const Quantity_NameOfColor YColor = Quantity_NOC_GREEN,const Quantity_NameOfColor ZColor = Quantity_NOC_BLUE1,const Standard_Real SizeRatio = 0.8,const Standard_Real AxisDiametr = 0.05,const Standard_Integer NbFacettes = 12) ; //! Display of the Triedron.
//! Initialize position, color and length of Triedron axes.
//! The scale is a percent of the window width.
Standard_EXPORT void TriedronDisplay(const Aspect_TypeOfTriedronPosition APosition = Aspect_TOTP_CENTER,const Quantity_NameOfColor AColor = Quantity_NOC_WHITE,const Standard_Real AScale = 0.02,const V3d_TypeOfVisualization AMode = V3d_WIREFRAME) ; //! Erases the Triedron.
Standard_EXPORT void TriedronErase() ; //! Highlights the echo zone of the Triedron.
Standard_EXPORT void TriedronEcho(const Aspect_TypeOfTriedronEcho AType = Aspect_TOTE_NONE) ; //! Returns data of a graduated trihedron.
Standard_EXPORT void GetGraduatedTrihedron(TCollection_ExtendedString& xname,TCollection_ExtendedString& yname,TCollection_ExtendedString& zname,Standard_Boolean& xdrawname,Standard_Boolean& ydrawname,Standard_Boolean& zdrawname,Standard_Boolean& xdrawvalues,Standard_Boolean& ydrawvalues,Standard_Boolean& zdrawvalues,Standard_Boolean& drawgrid,Standard_Boolean& drawaxes,Standard_Integer& nbx,Standard_Integer& nby,Standard_Integer& nbz,Standard_Integer& xoffset,Standard_Integer& yoffset,Standard_Integer& zoffset,Standard_Integer& xaxisoffset,Standard_Integer& yaxisoffset,Standard_Integer& zaxisoffset,Standard_Boolean& xdrawtickmarks,Standard_Boolean& ydrawtickmarks,Standard_Boolean& zdrawtickmarks,Standard_Integer& xtickmarklength,Standard_Integer& ytickmarklength,Standard_Integer& ztickmarklength,Quantity_Color& gridcolor,Quantity_Color& xnamecolor,Quantity_Color& ynamecolor,Quantity_Color& znamecolor,Quantity_Color& xcolor,Quantity_Color& ycolor,Quantity_Color& zcolor,TCollection_AsciiString& fontOfNames,OSD_FontAspect& styleOfNames,Standard_Integer& sizeOfNames,TCollection_AsciiString& fontOfValues,OSD_FontAspect& styleOfValues,Standard_Integer& sizeOfValues) const; //! Displays a graduated trihedron.
Standard_EXPORT void GraduatedTrihedronDisplay(const TCollection_ExtendedString& xname = "X",const TCollection_ExtendedString& yname = "Y",const TCollection_ExtendedString& zname = "Z",const Standard_Boolean xdrawname = Standard_True,const Standard_Boolean ydrawname = Standard_True,const Standard_Boolean zdrawname = Standard_True,const Standard_Boolean xdrawvalues = Standard_True,const Standard_Boolean ydrawvalues = Standard_True,const Standard_Boolean zdrawvalues = Standard_True,const Standard_Boolean drawgrid = Standard_True,const Standard_Boolean drawaxes = Standard_True,const Standard_Integer nbx = 3,const Standard_Integer nby = 3,const Standard_Integer nbz = 3,const Standard_Integer xoffset = 10,const Standard_Integer yoffset = 10,const Standard_Integer zoffset = 10,const Standard_Integer xaxisoffset = 30,const Standard_Integer yaxisoffset = 30,const Standard_Integer zaxisoffset = 30,const Standard_Boolean xdrawtickmarks = Standard_True,const Standard_Boolean ydrawtickmarks = Standard_True,const Standard_Boolean zdrawtickmarks = Standard_True,const Standard_Integer xtickmarklength = 10,const Standard_Integer ytickmarklength = 10,const Standard_Integer ztickmarklength = 10,const Quantity_Color& gridcolor = Quantity_NOC_WHITE,const Quantity_Color& xnamecolor = Quantity_NOC_RED,const Quantity_Color& ynamecolor = Quantity_NOC_GREEN,const Quantity_Color& znamecolor = Quantity_NOC_BLUE1,const Quantity_Color& xcolor = Quantity_NOC_RED,const Quantity_Color& ycolor = Quantity_NOC_GREEN,const Quantity_Color& zcolor = Quantity_NOC_BLUE1,const TCollection_AsciiString& fontOfNames = "Arial",const OSD_FontAspect styleOfNames = OSD_FA_Bold,const Standard_Integer sizeOfNames = 12,const TCollection_AsciiString& fontOfValues = "Arial",const OSD_FontAspect styleOfValues = OSD_FA_Regular,const Standard_Integer sizeOfValues = 12) ; //! Erases a graduated trihedron from the view.
Standard_EXPORT void GraduatedTrihedronErase() ; Standard_EXPORT void SetLayerMgr(const Handle(V3d_LayerMgr)& aMgr) ; Standard_EXPORT void ColorScaleDisplay() ; Standard_EXPORT void ColorScaleErase() ; Standard_EXPORT Standard_Boolean ColorScaleIsDisplayed() const; Standard_EXPORT Handle_Aspect_ColorScale ColorScale() const; //! modify the Projection of the view perpendicularly to
//! the privileged plane of the viewer.
Standard_EXPORT void SetFront() ; //! Rotates the eye about the coordinate system of
//! reference of the screen
//! for which the origin is the view point of the projection,
//! with a relative angular value in RADIANS with respect to
//! the initial position expressed by Start = Standard_True
//! Warning! raises BadValue from Viewer
//! If the eye, the view point, or the high point are
//! aligned or confused.
Standard_EXPORT void Rotate(const Quantity_PlaneAngle Ax,const Quantity_PlaneAngle Ay,const Quantity_PlaneAngle Az,const Standard_Boolean Start = Standard_True) ; //! Rotates the eye about the coordinate system of
//! reference of the screen
//! for which the origin is Gravity point {X,Y,Z},
//! with a relative angular value in RADIANS with respect to
//! the initial position expressed by Start = Standard_True
//! If the eye, the view point, or the high point are
//! aligned or confused.
Standard_EXPORT void Rotate(const Quantity_PlaneAngle Ax,const Quantity_PlaneAngle Ay,const Quantity_PlaneAngle Az,const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,const Standard_Boolean Start = Standard_True) ; //! Rotates the eye about one of the coordinate axes of
//! of the view for which the origin is the Gravity point{X,Y,Z}
//! with an relative angular value in RADIANS with
//! respect to the initial position expressed by
//! Start = Standard_True
Standard_EXPORT void Rotate(const V3d_TypeOfAxe Axe,const Quantity_PlaneAngle Angle,const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,const Standard_Boolean Start = Standard_True) ; //! Rotates the eye about one of the coordinate axes of
//! of the view for which the origin is the view point of the
//! projection with an relative angular value in RADIANS with
//! respect to the initial position expressed by
//! Start = Standard_True
Standard_EXPORT void Rotate(const V3d_TypeOfAxe Axe,const Quantity_PlaneAngle Angle,const Standard_Boolean Start = Standard_True) ; //! Rotates the eye around the current axis a relative
//! angular value in RADIANS with respect to the initial
//! position expressed by Start = Standard_True
Standard_EXPORT void Rotate(const Quantity_PlaneAngle Angle,const Standard_Boolean Start = Standard_True) ; //! Movement of the eye parallel to the coordinate system
//! of reference of the screen a distance relative to the
//! initial position expressed by Start = Standard_True.
Standard_EXPORT void Move(const Quantity_Length Dx,const Quantity_Length Dy,const Quantity_Length Dz,const Standard_Boolean Start = Standard_True) ; //! Movement of the eye parallel to one of the axes of the
//! coordinate system of reference of the view a distance
//! relative to the initial position expressed by
//! Start = Standard_True.
Standard_EXPORT void Move(const V3d_TypeOfAxe Axe,const Quantity_Length Length,const Standard_Boolean Start = Standard_True) ; //! Movement of the eye parllel to the current axis
//! a distance relative to the initial position
//! expressed by Start = Standard_True
Standard_EXPORT void Move(const Quantity_Length Length,const Standard_Boolean Start = Standard_True) ; //! Movement of the ye and the view point parallel to the
//! frame of reference of the screen a distance relative
//! to the initial position expressed by
//! Start = Standard_True
Standard_EXPORT void Translate(const Quantity_Length Dx,const Quantity_Length Dy,const Quantity_Length Dz,const Standard_Boolean Start = Standard_True) ; //! Movement of the eye and the view point parallel to one
//! of the axes of the fame of reference of the view a
//! distance relative to the initial position
//! expressed by Start = Standard_True
Standard_EXPORT void Translate(const V3d_TypeOfAxe Axe,const Quantity_Length Length,const Standard_Boolean Start = Standard_True) ; //! Movement of the eye and view point parallel to
//! the current axis a distance relative to the initial
//! position expressed by Start = Standard_True
Standard_EXPORT void Translate(const Quantity_Length Length,const Standard_Boolean Start = Standard_True) ; //! places the point of the view corresponding
//! at the pixel position x,y at the center of the window
//! and updates the view.
Standard_EXPORT void Place(const Standard_Integer x,const Standard_Integer y,const Quantity_Factor aZoomFactor = 1) ; //! Rotation of the view point around the frame of reference
//! of the screen for which the origin is the eye of the
//! projection with a relative angular value in RADIANS
//! with respect to the initial position expressed by
//! Start = Standard_True
Standard_EXPORT void Turn(const Quantity_PlaneAngle Ax,const Quantity_PlaneAngle Ay,const Quantity_PlaneAngle Az,const Standard_Boolean Start = Standard_True) ; //! Rotation of the view point around one of the axes of the
//! frame of reference of the view for which the origin is
//! the eye of the projection with an angular value in
//! RADIANS relative to the initial position expressed by
//! Start = Standard_True
Standard_EXPORT void Turn(const V3d_TypeOfAxe Axe,const Quantity_PlaneAngle Angle,const Standard_Boolean Start = Standard_True) ; //! Rotation of the view point around the current axis an
//! angular value in RADIANS relative to the initial
//! position expressed by Start = Standard_True
Standard_EXPORT void Turn(const Quantity_PlaneAngle Angle,const Standard_Boolean Start = Standard_True) ; //! Defines the angular position of the high point of
//! the reference frame of the view with respect to the
//! Y screen axis with an absolute angular value in
//! RADIANS.
Standard_EXPORT void SetTwist(const Quantity_PlaneAngle Angle) ; //! Defines the position of the eye..
Standard_EXPORT void SetEye(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z) ; //! Defines the Depth of the eye from the view point
//! without update the projection .
Standard_EXPORT void SetDepth(const Quantity_Length Depth) ; //! Defines the orientation of the projection.
Standard_EXPORT void SetProj(const Quantity_Parameter Vx,const Quantity_Parameter Vy,const Quantity_Parameter Vz) ; //! Defines the orientation of the projection .
Standard_EXPORT void SetProj(const V3d_TypeOfOrientation Orientation) ; //! Defines the position of the view point.
Standard_EXPORT void SetAt(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z) ; //! Defines the orientation of the high point.
Standard_EXPORT void SetUp(const Quantity_Parameter Vx,const Quantity_Parameter Vy,const Quantity_Parameter Vz) ; //! Defines the orientation(SO) of the high point.
Standard_EXPORT void SetUp(const V3d_TypeOfOrientation Orientation) ; //! Modifies the orientation of the view.
Standard_EXPORT void SetViewOrientation(const Visual3d_ViewOrientation& VO) ; //! Saves the current state of the orientation of the view
//! which will be the return state at ResetViewOrientation.
Standard_EXPORT void SetViewOrientationDefault() ; //! Resets the orientation of the view.
//! Updates the view
Standard_EXPORT void ResetViewOrientation() ; //! translates the center of the view and zooms the view.
//! Updates the view.
Standard_EXPORT void Panning(const Quantity_Length Dx,const Quantity_Length Dy,const Quantity_Factor aZoomFactor = 1,const Standard_Boolean Start = Standard_True) ; //! Defines the centre of the view.
//! Updates the view.
Standard_EXPORT void SetCenter(const V3d_Coordinate Xc,const V3d_Coordinate Yc) ; //! Defines the centre of the view from a pixel position.
//! Updates the view.
Standard_EXPORT void SetCenter(const Standard_Integer X,const Standard_Integer Y) ; //! Defines the size of the view while preserving the
//! center and height/width ratio of the window supporting
//! the view.
//! NOTE than the Depth of the View is NOT modified .
Standard_EXPORT void SetSize(const Quantity_Length Size) ; //! Defines the Depth size of the view
//! Front Plane will be set to Size/2.
//! Back Plane will be set to -Size/2.
//! Any Object located Above the Front Plane or
//! behind the Back Plane will be Clipped .
//! NOTE than the XY Size of the View is NOT modified .
Standard_EXPORT void SetZSize(const Quantity_Length Size) ; //! Zooms the view by a factor relative to the initial
//! value expressed by Start = Standard_True
//! Updates the view.
Standard_EXPORT void SetZoom(const Quantity_Factor Coef,const Standard_Boolean Start = Standard_True) ; //! Zooms the view by a factor relative to the value
//! initialised by SetViewMappingDefault().
//! Updates the view.
Standard_EXPORT void SetScale(const Quantity_Factor Coef) ; //! Sets anisotropic (axial) scale factors , , for view .
//! Anisotropic scaling operation is performed through multiplying
//! the current view orientation matrix by a scaling matrix:
//! || Sx 0 0 0 ||
//! || 0 Sy 0 0 ||
//! || 0 0 Sz 0 ||
//! || 0 0 0 1 ||
//! Updates the view.
Standard_EXPORT void SetAxialScale(const Standard_Real Sx,const Standard_Real Sy,const Standard_Real Sz) ; //! Automatic zoom/panning. Objects in the view are visualised
//! so as to occupy the maximum space while respecting the
//! margin coefficient and the initial height /width ratio.
//! NOTE than the original Z size of the view is NOT modified .
Standard_EXPORT void FitAll(const Quantity_Coefficient Coef = 0.01,const Standard_Boolean FitZ = Standard_False,const Standard_Boolean update = Standard_True) ; //! Automatic Depth Panning. Objects visible in the view are
//! visualised so as to occupy the maximum Z amount of space
//! while respecting the margin coefficient .
//! NOTE than the original XY size of the view is NOT modified .
Standard_EXPORT void ZFitAll(const Quantity_Coefficient Coef = 1.0) ; //! Adjusts the viewing volume so as not to clip the displayed objects by front and back
//! and back clipping planes. Also sets depth value automatically depending on the
//! calculated Z size and Aspect parameter.
//! NOTE than the original XY size of the view is NOT modified .
Standard_EXPORT void DepthFitAll(const Quantity_Coefficient Aspect = 0.01,const Quantity_Coefficient Margin = 0.01) ; //! Centres the defined projection window so that it occupies
//! the maximum space while respecting the initial
//! height/width ratio.
//! NOTE than the original Z size of the view is NOT modified .
Standard_EXPORT void FitAll(const V3d_Coordinate Umin,const V3d_Coordinate Vmin,const V3d_Coordinate Umax,const V3d_Coordinate Vmax) ; //! Centres the defined PIXEL window so that it occupies
//! the maximum space while respecting the initial
//! height/width ratio.
//! NOTE than the original Z size of the view is NOT modified .
Standard_EXPORT void WindowFit(const Standard_Integer Xmin,const Standard_Integer Ymin,const Standard_Integer Xmax,const Standard_Integer Ymax) ; //! Sets Z and XY size of the view according to given values
//! with respecting the initial view depth (eye position)
Standard_EXPORT void SetViewingVolume(const Standard_Real Left,const Standard_Real Right,const Standard_Real Bottom,const Standard_Real Top,const Standard_Real ZNear,const Standard_Real ZFar) ; //! Modifies the mapping of the view.
Standard_EXPORT void SetViewMapping(const Visual3d_ViewMapping& VM) ; //! Saves the current view mapping. This will be the
//! state returned from ResetViewmapping.
Standard_EXPORT void SetViewMappingDefault() ; //! Resets the centring of the view.
//! Updates the view
Standard_EXPORT void ResetViewMapping() ; //! Resets the centring and the orientation of the view
//! Updates the view
Standard_EXPORT void Reset(const Standard_Boolean update = Standard_True) ; //! Converts the PIXEL value
//! to a value in the projection plane.
Standard_EXPORT Quantity_Length Convert(const Standard_Integer Vp) const; //! Converts the point PIXEL into a point projected
//! in the reference frame of the projection plane.
Standard_EXPORT void Convert(const Standard_Integer Xp,const Standard_Integer Yp,V3d_Coordinate& Xv,V3d_Coordinate& Yv) const; //! Converts tha value of the projection plane into
//! a PIXEL value.
Standard_EXPORT Standard_Integer Convert(const Quantity_Length Vv) const; //! Converts the point defined in the reference frame
//! of the projection plane into a point PIXEL.
Standard_EXPORT void Convert(const V3d_Coordinate Xv,const V3d_Coordinate Yv,Standard_Integer& Xp,Standard_Integer& Yp) const; //! Converts the projected point into a point
//! in the reference frame of the view corresponding
//! to the intersection with the projection plane
//! of the eye/view point vector.
Standard_EXPORT void Convert(const Standard_Integer Xp,const Standard_Integer Yp,V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z) const; //! Converts the projected point into a point
//! in the reference frame of the view corresponding
//! to the intersection with the projection plane
//! of the eye/view point vector and returns the
//! projection ray for further computations.
Standard_EXPORT void ConvertWithProj(const Standard_Integer Xp,const Standard_Integer Yp,V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z,Quantity_Parameter& Vx,Quantity_Parameter& Vy,Quantity_Parameter& Vz) const; //! Converts the projected point into the nearest grid point
//! in the reference frame of the view corresponding
//! to the intersection with the projection plane
//! of the eye/view point vector and display the grid marker.
//! Warning: When the grid is not active the result is identical
//! to the above Convert() method.
//! How to use :
//! 1) Enable the grid echo display
//! myViewer->SetGridEcho(Standard_True);
//! 2) When application receive a move event :
//! 2.1) Check if any object is detected
//! if( myInteractiveContext->MoveTo(x,y) == AIS_SOD_Nothing ) {
//! 2.2) Check if the grid is active
//! if( myViewer->Grid()->IsActive() ) {
//! 2.3) Display the grid echo and gets the grid point
//! myView->ConvertToGrid(x,y,X,Y,Z);
//! 2.4) Else this is the standard case
//! } else myView->Convert(x,y,X,Y,Z);
Standard_EXPORT void ConvertToGrid(const Standard_Integer Xp,const Standard_Integer Yp,V3d_Coordinate& Xg,V3d_Coordinate& Yg,V3d_Coordinate& Zg) const; //! Converts the point into the nearest grid point
//! and display the grid marker.
Standard_EXPORT void ConvertToGrid(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,V3d_Coordinate& Xg,V3d_Coordinate& Yg,V3d_Coordinate& Zg) const; //! Projects the point defined in the reference frame of
//! the view into the projected point in the associated window.
Standard_EXPORT void Convert(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,Standard_Integer& Xp,Standard_Integer& Yp) const; //! Converts the point defined in the user space of
//! the view to the projected view plane point at z 0.
Standard_EXPORT void Project(const V3d_Coordinate X,const V3d_Coordinate Y,const V3d_Coordinate Z,V3d_Coordinate& Xp,V3d_Coordinate& Yp) const; //! Returns the Background color values of the view
//! depending of the color Type.
Standard_EXPORT void BackgroundColor(const Quantity_TypeOfColor Type,Quantity_Parameter& V1,Quantity_Parameter& V2,Quantity_Parameter& V3) const; //! Returns the Background color object of the view.
Standard_EXPORT Quantity_Color BackgroundColor() const; //! Returns the gradient background colour objects of the view.
Standard_EXPORT void GradientBackgroundColors(Quantity_Color& Color1,Quantity_Color& Color2) const; //! Returns the gradient background of the view.
Standard_EXPORT Aspect_GradientBackground GradientBackground() const; //! Returns the current value of the zoom expressed with
//! respect to SetViewMappingDefault().
Standard_EXPORT Quantity_Factor Scale() const; //! Returns the current values of the anisotropic (axial) scale factors.
Standard_EXPORT void AxialScale(Standard_Real& Sx,Standard_Real& Sy,Standard_Real& Sz) const; //! Returns the centre of the view.
Standard_EXPORT void Center(V3d_Coordinate& Xc,V3d_Coordinate& Yc) const; //! Returns the height and width of the view.
Standard_EXPORT void Size(Quantity_Length& Width,Quantity_Length& Height) const; //! Returns the Depth of the view .
Standard_EXPORT Standard_Real ZSize() const; //! Returns the position of the eye.
Standard_EXPORT void Eye(V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z) const; //! Returns the position of point which emanating the
//! projections.
Standard_EXPORT void FocalReferencePoint(V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z) const; //! Returns the coordinate of the point (Xpix,Ypix)
//! in the view (XP,YP,ZP), and the projection vector of the
//! view passing by the point (for PerspectiveView).
Standard_EXPORT void ProjReferenceAxe(const Standard_Integer Xpix,const Standard_Integer Ypix,V3d_Coordinate& XP,V3d_Coordinate& YP,V3d_Coordinate& ZP,V3d_Coordinate& VX,V3d_Coordinate& VY,V3d_Coordinate& VZ) const; //! Returns the Distance between the Eye and View Point.
Standard_EXPORT Quantity_Length Depth() const; //! Returns the projection vector.
Standard_EXPORT void Proj(Quantity_Parameter& Vx,Quantity_Parameter& Vy,Quantity_Parameter& Vz) const; //! Returns the position of the view point.
Standard_EXPORT void At(V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z) const; //! Returns the vector giving the position of the high point.
Standard_EXPORT void Up(Quantity_Parameter& Vx,Quantity_Parameter& Vy,Quantity_Parameter& Vz) const; //! Returns in RADIANS the orientation of the view around
//! the visual axis measured from the Y axis of the screen.
Standard_EXPORT Quantity_PlaneAngle Twist() const; //! Returns the current shading model.
Standard_EXPORT V3d_TypeOfShadingModel ShadingModel() const; Standard_EXPORT V3d_TypeOfSurfaceDetail SurfaceDetail() const; Standard_EXPORT Handle_Graphic3d_TextureEnv TextureEnv() const; //! Returns the transparency activity.
Standard_EXPORT Standard_Boolean Transparency() const; //! Returns the current visualisation mode.
Standard_EXPORT V3d_TypeOfVisualization Visualization() const; //! Indicates if the antialiasing is active (True) or
//! inactive (False).
Standard_EXPORT Standard_Boolean Antialiasing() const; //! Returns activity and information on the Zcueing.
//! : Depth of plane.
//! : Thickness around the plane.
Standard_EXPORT Standard_Boolean ZCueing(Quantity_Length& Depth,Quantity_Length& Width) const; //! Returns current information on the ZClipping.
//! : Depth of plane.
//! : Thickness around the plane.
//! : "BACK"
//! "FRONT"
//! "SLICE"
//! "OFF"
Standard_EXPORT V3d_TypeOfZclipping ZClipping(Quantity_Length& Depth,Quantity_Length& Width) const; //! Returns True if One light more can be
//! activated in this View.
Standard_EXPORT Standard_Boolean IfMoreLights() const; //! initializes an iteration on the active Lights.
Standard_EXPORT void InitActiveLights() ; //! returns true if there are more active Light(s) to return.
Standard_EXPORT Standard_Boolean MoreActiveLights() const; //! Go to the next active Light
//! (if there is not, ActiveLight will raise an exception)
Standard_EXPORT void NextActiveLights() ; Standard_EXPORT Handle_V3d_Light ActiveLight() const; //! Returns True if One clipping plane more can be
//! activated in this View.
Standard_EXPORT Standard_Boolean IfMorePlanes() const; //! initializes an iteration on the active Planes.
Standard_EXPORT void InitActivePlanes() ; //! returns true if there are more active Plane(s) to return.
Standard_EXPORT Standard_Boolean MoreActivePlanes() const; //! Go to the next active Plane
//! (if there is not, ActivePlane will raise an exception)
Standard_EXPORT void NextActivePlanes() ; Standard_EXPORT Handle_V3d_Plane ActivePlane() const; //! Returns the viewer in which the view has been created.
Standard_EXPORT Handle_V3d_Viewer Viewer() const; //! Returns True if MyView is associated with a window .
Standard_EXPORT Standard_Boolean IfWindow() const; //! Returns the Aspect Window associated with the view.
Standard_EXPORT Handle_Aspect_Window Window() const; //! Returns the Type of the View
Standard_EXPORT V3d_TypeOfView Type() const; //! translates the center of the view and zooms the view.
//! and updates the view.
Standard_EXPORT void Pan(const Standard_Integer Dx,const Standard_Integer Dy,const Quantity_Factor aZoomFactor = 1) ; //! Zoom the view according to a zoom factor computed
//! from the distance between the 2 mouse position ,
Standard_EXPORT void Zoom(const Standard_Integer X1,const Standard_Integer Y1,const Standard_Integer X2,const Standard_Integer Y2) ; //! Zoom the view according to a zoom factor computed
//! from the distance between the last and new mouse position
Standard_EXPORT void Zoom(const Standard_Integer X,const Standard_Integer Y) ; //! Defines the point (pixel) of zooming (for the method ZoomAtPoint()).
Standard_EXPORT void StartZoomAtPoint(const Standard_Integer xpix,const Standard_Integer ypix) ; //! Zooms the model at a pixel defined by the method StartZoomAtPoint().
Standard_EXPORT void ZoomAtPoint(const Standard_Integer mouseStartX,const Standard_Integer mouseStartY,const Standard_Integer mouseEndX,const Standard_Integer mouseEndY) ; //! Performs anisotropic scaling of view along the given .
//! The scale factor is calculated on a basis of
//! the mouse pointer displacement .
//! The calculated scale factor is then passed to SetAxialScale(Sx, Sy, Sz) method.
Standard_EXPORT void AxialScale(const Standard_Integer Dx,const Standard_Integer Dy,const V3d_TypeOfAxe Axis) ; //! Begin the rotation of the view arround the screen axis
//! according to the mouse position .
//! Warning: Enable rotation around the Z screen axis when
//! factor is > 0 soon the distance from the start point and the center
//! of the view is > (medium viewSize * ).
//! Generally a value of 0.4 is usable to rotate around XY screen axis
//! inside the circular treshold area and to rotate around Z screen axis
//! outside this area.
Standard_EXPORT void StartRotation(const Standard_Integer X,const Standard_Integer Y,const Quantity_Ratio zRotationThreshold = 0.0) ; //! Continues the rotation of the view
//! with an angle computed from the last and new mouse position .
Standard_EXPORT void Rotation(const Standard_Integer X,const Standard_Integer Y) ; //! Change View Plane Distance for Perspective Views
//! Warning! raises TypeMismatch from Standard if the view
//! is not a perspective view.
Standard_EXPORT void SetFocale(const Quantity_Length Focale) ; //! Returns the View Plane Distance for Perspective Views
Standard_EXPORT Quantity_Length Focale() const; //! Returns the associated Visual3d view.
Standard_EXPORT Handle_Visual3d_View View() const; //! Returns the current mapping of the view.
Standard_EXPORT Visual3d_ViewMapping ViewMapping() const; //! Returns the current orientation of the view.
Standard_EXPORT Visual3d_ViewOrientation ViewOrientation() const; //! Begins any graphics in the view
//! Redraw any structured graphics in the back buffer before
//! if is TRUE.
//! Restore the front buffer from the back before
//! if is FALSE.
//! if is TRUE.
//! the graphic managed itself exposure,resizing ...
//! if is FALSE.
//! the application must managed itself exposure,resizing ...
Standard_EXPORT Standard_Boolean TransientManagerBeginDraw(const Standard_Boolean DoubleBuffer = Standard_False,const Standard_Boolean RetainMode = Standard_False) const; //! Clear all transient graphics in the view
Standard_EXPORT void TransientManagerClearDraw() const; //! Begins any add graphics in the view
//! Redraw any structured graphics in the back buffer before
//! the application must managed itself exposure,resizing ...
//! Warning: Returns TRUE if transient drawing is enabled in
//! the associated view.
//! Returns FALSE ,if nothing works because something
//! is wrong for the transient principle :
Standard_EXPORT Standard_Boolean TransientManagerBeginAddDraw() const; //! Activates animation mode.
//! When the animation mode is activated in the view,
//! all Graphic3d_Structure are stored in a graphic object.
Standard_EXPORT void SetAnimationModeOn() ; //! Deactivates the animation mode.
Standard_EXPORT void SetAnimationModeOff() ; //! Returns the activity of the animation mode.
Standard_EXPORT Standard_Boolean AnimationModeIsOn() const; //! Enable/Disable animation/degeneration mode
Standard_EXPORT void SetAnimationMode(const Standard_Boolean anAnimationFlag = Standard_True,const Standard_Boolean aDegenerationFlag = Standard_False) ; //! Returns the animation and degenerate status.
Standard_EXPORT Standard_Boolean AnimationMode(Standard_Boolean& isDegenerate) const; //! Activates degenerate mode.
//! When the degenerate mode is activated in the view,
//! all Graphic3d_Structure with the type TOS_COMPUTED
//! displayed in this view are not computed.
//! Warning: Obsolete method , use SetComputedMode()
Standard_EXPORT void SetDegenerateModeOn() ; //! Deactivates the degenerate mode.
//! Category: Methods to modify the class definition
//! Warning: if the computed mode has been disabled in the
//! viewer the mode will remain degenerated.
//! Warning: Obsolete method , use SetComputedMode()
Standard_EXPORT void SetDegenerateModeOff() ; //! Returns the activity of the degenerate mode.
Standard_EXPORT Standard_Boolean DegenerateModeIsOn() const; //! Switches computed HLR mode in the view
Standard_EXPORT void SetComputedMode(const Standard_Boolean aMode) ; //! Returns the computed HLR mode state
Standard_EXPORT Standard_Boolean ComputedMode() const; //! idem than WindowFit
Standard_EXPORT void WindowFitAll(const Standard_Integer Xmin,const Standard_Integer Ymin,const Standard_Integer Xmax,const Standard_Integer Ymax) ; //! Set a plotter for plotting the contents of the view
//! field MyPlotter
Standard_EXPORT virtual void SetPlotter(const Handle(Graphic3d_Plotter)& aPlotter) ; //! Create a 2D View for plotting the contents of the view
Standard_EXPORT void Plot() ; //! Defines or Updates the definition of the
//! grid in
Standard_EXPORT void SetGrid(const gp_Ax3& aPlane,const Handle(Aspect_Grid)& aGrid) ; //! Defines or Updates the graphic definition of the
//! grid in
Standard_EXPORT void SetGridGraphicValues(const Handle(Aspect_Grid)& aGrid) ; //! Defines or Updates the activity of the
//! grid in
Standard_EXPORT void SetGridActivity(const Standard_Boolean aFlag) ; //! Animates the view
//! Returns the number of images per second
//! if is Standard_True, the animation mode
//! is activated.
Standard_EXPORT Standard_Real Tumble(const Standard_Integer NbImages = 314,const Standard_Boolean AnimationMode = Standard_False) ; //! dump the view
Standard_EXPORT void ScreenCopy(const Handle(PlotMgt_PlotterDriver)& aPlotterDriver,const Standard_Boolean fWhiteBackground = Standard_True,const Quantity_Factor aScale = 1.0) ; //! dump the full contents of the view at the same
//! scale in the file . The file name
//! extension must be one of ".png",".bmp",".jpg",".gif".
//! Returns FALSE when the dump has failed
Standard_EXPORT Standard_Boolean Dump(const Standard_CString theFile,const Image_TypeOfImage theBufferType = Image_TOI_RGB) ; //! dump the full contents of the view with a
//! different scale according to the required sheet
//! paper size (format) and the ratio
//! width/height of the view.
//! and returns FALSE when the dump has failed
//! Warning : the file name extension must be one of
//! ".png",".bmp",".jpg",".gif"
//! but make becarefull about the time to dump and
//! resulting file size especially for the A0 format.
//! NOTE that you can use after any standard system utility
//! for editing or sending the image file to a laser printer.
//! (i.e: Microsoft Photo Editor on Windows system
//! or Image Viewer on SUN system)
Standard_EXPORT Standard_Boolean Dump(const Standard_CString theFile,const Aspect_FormatOfSheetPaper theFormat,const Image_TypeOfImage theBufferType = Image_TOI_RGB) ; //! print the contents of the view to printer with preview.
//! : If you have already an PrinterDeviceContext (HDC),
//! then you can pass it to the print routines.
//! If you don't have an PrinterDeviceContext, then this parameter should
//! be NULL.
//! : If hPrnDC == NULL, then you can force the print routines to
//! open a Print Dialog box.
//! If you want to do this, then set showDialog to TRUE
//! If you don't want to see a dialog (only possible, if you have a hPrnDC
//! or the dialog box was opened once before) then set to FALSE.
//! : When set to FALSE then print the view without background color
//! (background is white)
//! else set to TRUE for printing with current background color.
//! : If != NULL, then the view will be printed to a file.
//! : If you want to select the print algorithm, then you can
//! specify one of existing algorithms: Aspect_PA_STRETCH, Aspect_PA_TILE.
//! Returns Standard_True if the data is passed to the printer, otherwise
//! Standard_False if the print operation failed. This might be related to
//! insufficient memory or some internal errors. All this errors are
//! indicated by the message boxes (on level of OpenGl_GraphicDriver).
//! Warning: This function can reuse FBO assigned to the
//! view on level of OpenGl_GraphicDriver; Please take it into account if
//! you use it for your purposes;
//! Warning: Works only under Windows.
Standard_EXPORT Standard_Boolean Print(const Aspect_Handle hPrnDC = NULL,const Standard_Boolean showDialog = Standard_True,const Standard_Boolean showBackground = Standard_True,const Standard_CString filename = NULL,const Aspect_PrintAlgo printAlgorithm = Aspect_PA_STRETCH) const; //! dump the full contents of the view
//! to a pixmap of pixel size * and
//! buffer type . If is true
//! view scene will be centered.
Standard_EXPORT Handle_Image_PixMap ToPixMap(const Standard_Integer theWidth,const Standard_Integer theHeight,const Image_TypeOfImage theBufferType = Image_TOI_RGB,const Standard_Boolean theForceCentered = Standard_True) ; //! Manages projection model
Standard_EXPORT void SetProjModel(const V3d_TypeOfProjectionModel amOdel = V3d_TPM_SCREEN) ; //! Returns the current projection model
Standard_EXPORT V3d_TypeOfProjectionModel ProjModel() const; //! Manages display of the back faces
//! When is TOBM_AUTOMATIC the object backfaces
//! are displayed only for surface objects and
//! never displayed for solid objects.
//! this was the previous mode.
//! is TOBM_ALWAYS_DISPLAYED the object backfaces
//! are always displayed both for surfaces or solids.
//! is TOBM_NEVER_DISPLAYED the object backfaces
//! are never displayed.
Standard_EXPORT void SetBackFacingModel(const V3d_TypeOfBackfacingModel aModel = V3d_TOBM_AUTOMATIC) ; //! Returns current state of the back faces display
Standard_EXPORT V3d_TypeOfBackfacingModel BackFacingModel() const; //! turns on/off opengl depth testing
Standard_EXPORT void EnableDepthTest(const Standard_Boolean enable = Standard_True) const; //! returns the current state of the depth testing
Standard_EXPORT Standard_Boolean IsDepthTestEnabled() const; //! turns on/off opengl lighting, currently used in triedron displaying
Standard_EXPORT void EnableGLLight(const Standard_Boolean enable = Standard_True) const; //! returns the current state of the gl lighting
//! currently used in triedron displaying
Standard_EXPORT Standard_Boolean IsGLLightEnabled() const; friend //! Activates all of the views of a viewer attached
//! to a window.
Standard_EXPORT void V3d_Viewer::SetViewOn() ; friend //! Activates a particular view in the Viewer .
//! Must be call if the Window attached to the view
//! has been Deiconified .
Standard_EXPORT void V3d_Viewer::SetViewOn(const Handle(V3d_View)& View) ; friend //! Deactivates all the views of a Viewer
//! attached to a window.
Standard_EXPORT void V3d_Viewer::SetViewOff() ; friend //! Deactivates a particular view in the Viewer.
//! Must be call if the Window attached to the view
//! has been Iconified .
Standard_EXPORT void V3d_Viewer::SetViewOff(const Handle(V3d_View)& View) ; DEFINE_STANDARD_RTTI(V3d_View) protected: //! Initialises the view.
Standard_EXPORT V3d_View(const Handle(V3d_Viewer)& VM,const V3d_TypeOfView Type = V3d_ORTHOGRAPHIC); //! Initialises the view by copying.
Standard_EXPORT V3d_View(const Handle(V3d_Viewer)& VM,const Handle(V3d_View)& V,const V3d_TypeOfView Type = V3d_ORTHOGRAPHIC); V3d_TypeOfView MyType; Handle_Visual3d_View MyView; Visual3d_ViewMapping MyViewMapping; V3d_TypeOfProjectionModel MyProjModel; private: //! Change the scale factor and position of the view
//! such as the bounding box is contains
//! in the view.
Standard_EXPORT void FitAll(const Handle(Aspect_Window)& aWindow,const V3d_Coordinate Umin,const V3d_Coordinate Vmin,const V3d_Coordinate Umax,const V3d_Coordinate Vmax) ; //! Determines the screen axes in the reference
//! framework of the view.
Standard_EXPORT static Standard_Boolean ScreenAxis(const Graphic3d_Vector& Vpn,const Graphic3d_Vector& Vup,Graphic3d_Vector& Xaxe,Graphic3d_Vector& Yaxe,Graphic3d_Vector& Zaxe) ; Standard_EXPORT static void InitMatrix(TColStd_Array2OfReal& Matrix) ; Standard_EXPORT static Standard_Boolean Multiply(const TColStd_Array2OfReal& Left,const TColStd_Array2OfReal& Right,TColStd_Array2OfReal& Matrix) ; //! Determines the rotation matrice around an axis
//! for a given angle.
Standard_EXPORT static void RotAxis(const Graphic3d_Vertex& Vrp,const Graphic3d_Vector& Axe,const Quantity_PlaneAngle Angle,TColStd_Array2OfReal& Matrix) ; //! Transforms the point P according to the matrice Matrix .
Standard_EXPORT static Graphic3d_Vertex TrsPoint(const Graphic3d_Vertex& P,const TColStd_Array2OfReal& Matrix) ; //! Transforms the vector V according to the matrice Matrix .
Standard_EXPORT static Graphic3d_Vector TrsPoint(const Graphic3d_Vector& V,const TColStd_Array2OfReal& Matrix) ; //! Returns the objects number and the projection window
//! of the objects contained in the view.
Standard_EXPORT Standard_Integer MinMax(V3d_Coordinate& Umin,V3d_Coordinate& Vmin,V3d_Coordinate& Umax,V3d_Coordinate& Vmax) const; //! Returns the objects number and the box encompassing
//! the objects contained in the view
Standard_EXPORT Standard_Integer MinMax(V3d_Coordinate& Xmin,V3d_Coordinate& Ymin,V3d_Coordinate& Zmin,V3d_Coordinate& Xmax,V3d_Coordinate& Ymax,V3d_Coordinate& Zmax) const; //! Returns the Objects number and the gravity center
//! of ALL viewable points in the view
Standard_EXPORT Standard_Integer Gravity(V3d_Coordinate& X,V3d_Coordinate& Y,V3d_Coordinate& Z) const; Standard_EXPORT void Init() ; //! Returns a new vertex when the grid is activated.
Standard_EXPORT Graphic3d_Vertex Compute(const Graphic3d_Vertex& AVertex) const; V3d_ViewerPointer MyViewer; V3d_ListOfTransient MyActiveLights; V3d_ListOfTransient MyActivePlanes; Visual3d_ViewOrientation MyViewOrientation; Visual3d_ContextView MyViewContext; Aspect_Background MyBackground; Aspect_GradientBackground MyGradientBackground; Graphic3d_Vector MyDefaultViewAxis; Graphic3d_Vertex MyDefaultViewPoint; Handle_Aspect_Window MyWindow; Handle_Graphic3d_Plotter MyPlotter; TColStd_ListIteratorOfListOfTransient myActiveLightsIterator; TColStd_ListIteratorOfListOfTransient myActivePlanesIterator; Standard_Integer sx; Standard_Integer sy; Standard_Real rx; Standard_Real ry; Standard_Real gx; Standard_Real gy; Standard_Real gz; Standard_Boolean myComputedMode; Standard_Boolean SwitchSetFront; Standard_Integer MyZoomAtPointX; Standard_Integer MyZoomAtPointY; Handle_Aspect_Grid MyGrid; gp_Ax3 MyPlane; Handle_V3d_LayerMgr MyLayerMgr; TColStd_Array2OfReal MyTrsf; Handle_Graphic3d_Structure MyGridEchoStructure; Handle_Graphic3d_Group MyGridEchoGroup; Standard_Integer MyAnimationFlags; Standard_Boolean MyTransparencyFlag; }; // other Inline functions and methods (like "C++: function call" methods) #endif