DialogEngine CATIndicationAgent
Usage: you must use this class as is. You should never derive it.
public class CATIndicationAgent
Class representing an agent dedicated to indication.
Role: An Indication agent is a specific acquisition agent which
retrieves a 2D point from a mouse left click.
- See also:
-
Constructor and Destructor Index
- o
CATIndicationAgent(CATString&)
- Constructs an indication agent.
- o
~CATIndicationAgent()
-
Method Index
- o
GetMathPlane()
- Returns the plane on which a point selected in a 3D viewer is projected.
- o
GetModifier()
- Returns whether the shift and control keys have been pushed during
the indication.
- o
GetValue()
- Returns the agent value.
- o
SetMathPlane(CATMathPlane&)
- Sets the plane on which to project a point selected in a 3D viewer.
- o
SetValue(CATMathPoint2D&)
- Sets the agent value.
Constructor and Destructor
o CATIndicationAgent
public CATIndicationAgent( | const | iId) |
-
Constructs an indication agent.
- Parameters:
-
- iId
- The agent identifier. It is used to retrieve the undo/redo titles in
the command resource file.
o ~CATIndicationAgent
public virtual ~CATIndicationAgent( | ) |
-
Methods
o GetMathPlane
public virtual GetMathPlane( | ) |
-
Returns the plane on which a point selected in a 3D viewer is projected.
- Returns:
- The plane.
Lifecycle rules deviation: This method doesn't AddRef the
returned value.
o GetModifier
public virtual GetModifier( | ) |
-
Returns whether the shift and control keys have been pushed during
the indication.
- Returns:
- The key use.
Legal values: Use the defined values to decode the returned
integer:
- ShiftModifierOn
- ControlModifierOn
e.g: if (Agent->GetModifier() & ControlModifierOn)
o GetValue
public virtual GetValue( | ) |
-
Returns the agent value.
Role: The value is a 2D point.
The returned value depends on the
. Indeed, if the agent valuation state is Valuated, the
GetValue method returns the real value; but if the agent
valuation state is PreValuated, the GetValue method
returns the prevalue even if the agent has got a value.
- Returns:
- The value.
Lifecycle rules deviation: This method doesn't AddRef the
returned value.
o SetMathPlane
public SetMathPlane( | const | iPlane) |
-
Sets the plane on which to project a point selected in a 3D viewer.
Role: An indication agent directly retrieves 2D point
coordinates from a click in a 2D viewer. But, with a 3D viewer,
the click is undetermined.
To determine it, this method specifies a plane on which the point
clicked on the screen plane will be projected according to the
direction. This direction corresponds to the line going from the viewpoint eye to the mouse position on screen.
If no projection plane is defined, a plane perpendicular to the
and containing the visualization origin point will be used for projection.
- Parameters:
-
- iPlane
- The plane.
Legal values: it mustn't be perpendicular to the near
or far planes, that is to the screen plane, in order to get a point.
o SetValue
public virtual SetValue( | const | iValue) |
-
Sets the agent value.
Role: The value is a 2D point.
This method does not register an undo step.
Postcondition: Use the
method to make the agent accept the value, otherwise this value is not
taken into account.
- Parameters:
-
- iValue
- The value.
This object is included in the file: CATIndicationAgent.h
If needed, your Imakefile.mk should include the module: CATDialogEngine
Copyright © 1999-2014, Dassault Systèmes. All rights reserved.