All Frameworks Class Hierarchy This Framework Indexes
Visualization Class CATViewer
Usage: you must use this class as is. You should never derive it.
public class CATViewer
Class to display Graphic Representations on the screen.
Constructor and Destructor Index
- o
~CATViewer()
-
Method Index
- o
AddRepFurtive(CAT2DRep*)
- Adds a furtive representation in the Main CAT2DViewpoint.
- o
AddRepFurtive(CAT3DRep*)
- Adds a 3D furtive representation in the main CAT3DViewpoint.
- o
AddRep(CAT2DRep*)
- Adds a representation 2D in the main CAT2DViewpoint.
- o
AddRep(CAT3DRep*)
- Adds a representation 3D in the Main 3D Viewpoint.
- o
AddViewpoint(CATViewpoint*,CATViewerPlacement)
- Adds a new viewpoint in the Viewer's list with the highest/lowest priority.
- o
CATDeclareCBEvent(VIEWER_FEEDBACK_UPDATE)
- Event sent when something happens to the viewer.
- o
ClassId()
- Returns the class identifier for which the given object is an instance.
- o
DisplayNextViewpoint()
- Restores the Viewpoint store after the current viepoint.
- o
DisplayPreviousViewpoint()
- Restores the Viewpoint store before the current viepoint.
- o
DrawElement(CATRepPath&)
- Draws a CATRepPath without redrawing the entire screen .
- o
DrawElements(list<CATRepPath>&)
- Draws a list of CATRepPath without redrawing the entire screen.
- o
Draw()
- Asks for generating a new "image" displayed in the Viewer's screen.
- o
End2DRemoveRepsFurtive()
- Updates the 2D viewpoint to take into account the removal of reps.
- o
End2DRemoveReps()
- Updates the 2D viewpoint to take into account the removal of reps.
- o
EndRemoveRepsFurtive()
- Updates the 3D viewpoint to take into account the removal of reps.
- o
EndRemoveReps()
- Updates the 3D viewpoint to take into account the removal of reps.
- o
GetBackgroundColor(float*,float*,float*)
- Retreives the background color.
- o
GetCATColormap()
- Gets the CATColormMap.
- o
GetContextualMenu()
- Gets the CATDlgContextualMenu displayed when you right click on the viewer.
- o
GetDefaultBackgroundIndicator()
- Gets the default CATIndicator associated to the backGround.
- o
GetFeedbackMode()
- Returns the feedback mode.
- o
GetGlobalAmbientLight(float*,float*,float*)
- Retreives the global ambient light color.
- o
GetGraphicSize(float*,float*)
- Gets the size in pixel of the viewer.
- o
GetLightSourceReps(CAT3DLightSourceRep*&,CAT3DLightSourceRep*&)
- Gets the two CAT3DLightSourceRep associated to the viewer.
- o
GetMMInSupportUnit()
- Gets the Inverse of the size(height) of a pixel in millimeter.
- o
GetMain2DViewpoint()
- Gets the main CAT2DViewopint.
- o
GetMain3DViewpoint()
- Gets the main CAT3DViewopint.
- o
GetMainViewpoint()
- Gets the main viewpoint.
- o
GetManipulatorToActive()
- Gets the CATManipulator to activate.
- o
GetOverlayViewpoint()
- Gets the OverlayViewpoint.
- o
GetPickingOptions()
- Gets the options attached to this viewer for picking.
- o
GetSupport()
- Gets the CATSupport associated to the CATViewer.
- o
IsBackgroundGraduated()
- Gets whether or not the background is graduated.
- o
IsFullScreen()
- Gets whether or not the Viewer is in fullScreen.
- o
IsNextViewpoint()
- Gets wether or not there is a viewpoint store after the current one.
- o
IsPreviousViewpoint()
- Gets wether or not there is a viewpoint store before the current one.
- o
Pick(CATPickingStyle,float,float,float,float,CATPickPathList&,CATRepPath*,float*,int,int)
- Generates a CATPickPathList corresponding to all representations laying under
the given position.
- o
Pick(CATPickingStyle,CATMathPointf&,CATMathDirectionf&,float,float,float,float,CATPickPathList&,CATRepPath*,int)
- Generates a CATPickPathList corresponding to all representations laying under
the given position.
- o
Reframe()
- Changes the Main Viewpoint to have all the repreentations visible on screen.
- o
RemoveManipulatorToActive()
- Removes the CATManipulator to be activated.
- o
RemoveRepFurtive(CAT2DRep*)
- Removes a 2D furtive representation from Main 2D Viewpoint .
- o
RemoveRepFurtive(CAT3DRep*)
- Removes a 3D furtive representation from main 3D Viewpoint.
- o
RemoveRep(CAT2DRep*)
- Removes a representation 2D from the main CAT2DViewpoint.
- o
RemoveRep(CAT3DRep*)
- Removes a representation 3D from the main CAT3DViewpoint.
- o
RemoveRepsFurtive(CAT2DRep*)
- Removes a furtive representation from the Main 2D Viewpoint.
- o
RemoveRepsFurtive(CAT3DRep*)
- Removes a furtive representation from the main 3D Viewpoint.
- o
RemoveReps(CAT2DRep*)
- Removes a representation 2D from the main CAT2DViewpoint.
- o
RemoveReps(CAT3DRep*)
- Removes a representation 3D from the Main CAT3DViewpoint to be visualized.
- o
RemoveViewpoint(CATViewpoint*)
- Removes the viewpoint from the viewer's list.
- o
Resize(float,float)
- Resize the viewer.
- o
SaveViewpoint()
- Stores the Current MainViewpoint so that it can be restored later.
- o
SetBackgroundColor(float,float,float,int)
- Sets the background color.
- o
SetCursor(CATDialog::CATDlgCursor)
- Sets the cursor displayed when the mouse is over the viewer.
- o
SetFeedbackMode(CATBoolean)
- Sets the feedback mode.
- o
SetFullScreen(int)
- Sets the viewer's FullScreen state.
- o
SetGlobalAmbientLight(float,float,float)
- Sets the global ambient light color.
- o
SetGraduatedBackground(int)
- Sets whether or not the background is graduated.
- o
SetIndicator(CATIndicator*,CATViewerPlacement)
- Sets the current indicator.
- o
SetLightSourceReps(CAT3DLightSourceRep*,CAT3DLightSourceRep*)
- Sets the two CAT3DLightSourceRep associated to the viewer.
- o
SetMainViewpoint(CATViewpoint*)
- Sets the main viewpoint of the viewer.
- o
SetManipulatorToActive(CATManipulator*)
- Sets the CATManipulator to activate on next mouse interaction.
- o
SetViewMode(int,int)
- Sets the viewmode for viewer enclosed in the current CATSupport.
- o
UndrawElement(CATRepPath&)
- Undraws a CATRepPath if it is Furtive .
- o
UndrawElements(list<CATRepPath>&)
- Undraws a list of CATRepPath if they are Furtive .
- o
ViewMode(int)
- Returns whether or not the given mode is active.
Constructor and Destructor
o ~CATViewer
| public virtual ~CATViewer( | ) |
-
Methods
o AddRepFurtive
| public virtual AddRepFurtive( | | iRep) |
-
Adds a furtive representation in the Main CAT2DViewpoint.
Role:The furtive representation will be displayed
with the XOR color. See the
DrawElement method
- Parameters:
-
- iRep
- the
CAT2DRep to add
o AddRepFurtive
| public virtual AddRepFurtive( | | iRep) |
-
Adds a 3D furtive representation in the main CAT3DViewpoint.
- Parameters:
-
- iRep
- The 3D Rep to add
o AddRep
| public virtual AddRep( | | iRep) |
-
Adds a representation 2D in the main CAT2DViewpoint.
The representation will appear only at the next
CATViewer.Draw
- Parameters:
-
- iRep
- The
CAT2DRep to add
o AddRep
| public virtual AddRep( | | iRep) |
-
Adds a representation 3D in the Main 3D Viewpoint.
The representation will appears only at the next CATViewer::Draw
- Parameters:
-
- iRep
- The rep to Add
o AddViewpoint
| public AddViewpoint( | | iViewpoint, |
| const | iPlace) |
-
Adds a new viewpoint in the Viewer's list with the highest/lowest priority.
The representations of this viewpoint will be displayed behind the other viewpoints
- Parameters:
-
- iViewpoint
- the Viewpoint to add
- iPlace
- Legal values: Foreground and Background
o CATDeclareCBEvent
| public CATDeclareCBEvent( | | ) |
-
Event sent when something happens to the viewer.
Role: This event contains a
CATVisViewerFeedbackEvent class pointer to describe itself. This event is not dispatched when the end user uses the Preselection Navigator.
Sample of callback:
::AddCallback(this,
_myViewer,
CATViewer::VIEWER_FEEDBACK_UPDATE(),
(CATSubscriberMethod)&MyClass::MyCBMethod,
NULL);
o ClassId
-
Returns the class identifier for which the given object is an instance.
o DisplayNextViewpoint
| public virtual DisplayNextViewpoint( | ) |
-
Restores the Viewpoint store after the current viepoint.
o DisplayPreviousViewpoint
| public virtual DisplayPreviousViewpoint( | ) |
-
Restores the Viewpoint store before the current viepoint.
o DrawElement
| public virtual DrawElement( | | iPath) |
-
Draws a CATRepPath without redrawing the entire screen .
if the
CATRepPath is furtive. The
CATRepPath is drawn in XOR mode
- Parameters:
-
- iPath
- the CATRepPath to redraw
o DrawElements
| public virtual DrawElements( | | iPaths) |
-
Draws a list of CATRepPath without redrawing the entire screen.
if the
CATRepPath is furtive. The
CATRepPath is drawn in XOR mode
- Parameters:
-
- iPaths
- the list of
CATRepPath to redraw
o Draw
-
Asks for generating a new "image" displayed in the Viewer's screen.
This image is composed of all representations attached to each viewpoint.
This image is not computed immediately but as soon as possible.
o End2DRemoveRepsFurtive
| public virtual End2DRemoveRepsFurtive( | ) |
-
Updates the 2D viewpoint to take into account the removal of reps.
Call that method after removing many representations with RemoveRepsFurtive
o End2DRemoveReps
| public virtual End2DRemoveReps( | ) |
-
Updates the 2D viewpoint to take into account the removal of reps.
Call that method after removing many representations with RemoveReps
o EndRemoveRepsFurtive
| public virtual EndRemoveRepsFurtive( | ) |
-
Updates the 3D viewpoint to take into account the removal of reps.
Call that method after removing many representations with RemoveRepsFurtive
o EndRemoveReps
| public virtual EndRemoveReps( | ) |
-
Updates the 3D viewpoint to take into account the removal of reps.
Call that method after removing many representations with RemoveReps
o GetBackgroundColor
| public GetBackgroundColor( | | oR, |
| | oG, |
| | oB) |
-
Retreives the background color.
- Parameters:
-
- oR
- the red composant color.
- oG
- the green composant color.
- oB
- the blue composant color.
o GetCATColormap
-
Gets the CATColormMap.
- Returns:
- the CATColorMap
o GetContextualMenu
| public GetContextualMenu( | ) |
-
Gets the CATDlgContextualMenu displayed when you right click on the viewer.
o GetDefaultBackgroundIndicator
| public GetDefaultBackgroundIndicator( | ) |
-
Gets the default CATIndicator associated to the backGround.
o GetFeedbackMode
-
Returns the feedback mode.
- Returns:
- The feedback mode.
TRUE if the feedback mode is active, FALSE otherwise.
o GetGlobalAmbientLight
| public GetGlobalAmbientLight( | | oR, |
| | oG, |
| | oB) |
-
Retreives the global ambient light color.
- Parameters:
-
- oR
- the red composant color.
- oG
- the green composant color.
- oB
- the blue composant color.
o GetGraphicSize
| public GetGraphicSize( | | owidth, |
| | oheight) |
-
Gets the size in pixel of the viewer.
- Parameters:
-
- owidth
-
- oheight
o GetLightSourceReps
| public GetLightSourceReps( | const | lightRep1, |
| const | lightRep2) |
-
Gets the two CAT3DLightSourceRep associated to the viewer.
o GetMMInSupportUnit
| public GetMMInSupportUnit( | ) |
-
Gets the Inverse of the size(height) of a pixel in millimeter.
o GetMain2DViewpoint
| public GetMain2DViewpoint( | ) |
-
Gets the main CAT2DViewopint.
- Returns:
- the main
CAT2DViewpoint
o GetMain3DViewpoint
| public GetMain3DViewpoint( | ) |
-
Gets the main CAT3DViewopint.
- Returns:
- the main
CAT3DViewpoint
o GetMainViewpoint
| public GetMainViewpoint( | ) |
-
Gets the main viewpoint.
This viewpoint is the one being modified by local transformations
o GetManipulatorToActive
| public GetManipulatorToActive( | ) |
-
Gets the CATManipulator to activate.
- Returns:
- the
CATManipulator to Activate
o GetOverlayViewpoint
| public GetOverlayViewpoint( | ) |
-
Gets the OverlayViewpoint.
Role:
This viewpoint is a
CAT2DViewpoint displayed in front of any other representation
- Returns:
- the overlay
CAT2DViewpoint
o GetPickingOptions
| public GetPickingOptions( | ) |
-
Gets the options attached to this viewer for picking.
- Returns:
- the options used for picking.
o GetSupport
-
Gets the CATSupport associated to the CATViewer.
- Returns:
- the
CATSupport
o IsBackgroundGraduated
| public IsBackgroundGraduated( | ) |
-
Gets whether or not the background is graduated.
- Returns:
- the result of the test
o IsFullScreen
| public virtual IsFullScreen( | ) |
-
Gets whether or not the Viewer is in fullScreen.
o IsNextViewpoint
| public virtual IsNextViewpoint( | ) |
-
Gets wether or not there is a viewpoint store after the current one.
- Returns:
- the result of the test
o IsPreviousViewpoint
| public virtual IsPreviousViewpoint( | ) |
-
Gets wether or not there is a viewpoint store before the current one.
- Returns:
- the result of the test
o Pick
| public Pick( | const | istyle, |
| const | ix, |
| const | iy, |
| const | idx, |
| const | idy, |
| | oPlist, |
| | irepp | = NULL, |
| const | ipolygon | = NULL, |
| const | inb_point | = 0, |
| const | ipick_style | = 0) |
-
Generates a CATPickPathList corresponding to all representations laying under
the given position.
- Parameters:
-
- istyle
- A CATPickingStyle specifying the way the
CATPickPathList is generated
- ix
- The x coordinate of the position at wich we want to pick
- iy
- The y coordinate of the position at wich we want to pick
- idx
- The width in pixel
- idy
- The height in pixel
- oPlist
- The CATPickPathList generated
- irepp
- The CATRepPath we want to pick on. If this parameter is NULL, we pick on all representations
- ipolygon
- If the CATPickingStyle is CATPickingInsidePolygon, define the polygon used for the picking
- inb_point
- If the CATPickingStyle is CATPickingInsidePolygon, define the number of points in the polygon
- ipick_style
- The
CATViewModeType used to do the picking
o Pick
| public Pick( | const | istyle, |
| const | iorg, |
| const | idir, |
| const | ineard, |
| const | ifard, |
| const | idx, |
| const | idy, |
| | oPlist, |
| | irepp | = NULL, |
| const | ipick_style | = 0) |
-
Generates a CATPickPathList corresponding to all representations laying under
the given position.
- Parameters:
-
- istyle
- A CATPickingStyle specifying the way the
CATPickPathList is generated
- iorg
- The Point from wich we pick
- idir
- The direction into wich we pick
- ineard
- The distance from iorg at wich we begin to pick
- ifard
- The distance from iorg at wich we stop to pick
- oPlist
- The
CATPickPathList generated
- irepp
- The
CATRepPath we want to pick on. If this parameter is NULL, we pick on all representations
- ipick_style
- The
CATViewModeType used to do the picking
o Reframe
-
Changes the Main Viewpoint to have all the repreentations visible on screen.
o RemoveManipulatorToActive
| public RemoveManipulatorToActive( | ) |
-
Removes the CATManipulator to be activated.
o RemoveRepFurtive
| public virtual RemoveRepFurtive( | | iRep) |
-
Removes a 2D furtive representation from Main 2D Viewpoint .
- Parameters:
-
- iRep
- the
CAT2DRep to remove
o RemoveRepFurtive
| public virtual RemoveRepFurtive( | | iRep) |
-
Removes a 3D furtive representation from main 3D Viewpoint.
- Parameters:
-
- iRep
- The 3D Rep to remove
o RemoveRep
| public virtual RemoveRep( | | iRep) |
-
Removes a representation 2D from the main CAT2DViewpoint.
The representation will disappear at the next
CATViewer.Draw
- Parameters:
-
- iRep
- the
CAT2DRep to remove
o RemoveRep
| public virtual RemoveRep( | | iRep) |
-
Removes a representation 3D from the main CAT3DViewpoint.
The representation will appears at he next
CATViewer.Draw Use this method in the process of removing many representations
- Parameters:
-
- iRep
- The 3D rep to remove
o RemoveRepsFurtive
| public virtual RemoveRepsFurtive( | | iRep) |
-
Removes a furtive representation from the Main 2D Viewpoint.
Role:The representation will disappear at the next
CATViewer.Draw. Use this method in the process of removing many representations.
o RemoveRepsFurtive
| public virtual RemoveRepsFurtive( | | iRep) |
-
Removes a furtive representation from the main 3D Viewpoint.
The representation will disappear at the next
CATViewer.Draw Use this method in the process of removing many representations
- Parameters:
-
- iRep
- The 3D Rep to remove
o RemoveReps
| public virtual RemoveReps( | | iRep) |
-
Removes a representation 2D from the main CAT2DViewpoint.
The representation will appears at the next
CATViewer.Draw Use this method in the process of removing many representations
- Parameters:
-
- iRep
- the
CAT2DRep to remove
o RemoveReps
| public virtual RemoveReps( | | iRep) |
-
Removes a representation 3D from the Main CAT3DViewpoint to be visualized.
The representation will appears at he next CATViewer::Draw
- Parameters:
-
- iRep
- the 3D Rep to remove
o RemoveViewpoint
| public RemoveViewpoint( | | iViewpoint) |
-
Removes the viewpoint from the viewer's list.
- Parameters:
-
- iViewpoint
-
CATViewpoint to remove
o Resize
| public Resize( | const | iWidth, |
| const | iHeight) |
-
Resize the viewer.
- Parameters:
-
- iWidth
- the new width in pixel for the viewer.
- iHeight
- the new width in pixel for the viewer.
o SaveViewpoint
| public virtual SaveViewpoint( | ) |
-
Stores the Current MainViewpoint so that it can be restored later.
o SetBackgroundColor
| public virtual SetBackgroundColor( | const | iR, |
| const | iG, |
| const | iB, |
| const | save | =1) |
-
Sets the background color.
- Parameters:
-
- iR
- the red composant color.
- iG
- the green composant color.
- iB
- the blue composant color.
o SetCursor
| public SetCursor( | | iCursor) |
-
Sets the cursor displayed when the mouse is over the viewer.
- Parameters:
-
- iCursor
o SetFeedbackMode
| public SetFeedbackMode( | const | iOnOff | =FALSE) |
-
Sets the feedback mode.
- Parameters:
-
- iOnOff
- The feedback mode.
Legal values:
- FALSE= Off (default value), no feedback
- TRUE= On , a
CATVisViewerFeedbackEvent is sent when something appends in the viewer.
o SetFullScreen
| public virtual SetFullScreen( | const | iOnOff | =1) |
-
Sets the viewer's FullScreen state.
- Parameters:
-
- iOnOff
- the FullScreen mode
o SetGlobalAmbientLight
| public SetGlobalAmbientLight( | const | iR, |
| const | iG, |
| const | iB) |
-
Sets the global ambient light color.
- Parameters:
-
- iR
- the red composant color.
- iG
- the green composant color.
- iB
- the blue composant color.
o SetGraduatedBackground
| public virtual SetGraduatedBackground( | const | iActive) |
-
Sets whether or not the background is graduated.
- Parameters:
-
- iActive
- 0 = off.
1 = on.
o SetIndicator
| public SetIndicator( | | iIndic, |
| const | iPlace) |
-
Sets the current indicator. The Background and foreground indicator are
two uniques indicators. When you set the indicators, YOU MUST SAVE the
previous one to put yours. Then at the end of your use, you connect back
the saved one.
- Parameters:
-
- iIndic
- the
CATIndicator
- iPlace
- Placement Background or Foregroung
- Returns:
- Previous Current indicator to save.
o SetLightSourceReps
| public SetLightSourceReps( | | lightRep1, |
| | lightRep2) |
-
Sets the two CAT3DLightSourceRep associated to the viewer.
- Parameters:
-
- lightRep1
- the first light source
- lightRep2
- the second light source
o SetMainViewpoint
| public virtual SetMainViewpoint( | | viewpoint) |
-
Sets the main viewpoint of the viewer.
- Parameters:
-
- viewpoint
- the viewpoint that is to be manipulated by local transformations
o SetManipulatorToActive
| public SetManipulatorToActive( | | iManip) |
-
Sets the CATManipulator to activate on next mouse interaction.
- Parameters:
-
- iManip
- the
CATManipulator to activate
o SetViewMode
| public SetViewMode( | const | iMode, |
| const | iActive) |
-
Sets the viewmode for viewer enclosed in the current CATSupport.
- Parameters:
-
- iMode
- The viewer mode
Legal values:
CATViewModeType
- iActive
- 0 = off.
1 = on.
o UndrawElement
| public virtual UndrawElement( | | iPath) |
-
Undraws a CATRepPath if it is Furtive .
- Parameters:
-
- iPath
- the
CATRepPath to undraw
o UndrawElements
| public virtual UndrawElements( | | iPaths) |
-
Undraws a list of CATRepPath if they are Furtive .
- Parameters:
-
- iPaths
- the list of
CATRepPath to undraw
o ViewMode
| public ViewMode( | const | iMode) |
-
Returns whether or not the given mode is active.
- Parameters:
-
- iMode
- the viewer mode.
Legal values:
CATViewModeType
This object is included in the file: CATViewer.h
If needed, your Imakefile.mk should include the module: CATVisualization