#include <V3d_View.hxx>
Inheritance diagram for V3d_View:
Public Member Functions | |
Standard_EXPORT void | SetWindow (const Handle(Aspect_Window)&IdWin) |
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)&aWindow, const Aspect_RenderingContext aContext, const Aspect_GraphicCallbackProc &aDisplayCB, const Standard_Address aClientData) |
Activates the view in the specified Window If <acontext> is not NULL the graphic context is used to draw something in this view. Otherwise an internal graphic context is created. If <adisplaycb> 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 <aclientdata> 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 | 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) |
Standard_EXPORT void | Remove () const |
Destroys the view. . | |
Standard_EXPORT void | Update () const |
Updates the display of the view. Must be called to update the view when the update mode is deferred (WAIT) . . | |
Standard_EXPORT void | Redraw () 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 Standard_Integer x, const Standard_Integer y, const Standard_Integer width, const Standard_Integer height) 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 | MustBeResized () |
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 | DoMapping () |
Must be called when the window supporting the view is mapped or unmapped. . | |
Standard_EXPORT Standard_Boolean | IsEmpty () const |
Returns the status of the view regarding the displayed structures inside Returns True is The View is empty . | |
Standard_EXPORT void | UpdateLights () const |
Updates the lights of the view. The view is redrawn. . | |
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 definition type, and the three corresponding values. . | |
Standard_EXPORT void | SetBackgroundColor (const Quantity_Color &Color) |
Defines the background colour of the view by supplying : the colour object. . | |
Standard_EXPORT void | SetBackgroundColor (const Quantity_NameOfColor Name) |
Defines the background colour of the view by supplying : the colour name in the form Quantity_NOC_xxxx . . | |
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) |
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) |
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 | SetShadingModel (const V3d_TypeOfShadingModel Model) |
Defines the shading model for the visualisation ZBUFFER mode. Various models are available. . | |
Standard_EXPORT void | SetSurfaceDetail (const V3d_TypeOfSurfaceDetail SurfaceDetail) |
select the kind of rendering for texture mapping no texture mapping by default | |
Standard_EXPORT void | SetTextureEnv (const Handle(Graphic3d_TextureEnv)&ATexture) |
set the environment texture to use no environment texture by default | |
Standard_EXPORT void | SetVisualization (const V3d_TypeOfVisualization Mode) |
Defines the visualisation mode in the view. . | |
Standard_EXPORT void | SetAntialiasingOn () |
Activates antialiasing in the view. . | |
Standard_EXPORT void | SetAntialiasingOff () |
Desactivates antialiasing in the view. . | |
Standard_EXPORT void | SetZClippingDepth (const Quantity_Length Depth) |
Defines the depth of the medium clipping plane. . | |
Standard_EXPORT void | SetZClippingWidth (const Quantity_Length Width) |
Defines the thicknes around the medium clippling plane. . . | |
Standard_EXPORT void | SetZClippingType (const V3d_TypeOfZclipping Type) |
Defines the type of ZClipping. . | |
Standard_EXPORT void | SetZCueingDepth (const Quantity_Length Depth) |
Defines the depth of the medium plane. . | |
Standard_EXPORT void | SetZCueingWidth (const Quantity_Length Width) |
Defines the thickness around the medium plane. . | |
Standard_EXPORT void | SetZCueingOn () |
Activates ZCueing in the view. . | |
Standard_EXPORT void | SetZCueingOff () |
Desactivates ZCueing in the view. . | |
Standard_EXPORT void | SetLightOn (const Handle(V3d_Light)&MyLight) |
Activates MyLight in the view. . | |
Standard_EXPORT void | SetLightOn () |
Activates all the lights defined in this view. . | |
Standard_EXPORT void | SetLightOff (const Handle(V3d_Light)&MyLight) |
Desactivate MyLight in this view. . | |
Standard_EXPORT void | SetLightOff () |
Deactivate all the Lights defined in this view. . | |
Standard_EXPORT Standard_Boolean | IsActiveLight (const Handle(V3d_Light)&aLight) const |
Returns TRUE when the light is active in this view. . | |
Standard_EXPORT void | SetTransparency (const Standard_Boolean AnActivity=Standard_False) |
Activate/Deactivate the transparency in this view. . | |
Standard_EXPORT void | SetPlaneOn (const Handle(V3d_Plane)&MyPlane) |
Activates the clipping plane in this view. //! If No More Plane can be activated in MyView . . | |
Standard_EXPORT void | SetPlaneOn () |
Activate all the clipping planes defined in this view. //! If No More Plane can be activated in MyView . . | |
Standard_EXPORT void | SetPlaneOff (const Handle(V3d_Plane)&MyPlane) |
Desactivates the clipping plane defined in this view. . | |
Standard_EXPORT void | SetPlaneOff () |
Deactivate all clipping planes defined in this view. . | |
Standard_EXPORT Standard_Boolean | IsActivePlane (const Handle(V3d_Plane)&aPlane) const |
Returns TRUE when the plane is active in this view. . | |
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) |
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 | 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) |
Display of the Triedron. Initialize position, color and length of Triedron axes. The scale is a percent of the window width. . | |
Standard_EXPORT void | TriedronErase () |
Erases the Triedron. . | |
Standard_EXPORT void | TriedronEcho (const Aspect_TypeOfTriedronEcho AType=Aspect_TOTE_NONE) |
Highlights the echo zone of the Triedron. . | |
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 |
Standard_EXPORT void | SetFront () |
modify the Projection of the view perpendicularly to the privileged plane of the viewer. | |
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 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 V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z, 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 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 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 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 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 | 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 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 V3d_TypeOfAxe Axe, const Quantity_Length Length, 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 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 | Translate (const Quantity_Length Dx, const Quantity_Length Dy, const Quantity_Length Dz, 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 V3d_TypeOfAxe Axe, const Quantity_Length Length, 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 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 | Place (const Standard_Integer x, const Standard_Integer y, const Quantity_Factor aZoomFactor=1) |
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 | 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 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 V3d_TypeOfAxe Axe, const Quantity_PlaneAngle Angle, 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 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 | SetTwist (const Quantity_PlaneAngle Angle) |
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 | SetEye (const V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z) |
Defines the position of the eye.. . | |
Standard_EXPORT void | SetDepth (const Quantity_Length Depth) |
Defines the Depth of the eye from the view point without update 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 orientation of the projection . . | |
Standard_EXPORT void | SetAt (const V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z) |
Defines the position of the view point. . | |
Standard_EXPORT void | SetUp (const Quantity_Parameter Vx, const Quantity_Parameter Vy, const Quantity_Parameter Vz) |
Defines the orientation of the high point. . | |
Standard_EXPORT void | SetUp (const V3d_TypeOfOrientation Orientation) |
Defines the orientation(SO) of the high point. . | |
Standard_EXPORT void | SetViewOrientation (const Visual3d_ViewOrientation &VO) |
Modifies the orientation of the view. . | |
Standard_EXPORT void | SetViewOrientationDefault () |
Saves the current state of the orientation of the view which will be the return state at ResetViewOrientation. . | |
Standard_EXPORT void | ResetViewOrientation () |
Resets the orientation of 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) |
translates the center of the view and zooms the view. Updates the view. | |
Standard_EXPORT void | SetCenter (const V3d_Coordinate Xc, const V3d_Coordinate Yc) |
Defines the centre of the view. Updates the view. . | |
Standard_EXPORT void | SetCenter (const Standard_Integer X, const Standard_Integer Y) |
Defines the centre of the view from a pixel position. Updates the view. . | |
Standard_EXPORT void | SetSize (const Quantity_Length Size) |
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 | SetZSize (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 | SetZoom (const Quantity_Factor Coef, const Standard_Boolean Start=Standard_True) |
Zooms the view by a factor relative to the initial value expressed by Start = Standard_True Updates the view. . | |
Standard_EXPORT void | SetScale (const Quantity_Factor Coef) |
Zooms the view by a factor relative to the value initialised by SetViewMappingDefault(). Updates the view. . | |
Standard_EXPORT void | SetAxialScale (const Standard_Real Sx, const Standard_Real Sy, const Standard_Real Sz) |
Sets anisotropic (axial) scale factors <sx>, <sy>, <sz> for view <me>. 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 | FitAll (const Quantity_Coefficient Coef=0.01, const Standard_Boolean FitZ=Standard_False, const Standard_Boolean update=Standard_True) |
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 | ZFitAll (const Quantity_Coefficient Coef=1.0) |
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 | DepthFitAll (const Quantity_Coefficient Aspect=0.01, const Quantity_Coefficient Margin=0.01) |
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 | FitAll (const V3d_Coordinate Umin, const V3d_Coordinate Vmin, const V3d_Coordinate Umax, const V3d_Coordinate Vmax) |
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 | WindowFit (const Standard_Integer Xmin, const Standard_Integer Ymin, const Standard_Integer Xmax, const Standard_Integer Ymax) |
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 | 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) |
Sets Z and XY size of the view according to given values with respecting the initial view depth (eye position) . | |
Standard_EXPORT void | SetViewMapping (const Visual3d_ViewMapping &VM) |
Modifies the mapping of the view. . | |
Standard_EXPORT void | SetViewMappingDefault () |
Saves the current view mapping. This will be the state returned from ResetViewmapping. . | |
Standard_EXPORT void | ResetViewMapping () |
Resets the centring of the view. Updates the view . | |
Standard_EXPORT void | Reset (const Standard_Boolean update=Standard_True) |
Resets the centring and the orientation of the view Updates the view . | |
Standard_EXPORT Quantity_Length | Convert (const Standard_Integer Vp) const |
Converts the PIXEL value to a value in the projection plane. . | |
Standard_EXPORT void | Convert (const Standard_Integer Xp, const Standard_Integer Yp, V3d_Coordinate &Xv, V3d_Coordinate &Yv) const |
Converts the point PIXEL into a point projected in the reference frame of the projection plane. . | |
Standard_EXPORT Standard_Integer | Convert (const Quantity_Length Vv) const |
Converts tha value of the projection plane into a PIXEL value. . | |
Standard_EXPORT void | Convert (const V3d_Coordinate Xv, const V3d_Coordinate Yv, Standard_Integer &Xp, Standard_Integer &Yp) const |
Converts the point defined in the reference frame of the projection plane into a point PIXEL. . | |
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. . | |
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 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 | ConvertToGrid (const Standard_Integer Xp, const Standard_Integer Yp, V3d_Coordinate &Xg, V3d_Coordinate &Yg, V3d_Coordinate &Zg) 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 V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z, 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 | Convert (const V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z, Standard_Integer &Xp, Standard_Integer &Yp) const |
Projects the point defined in the reference frame of the view into the projected point in the associated window. . | |
Standard_EXPORT void | Project (const V3d_Coordinate X, const V3d_Coordinate Y, const V3d_Coordinate Z, V3d_Coordinate &Xp, V3d_Coordinate &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 | BackgroundColor (const Quantity_TypeOfColor Type, Quantity_Parameter &V1, Quantity_Parameter &V2, Quantity_Parameter &V3) const |
Returns the Background color values of the view depending of the color Type. . | |
Standard_EXPORT Quantity_Color | BackgroundColor () const |
Returns the Background color object of the view. . | |
Standard_EXPORT Quantity_Factor | Scale () const |
Returns the current value of the zoom expressed with respect to SetViewMappingDefault(). . | |
Standard_EXPORT void | AxialScale (Standard_Real &Sx, Standard_Real &Sy, Standard_Real &Sz) const |
Returns the current values of the anisotropic (axial) scale factors. . | |
Standard_EXPORT void | Center (V3d_Coordinate &Xc, V3d_Coordinate &Yc) const |
Returns the centre of the view. . | |
Standard_EXPORT void | Size (Quantity_Length &Width, Quantity_Length &Height) const |
Returns the height and width of the view. . | |
Standard_EXPORT Standard_Real | ZSize () const |
Returns the Depth of the view . . | |
Standard_EXPORT void | Eye (V3d_Coordinate &X, V3d_Coordinate &Y, V3d_Coordinate &Z) const |
Returns the position of the eye. . | |
Standard_EXPORT void | FocalReferencePoint (V3d_Coordinate &X, V3d_Coordinate &Y, V3d_Coordinate &Z) const |
Returns the position of point which emanating the projections. . | |
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 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 Quantity_Length | Depth () const |
Returns the Distance between the Eye and View Point. . | |
Standard_EXPORT void | Proj (Quantity_Parameter &Vx, Quantity_Parameter &Vy, Quantity_Parameter &Vz) const |
Returns the projection vector. . | |
Standard_EXPORT void | At (V3d_Coordinate &X, V3d_Coordinate &Y, V3d_Coordinate &Z) const |
Returns the position of the view point. . | |
Standard_EXPORT void | Up (Quantity_Parameter &Vx, Quantity_Parameter &Vy, Quantity_Parameter &Vz) const |
Returns the vector giving the position of the high point. . | |
Standard_EXPORT Quantity_PlaneAngle | Twist () const |
Returns in RADIANS the orientation of the view around the visual axis measured from the Y axis of the screen. . | |
Standard_EXPORT V3d_TypeOfShadingModel | ShadingModel () const |
Returns the current shading model. . | |
Standard_EXPORT V3d_TypeOfSurfaceDetail | SurfaceDetail () const |
Standard_EXPORT Handle_Graphic3d_TextureEnv | TextureEnv () const |
Standard_EXPORT Standard_Boolean | Transparency () const |
Returns the transparency activity. . | |
Standard_EXPORT V3d_TypeOfVisualization | Visualization () const |
Returns the current visualisation mode. . | |
Standard_EXPORT Standard_Boolean | Antialiasing () const |
Indicates if the antialiasing is active (True) or inactive (False). . | |
Standard_EXPORT Standard_Boolean | ZCueing (Quantity_Length &Depth, Quantity_Length &Width) const |
Returns activity and information on the Zcueing. <depth> : Depth of plane. <width> : Thickness around the plane. . | |
Standard_EXPORT V3d_TypeOfZclipping | ZClipping (Quantity_Length &Depth, Quantity_Length &Width) const |
Returns current information on the ZClipping. <depth> : Depth of plane. <width> : Thickness around the plane. <typeofzclipping> : "BACK" "FRONT" "SLICE" "OFF" . | |
Standard_EXPORT Standard_Boolean | IfMoreLights () const |
Returns True if One light more can be activated in this View. . | |
Standard_EXPORT void | InitActiveLights () |
initializes an iteration on the active Lights. | |
Standard_EXPORT Standard_Boolean | MoreActiveLights () const |
returns true if there are more active Light(s) to return. | |
Standard_EXPORT void | NextActiveLights () |
Go to the next active Light (if there is not, ActiveLight will raise an exception) . | |
Standard_EXPORT Handle_V3d_Light | ActiveLight () const |
Standard_EXPORT Standard_Boolean | IfMorePlanes () const |
Returns True if One clipping plane more can be activated in this View. . | |
Standard_EXPORT void | InitActivePlanes () |
initializes an iteration on the active Planes. | |
Standard_EXPORT Standard_Boolean | MoreActivePlanes () const |
returns true if there are more active Plane(s) to return. | |
Standard_EXPORT void | NextActivePlanes () |
Go to the next active Plane (if there is not, ActivePlane will raise an exception) . | |
Standard_EXPORT Handle_V3d_Plane | ActivePlane () const |
Standard_EXPORT Handle_V3d_Viewer | Viewer () const |
Returns the viewer in which the view has been created. . | |
Standard_EXPORT Standard_Boolean | IfWindow () const |
Returns True if MyView is associated with a window . . | |
Standard_EXPORT Handle_Aspect_Window | Window () const |
Returns the Aspect Window associated with the view. . | |
Standard_EXPORT V3d_TypeOfView | Type () const |
Returns the Type of the View . | |
Standard_EXPORT void | Pan (const Standard_Integer Dx, const Standard_Integer Dy, const Quantity_Factor aZoomFactor=1) |
translates the center of the view and zooms the view. and updates the view. | |
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 2 mouse position <X1,Y1>,<X2,Y2> . | |
Standard_EXPORT void | Zoom (const Standard_Integer X, const Standard_Integer Y) |
Zoom the view according to a zoom factor computed from the distance between the last and new mouse position <X,Y> . | |
Standard_EXPORT void | AxialScale (const Standard_Integer Dx, const Standard_Integer Dy, const V3d_TypeOfAxe Axis) |
Performs anisotropic scaling of <me> view along the given <axis>. The scale factor is calculated on a basis of the mouse pointer displacement <Dx,Dy>. The calculated scale factor is then passed to SetAxialScale(Sx, Sy, Sz) method. . | |
Standard_EXPORT void | StartRotation (const Standard_Integer X, const Standard_Integer Y, const Quantity_Ratio zRotationThreshold=0.0) |
Begin the rotation of the view arround the screen axis according to the mouse position <X,Y>. Warning: Enable rotation around the Z screen axis when <zrotationthreshold> factor is > 0 soon the distance from the start point and the center of the view is > (medium viewSize * <zrotationthreshold> ). 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 | Rotation (const Standard_Integer X, const Standard_Integer Y) |
Continues the rotation of the view with an angle computed from the last and new mouse position <X,Y>. . | |
Standard_EXPORT void | SetFocale (const Quantity_Length Focale) |
Change View Plane Distance for Perspective Views //! Warning! raises TypeMismatch from Standard if the view is not a perspective view. . | |
Standard_EXPORT Quantity_Length | Focale () const |
Returns the View Plane Distance for Perspective Views . | |
Standard_EXPORT Handle_Visual3d_View | View () const |
Returns the associated Visual3d view. . | |
Standard_EXPORT Visual3d_ViewMapping | ViewMapping () const |
Returns the current mapping of the view. . | |
Standard_EXPORT Visual3d_ViewOrientation | ViewOrientation () const |
Returns the current orientation of the view. . | |
Standard_EXPORT Standard_Boolean | TransientManagerBeginDraw (const Standard_Boolean DoubleBuffer=Standard_False, const Standard_Boolean RetainMode=Standard_False) const |
Begins any graphics in the view <aview> Redraw any structured graphics in the back buffer before if <doublebuffer> is TRUE. Restore the front buffer from the back before if <doublebuffer> is FALSE. if <retainmode> is TRUE. the graphic managed itself exposure,resizing ... if <retainmode> is FALSE. the application must managed itself exposure,resizing ... . | |
Standard_EXPORT void | TransientManagerClearDraw () const |
Clear all transient graphics in the view <aview> . | |
Standard_EXPORT Standard_Boolean | TransientManagerBeginAddDraw () const |
Begins any add graphics in the view <aview> 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 void | SetAnimationModeOn () |
Activates animation mode. When the animation mode is activated in the view, all Graphic3d_Structure are stored in a graphic object. . | |
Standard_EXPORT void | SetAnimationModeOff () |
Deactivates the animation mode. . | |
Standard_EXPORT Standard_Boolean | AnimationModeIsOn () const |
Returns the activity of the animation mode. . | |
Standard_EXPORT void | SetAnimationMode (const Standard_Boolean anAnimationFlag=Standard_True, const Standard_Boolean aDegenerationFlag=Standard_False) |
Enable/Disable animation/degeneration mode . | |
Standard_EXPORT Standard_Boolean | AnimationMode (Standard_Boolean &isDegenerate) const |
Returns the animation and degenerate status. . | |
Standard_EXPORT void | SetDegenerateModeOn () |
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 | SetDegenerateModeOff () |
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 Standard_Boolean | DegenerateModeIsOn () const |
Returns the activity of the degenerate mode. . | |
Standard_EXPORT void | SetComputedMode (const Standard_Boolean aMode) |
Switches computed HLR mode in the view . | |
Standard_EXPORT Standard_Boolean | ComputedMode () const |
Returns the computed HLR mode state . | |
Standard_EXPORT void | WindowFitAll (const Standard_Integer Xmin, const Standard_Integer Ymin, const Standard_Integer Xmax, const Standard_Integer Ymax) |
idem than WindowFit | |
virtual Standard_EXPORT void | SetPlotter (const Handle(Graphic3d_Plotter)&aPlotter) |
Set a plotter for plotting the contents of the view field MyPlotter . | |
Standard_EXPORT void | Plot () |
Create a 2D View for plotting the contents of the view . | |
Standard_EXPORT void | SetGrid (const gp_Ax3 &aPlane, const Handle(Aspect_Grid)&aGrid) |
Defines or Updates the definition of the grid in <me> . | |
Standard_EXPORT void | SetGridGraphicValues (const Handle(Aspect_Grid)&aGrid) |
Defines or Updates the graphic definition of the grid in <me> . | |
Standard_EXPORT void | SetGridActivity (const Standard_Boolean aFlag) |
Defines or Updates the activity of the grid in <me> . | |
Standard_EXPORT Standard_Real | Tumble (const Standard_Integer NbImages=314, const Standard_Boolean AnimationMode=Standard_False) |
Animates the view <me> Returns the number of images per second if <animationmode> is Standard_True, the animation mode is activated. . | |
Standard_EXPORT void | ScreenCopy (const Handle(PlotMgt_PlotterDriver)&aPlotterDriver, const Standard_Boolean fWhiteBackground=Standard_True, const Quantity_Factor aScale=1.0) |
dump the view | |
Standard_EXPORT Standard_Boolean | Dump (const Standard_CString aFile) |
dump the full contents of the view at the same scale in the file <afile>. The file name extension must be one of ".xwd",".gif",".bmp" both on UNIX or WNT. and returns FALSE when the dump has failed | |
Standard_EXPORT Standard_Boolean | Dump (const Standard_CString aFile, const Aspect_FormatOfSheetPaper aFormat) |
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 ".xwd",".gif",".bmp" both on UNIX or WNT but make becarefull about the time to dump and resulting file size especially for the A0 format, GIF format generates very small files, BMP and XWD generates big files (4 to 6 times more than GIF). Time to generates the files is very short with XWD files and 2 or 4 times more for other 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 void | Print (const Aspect_Handle hPrnDC=NULL, const Standard_Boolean showDialog=Standard_True, const Standard_Boolean showBackground=Standard_True, const Standard_CString filename=NULL) const |
print the contents of the view to printer with preview. <hprndc> : 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. <showdialog> : 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 <showdialog> to FALSE. <showbackground> : When set to FALSE then print the view without background color (background is white) else set to TRUE for printing with current background color. <filename>: If != NULL, then the view will be printed to a file. Warning: Works only under Windows. | |
Standard_EXPORT Handle_Aspect_PixMap | ToPixMap (const Standard_Integer aWidth, const Standard_Integer aHeight, const Standard_Integer aCDepth=24) |
dump the full contents of the view to a pixmap of pixel size <awidth>*<aheight> and planes depth <acdepth> | |
Standard_EXPORT void | SetProjModel (const V3d_TypeOfProjectionModel amOdel=V3d_TPM_SCREEN) |
Manages projection model . | |
Standard_EXPORT V3d_TypeOfProjectionModel | ProjModel () const |
Returns the current projection model . | |
Standard_EXPORT void | SetBackFacingModel (const V3d_TypeOfBackfacingModel aModel=V3d_TOBM_AUTOMATIC) |
Manages display of the back faces When <amodel> is TOBM_AUTOMATIC the object backfaces are displayed only for surface objects and never displayed for solid objects. this was the previous mode. <amodel> is TOBM_ALWAYS_DISPLAYED the object backfaces are always displayed both for surfaces or solids. <amodel> is TOBM_NEVER_DISPLAYED the object backfaces are never displayed. . | |
Standard_EXPORT V3d_TypeOfBackfacingModel | BackFacingModel () const |
Returns current state of the back faces display . | |
Standard_EXPORT void | EnableDepthTest (const Standard_Boolean enable=Standard_True) const |
turns on/off opengl depth testing | |
Standard_EXPORT Standard_Boolean | IsDepthTestEnabled () const |
returns the current state of the depth testing | |
Standard_EXPORT void | EnableGLLight (const Standard_Boolean enable=Standard_True) const |
turns on/off opengl lighting, currently used in triedron displaying | |
Standard_EXPORT Standard_Boolean | IsGLLightEnabled () const |
returns the current state of the gl lighting currently used in triedron displaying | |
Standard_EXPORT const | Handle (Standard_Type)&DynamicType() const |
Protected Member Functions | |
Standard_EXPORT | V3d_View (const Handle(V3d_Viewer)&VM, const V3d_TypeOfView Type=V3d_ORTHOGRAPHIC) |
Initialises the view. . | |
Standard_EXPORT | V3d_View (const Handle(V3d_Viewer)&VM, const Handle(V3d_View)&V, const V3d_TypeOfView Type=V3d_ORTHOGRAPHIC) |
Initialises the view by copying. . | |
Protected Attributes | |
V3d_TypeOfView | MyType |
Handle_Visual3d_View | MyView |
Visual3d_ViewMapping | MyViewMapping |
V3d_TypeOfProjectionModel | MyProjModel |
Private Member Functions | |
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) |
Change the scale factor and position of the view such as the bounding box <Umin, Vmin, Umax, Vmax> is contains 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 projection window of 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 box encompassing the objects contained in the view . | |
Standard_EXPORT Standard_Integer | Gravity (V3d_Coordinate &X, V3d_Coordinate &Y, V3d_Coordinate &Z) const |
Returns the Objects number and the gravity center of ALL viewable points in the view . | |
Standard_EXPORT void | Init () |
Standard_EXPORT Graphic3d_Vertex | Compute (const Graphic3d_Vertex &AVertex) const |
Returns a new vertex when the grid is activated. . | |
Static Private Member Functions | |
static Standard_EXPORT Standard_Boolean | ScreenAxis (const Graphic3d_Vector &Vpn, const Graphic3d_Vector &Vup, Graphic3d_Vector &Xaxe, Graphic3d_Vector &Yaxe, Graphic3d_Vector &Zaxe) |
Determines the screen axes in the reference framework of the view. . | |
static Standard_EXPORT void | InitMatrix (TColStd_Array2OfReal &Matrix) |
static Standard_EXPORT Standard_Boolean | Multiply (const TColStd_Array2OfReal &Left, const TColStd_Array2OfReal &Right, TColStd_Array2OfReal &Matrix) |
static Standard_EXPORT void | RotAxis (const Graphic3d_Vertex &Vrp, const Graphic3d_Vector &Axe, const Quantity_PlaneAngle Angle, TColStd_Array2OfReal &Matrix) |
Determines the rotation matrice around an axis for a given angle. . | |
static Standard_EXPORT Graphic3d_Vertex | TrsPoint (const Graphic3d_Vertex &P, const TColStd_Array2OfReal &Matrix) |
Transforms the point P according to the matrice Matrix . . | |
static Standard_EXPORT Graphic3d_Vector | TrsPoint (const Graphic3d_Vector &V, const TColStd_Array2OfReal &Matrix) |
Transforms the vector V according to the matrice Matrix . . | |
Private Attributes | |
V3d_ViewerPointer | MyViewer |
V3d_ListOfTransient | MyActiveLights |
V3d_ListOfTransient | MyActivePlanes |
Visual3d_ViewOrientation | MyViewOrientation |
Visual3d_ContextView | MyViewContext |
Aspect_Background | MyBackground |
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 |
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 |
Friends | |
Standard_EXPORT void | V3d_Viewer::SetViewOn () |
Activates all of the views of a viewer attached to a window. . | |
Standard_EXPORT void | V3d_Viewer::SetViewOn (const Handle(V3d_View)&View) |
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::SetViewOff () |
Deactivates all the views of a Viewer attached to a window. . | |
Standard_EXPORT void | V3d_Viewer::SetViewOff (const Handle(V3d_View)&View) |
Deactivates a particular view in the Viewer. Must be call if the Window attached to the view has been Iconified . . |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Reimplemented from Viewer_View. Reimplemented in V3d_OrthographicView, and V3d_PerspectiveView. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Implements Viewer_View. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Implements Viewer_View. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Implements Viewer_View. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|