OCC Main Page | Visualization | Toolkits | Packages | Class Hierarchy | Data Structures | File List | Data Fields | Globals

Visualization
TKV3d
AIS


AIS Class Reference

Application Interactive Services provide the means to
create links between an application GUI viewer and
the packages which are used to manage selection
and presentation. The tools AIS defined in order to
do this include different sorts of entities: both the
selectable viewable objects themselves and the
context and attribute managers to define their
selection and display.
To orient the user as he works in a modeling
environment, views and selections must be
comprehensible. There must be several different sorts
of selectable and viewable object defined. These must
also be interactive, that is, connecting graphic
representation and the underlying reference
geometry. These entities are called Interactive
Objects, and are divided into four types:
- the Datum
- the Relation
- the Object
- None.
The Datum groups together the construction elements
such as lines, circles, points, trihedra, plane trihedra,
planes and axes.
The Relation is made up of constraints on one or
more interactive shapes and the corresponding
reference geometry. For example, you might want to
constrain two edges in a parallel relation. This
contraint is considered as an object in its own right,
and is shown as a sensitive primitive. This takes the
graphic form of a perpendicular arrow marked with
the || symbol and lying between the two edges.
The Object type includes topological shapes, and
connections between shapes.
None, in order not to eliminate the object, tells the
application to look further until it finds an object
definition in its generation which is accepted.
Inside these categories, you have the possibility
of an additional characterization by means of a
signature. The signature provides an index to the
further characterization. By default, the Interactive
Object has a None type and a signature of 0
(equivalent to None.) If you want to give a particular
type and signature to your interactive object, you must
redefine the two virtual methods: Type and Signature.
In the C++ inheritance structure of the package, each
class representing a specific Interactive Object
inherits AIS_InteractiveObject. Among these
inheriting classes, AIS_Relation functions as the
abstract mother class for tinheriting classes defining
display of specific relational constraints and types of
dimension. Some of these include:
- display of constraints based on relations of
symmetry, tangency, parallelism and concentricity
- display of dimensions for angles, offsets,
diameters, radii and chamfers.
No viewer can show everything at once with any
coherence or clarity. Views must be managed
carefully both sequentially and at any given instant.
Another function of the view is that of a context to
carry out design in. The design changes are applied
to the objects in the view and then extended to the
underlying reference geometry by a solver. To make
sense of this complicated visual data, several display
and selection tools are required. To facilitate
management, each object and each construction
element has a selection priority. There are also
means to modify the default priority.
To define an environment of dynamic detection, you
can use standard filter classes or create your own. A
filter questions the owner of the sensitive primitive in
local context to determine if it has the the desired
qualities. If it answers positively, it is kept. If not, it is rejected.
The standard filters supplied in AIS include:
AIS_AttributeFilter
AIS_SignatureFilter
AIS_TypeFilter.
Only the type filter can be used in the default
operating mode, the neutral point. The others can
only be used in open local contexts.
Neutral point and local context constitute the two
operating modes of the central entity which pilots
visualizations and selections, the Interactive Context.
It is linked to a main viewer and if you like, a trash bin
viewer as well.
The neutral point, which is the default mode, allows
you to easily visualize and select interactive objects
which have been loaded into the context. Opening
local contexts allows you to prepare and use a
temporary selection environment without disturbing
the neutral point. A set of functions allows you to
choose the interactive objects which you want to act
on, the selection modes which you want to activate,
and the temporary visualizations which you will
execute. When the operation is finished, you close the
current local context and return to the state in which
you were before opening it (neutral point or previous
local context).
An interactive object can have a certain number of
graphic attributes which are specific to it, such as
visualization mode, color, and material. By the same
token, the interactive context has a set of graphic
attributes, the Drawer which is valid by default for the
objects it controls. When an interactive object is
visualized, the required graphic attributes are first
taken from the object's own Drawer if one exists, or
from the context drawer for the others.
.

#include <AIS.hxx>


Public Member Functions

void * operator new (size_t, void *anAddress)
void * operator new (size_t size)
void operator delete (void *anAddress)

Static Public Member Functions

static Standard_EXPORT gp_Pnt Nearest (const TopoDS_Shape &aShape, const gp_Pnt &aPoint)
 Returns the nearest point in a shape. This is used by
several classes in calculation of dimensions.
.
static Standard_EXPORT gp_Pnt Farest (const TopoDS_Shape &aShape, const gp_Pnt &aPoint)
static Standard_EXPORT Standard_Boolean ComputeGeometry (const TopoDS_Edge &anEdge, Handle(Geom_Curve)&aCurve, gp_Pnt &FirstPnt, gp_Pnt &LastPnt)
static Standard_EXPORT Standard_Boolean ComputeGeometry (const TopoDS_Edge &anEdge, Handle(Geom_Curve)&aCurve, gp_Pnt &FirstPnt, gp_Pnt &LastPnt, Handle(Geom_Curve)&extCurve, Standard_Boolean &isinfinite, Standard_Boolean &isOnPlane, const Handle(Geom_Plane)&aPlane)
static Standard_EXPORT Standard_Boolean ComputeGeometry (const TopoDS_Edge &anEdge1, const TopoDS_Edge &anEdge2, Handle(Geom_Curve)&aCurve1, Handle(Geom_Curve)&aCurve2, gp_Pnt &FirstPnt1, gp_Pnt &LastPnt1, gp_Pnt &FirstPnt2, gp_Pnt &LastPnt2, const Handle(Geom_Plane)&aPlane)
static Standard_EXPORT Standard_Boolean ComputeGeometry (const TopoDS_Edge &anEdge1, const TopoDS_Edge &anEdge2, Standard_Integer &indexExt, Handle(Geom_Curve)&aCurve1, Handle(Geom_Curve)&aCurve2, gp_Pnt &FirstPnt1, gp_Pnt &LastPnt1, gp_Pnt &FirstPnt2, gp_Pnt &LastPnt2, Handle(Geom_Curve)&ExtCurve, Standard_Boolean &isinfinite1, Standard_Boolean &isinfinite2, const Handle(Geom_Plane)&aPlane)
static Standard_EXPORT Standard_Boolean ComputeGeomCurve (Handle(Geom_Curve)&aCurve, const Standard_Real first1, const Standard_Real last1, gp_Pnt &FirstPnt1, gp_Pnt &LastPnt1, const Handle(Geom_Plane)&aPlane, Standard_Boolean &isOnPlane)
static Standard_EXPORT Standard_Boolean ComputeGeometry (const TopoDS_Vertex &aVertex, gp_Pnt &point, const Handle(Geom_Plane)&aPlane, Standard_Boolean &isOnPlane)
static Standard_EXPORT Standard_Boolean GetPlaneFromFace (const TopoDS_Face &aFace, gp_Pln &aPlane, Handle(Geom_Surface)&aSurf, AIS_KindOfSurface &aSurfType, Standard_Real &Offset)
 Tryes to get Plane from Face. Returns Surface of Face
in aSurf. Returns Standard_True and Plane of Face in
aPlane in following cases:
Face is Plane, Offset of Plane,
Extrusion of Line and Offset of Extrusion of Line
Returns pure type of Surface which can be:
Plane, Cylinder, Cone, Sphere, Torus,
SurfaceOfRevolution, SurfaceOfExtrusion
.
static Standard_EXPORT void InitFaceLength (const TopoDS_Face &aFace, gp_Pln &aPlane, Handle(Geom_Surface)&aSurface, AIS_KindOfSurface &aSurfaceType, Standard_Real &anOffset)
static Standard_EXPORT void ComputeLengthBetweenPlanarFaces (const TopoDS_Face &FirstFace, const TopoDS_Face &SecondFace, const gp_Pln &Plane1, const gp_Pln &Plane2, Standard_Real &Value, gp_Pnt &FirstAttach, gp_Pnt &SecondAttach, gp_Dir &DirAttach, const Standard_Boolean AutomaticPos, gp_Pnt &Position)
static Standard_EXPORT void ComputeLengthBetweenCurvilinearFaces (const TopoDS_Face &FirstFace, const TopoDS_Face &SecondFace, Handle(Geom_Surface)&FirstSurf, Handle(Geom_Surface)&SecondSurf, const Standard_Boolean AutomaticPos, Standard_Real &Value, gp_Pnt &Position, gp_Pnt &FirstAttach, gp_Pnt &SecondAttach, gp_Dir &DirAttach)
static Standard_EXPORT void ComputeAngleBetweenPlanarFaces (const TopoDS_Face &FirstFace, const TopoDS_Face &SecondFace, const Handle(Geom_Surface)&Surf2, const gp_Ax1 &Axis, const Standard_Real Value, const Standard_Boolean AutomaticPos, gp_Pnt &Position, gp_Pnt &Center, gp_Pnt &FirstAttach, gp_Pnt &SecondAttach, gp_Dir &FirstDir, gp_Dir &SecondDir)
 Computes geometric parameters for planar faces for
Angular dimensions
.
static Standard_EXPORT void ComputeAngleBetweenCurvilinearFaces (const TopoDS_Face &FirstFace, const TopoDS_Face &SecondFace, const Handle(Geom_Surface)&FirstSurf, const Handle(Geom_Surface)&SecondSurf, const AIS_KindOfSurface FirstSurfType, const AIS_KindOfSurface SecondSurfType, const gp_Ax1 &Axis, const Standard_Real Value, const Standard_Boolean AutomaticPos, gp_Pnt &Position, gp_Pnt &Center, gp_Pnt &FirstAttach, gp_Pnt &SecondAttach, gp_Dir &FirstDir, gp_Dir &SecondDir, Handle(Geom_Plane)&Plane)
 Computes geometric parameters for curvilinear faces for
Angular dimensions
.
static Standard_EXPORT gp_Pnt ProjectPointOnPlane (const gp_Pnt &aPoint, const gp_Pln &aPlane)
static Standard_EXPORT gp_Pnt ProjectPointOnLine (const gp_Pnt &aPoint, const gp_Lin &aLine)
static Standard_EXPORT gp_Pnt TranslatePointToBound (const gp_Pnt &aPoint, const gp_Dir &aDir, const Bnd_Box &aBndBox)
static Standard_EXPORT Standard_Boolean InDomain (const Standard_Real aFirstPar, const Standard_Real aLastPar, const Standard_Real anAttachPar)
 returns True if point with anAttachPar is
in domain of arc

static Standard_EXPORT gp_Pnt NearestApex (const gp_Elips &elips, const gp_Pnt &pApex, const gp_Pnt &nApex, const Standard_Real fpara, const Standard_Real lpara, Standard_Boolean &IsInDomain)
 computes nearest to ellipse arc apex

static Standard_EXPORT Standard_Real DistanceFromApex (const gp_Elips &elips, const gp_Pnt &Apex, const Standard_Real par)
 computes length of ellipse arc in parametric units

static Standard_EXPORT void ComputeProjEdgePresentation (const Handle(Prs3d_Presentation)&aPres, const Handle(AIS_Drawer)&aDrawer, const TopoDS_Edge &anEdge, const Handle(Geom_Curve)&ProjCurve, const gp_Pnt &FirstP, const gp_Pnt &LastP, const Quantity_NameOfColor aColor=Quantity_NOC_PURPLE, const Standard_Real aWidth=2, const Aspect_TypeOfLine aProjTOL=Aspect_TOL_DASH, const Aspect_TypeOfLine aCallTOL=Aspect_TOL_DOT)
static Standard_EXPORT void ComputeProjVertexPresentation (const Handle(Prs3d_Presentation)&aPres, const Handle(AIS_Drawer)&aDrawer, const TopoDS_Vertex &aVertex, const gp_Pnt &ProjPoint, const Quantity_NameOfColor aColor=Quantity_NOC_PURPLE, const Standard_Real aWidth=2, const Aspect_TypeOfMarker aProjTOM=Aspect_TOM_PLUS, const Aspect_TypeOfLine aCallTOL=Aspect_TOL_DOT)


Member Function Documentation

static Standard_EXPORT void AIS::ComputeAngleBetweenCurvilinearFaces const TopoDS_Face &  FirstFace,
const TopoDS_Face &  SecondFace,
const Handle(Geom_Surface)&  FirstSurf,
const Handle(Geom_Surface)&  SecondSurf,
const AIS_KindOfSurface  FirstSurfType,
const AIS_KindOfSurface  SecondSurfType,
const gp_Ax1 &  Axis,
const Standard_Real  Value,
const Standard_Boolean  AutomaticPos,
gp_Pnt &  Position,
gp_Pnt &  Center,
gp_Pnt &  FirstAttach,
gp_Pnt &  SecondAttach,
gp_Dir &  FirstDir,
gp_Dir &  SecondDir,
Handle(Geom_Plane)&  Plane
[static]
 

static Standard_EXPORT void AIS::ComputeAngleBetweenPlanarFaces const TopoDS_Face &  FirstFace,
const TopoDS_Face &  SecondFace,
const Handle(Geom_Surface)&  Surf2,
const gp_Ax1 &  Axis,
const Standard_Real  Value,
const Standard_Boolean  AutomaticPos,
gp_Pnt &  Position,
gp_Pnt &  Center,
gp_Pnt &  FirstAttach,
gp_Pnt &  SecondAttach,
gp_Dir &  FirstDir,
gp_Dir &  SecondDir
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeomCurve Handle(Geom_Curve)&  aCurve,
const Standard_Real  first1,
const Standard_Real  last1,
gp_Pnt &  FirstPnt1,
gp_Pnt &  LastPnt1,
const Handle(Geom_Plane)&  aPlane,
Standard_Boolean &  isOnPlane
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeometry const TopoDS_Vertex &  aVertex,
gp_Pnt &  point,
const Handle(Geom_Plane)&  aPlane,
Standard_Boolean &  isOnPlane
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeometry const TopoDS_Edge &  anEdge1,
const TopoDS_Edge &  anEdge2,
Standard_Integer &  indexExt,
Handle(Geom_Curve)&  aCurve1,
Handle(Geom_Curve)&  aCurve2,
gp_Pnt &  FirstPnt1,
gp_Pnt &  LastPnt1,
gp_Pnt &  FirstPnt2,
gp_Pnt &  LastPnt2,
Handle(Geom_Curve)&  ExtCurve,
Standard_Boolean &  isinfinite1,
Standard_Boolean &  isinfinite2,
const Handle(Geom_Plane)&  aPlane
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeometry const TopoDS_Edge &  anEdge1,
const TopoDS_Edge &  anEdge2,
Handle(Geom_Curve)&  aCurve1,
Handle(Geom_Curve)&  aCurve2,
gp_Pnt &  FirstPnt1,
gp_Pnt &  LastPnt1,
gp_Pnt &  FirstPnt2,
gp_Pnt &  LastPnt2,
const Handle(Geom_Plane)&  aPlane
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeometry const TopoDS_Edge &  anEdge,
Handle(Geom_Curve)&  aCurve,
gp_Pnt &  FirstPnt,
gp_Pnt &  LastPnt,
Handle(Geom_Curve)&  extCurve,
Standard_Boolean &  isinfinite,
Standard_Boolean &  isOnPlane,
const Handle(Geom_Plane)&  aPlane
[static]
 

static Standard_EXPORT Standard_Boolean AIS::ComputeGeometry const TopoDS_Edge &  anEdge,
Handle(Geom_Curve)&  aCurve,
gp_Pnt &  FirstPnt,
gp_Pnt &  LastPnt
[static]
 

static Standard_EXPORT void AIS::ComputeLengthBetweenCurvilinearFaces const TopoDS_Face &  FirstFace,
const TopoDS_Face &  SecondFace,
Handle(Geom_Surface)&  FirstSurf,
Handle(Geom_Surface)&  SecondSurf,
const Standard_Boolean  AutomaticPos,
Standard_Real &  Value,
gp_Pnt &  Position,
gp_Pnt &  FirstAttach,
gp_Pnt &  SecondAttach,
gp_Dir &  DirAttach
[static]
 

static Standard_EXPORT void AIS::ComputeLengthBetweenPlanarFaces const TopoDS_Face &  FirstFace,
const TopoDS_Face &  SecondFace,
const gp_Pln &  Plane1,
const gp_Pln &  Plane2,
Standard_Real &  Value,
gp_Pnt &  FirstAttach,
gp_Pnt &  SecondAttach,
gp_Dir &  DirAttach,
const Standard_Boolean  AutomaticPos,
gp_Pnt &  Position
[static]
 

static Standard_EXPORT void AIS::ComputeProjEdgePresentation const Handle(Prs3d_Presentation)&  aPres,
const Handle(AIS_Drawer)&  aDrawer,
const TopoDS_Edge &  anEdge,
const Handle(Geom_Curve)&  ProjCurve,
const gp_Pnt &  FirstP,
const gp_Pnt &  LastP,
const Quantity_NameOfColor  aColor = Quantity_NOC_PURPLE,
const Standard_Real  aWidth = 2,
const Aspect_TypeOfLine  aProjTOL = Aspect_TOL_DASH,
const Aspect_TypeOfLine  aCallTOL = Aspect_TOL_DOT
[static]
 

static Standard_EXPORT void AIS::ComputeProjVertexPresentation const Handle(Prs3d_Presentation)&  aPres,
const Handle(AIS_Drawer)&  aDrawer,
const TopoDS_Vertex &  aVertex,
const gp_Pnt &  ProjPoint,
const Quantity_NameOfColor  aColor = Quantity_NOC_PURPLE,
const Standard_Real  aWidth = 2,
const Aspect_TypeOfMarker  aProjTOM = Aspect_TOM_PLUS,
const Aspect_TypeOfLine  aCallTOL = Aspect_TOL_DOT
[static]
 

static Standard_EXPORT Standard_Real AIS::DistanceFromApex const gp_Elips &  elips,
const gp_Pnt &  Apex,
const Standard_Real  par
[static]
 

static Standard_EXPORT gp_Pnt AIS::Farest const TopoDS_Shape &  aShape,
const gp_Pnt &  aPoint
[static]
 

static Standard_EXPORT Standard_Boolean AIS::GetPlaneFromFace const TopoDS_Face &  aFace,
gp_Pln &  aPlane,
Handle(Geom_Surface)&  aSurf,
AIS_KindOfSurface aSurfType,
Standard_Real &  Offset
[static]
 

static Standard_EXPORT Standard_Boolean AIS::InDomain const Standard_Real  aFirstPar,
const Standard_Real  aLastPar,
const Standard_Real  anAttachPar
[static]
 

static Standard_EXPORT void AIS::InitFaceLength const TopoDS_Face &  aFace,
gp_Pln &  aPlane,
Handle(Geom_Surface)&  aSurface,
AIS_KindOfSurface aSurfaceType,
Standard_Real &  anOffset
[static]
 

static Standard_EXPORT gp_Pnt AIS::Nearest const TopoDS_Shape &  aShape,
const gp_Pnt &  aPoint
[static]
 

static Standard_EXPORT gp_Pnt AIS::NearestApex const gp_Elips &  elips,
const gp_Pnt &  pApex,
const gp_Pnt &  nApex,
const Standard_Real  fpara,
const Standard_Real  lpara,
Standard_Boolean &  IsInDomain
[static]
 

void AIS::operator delete void *  anAddress  )  [inline]
 

void* AIS::operator new size_t  size  )  [inline]
 

void* AIS::operator new size_t  ,
void *  anAddress
[inline]
 

static Standard_EXPORT gp_Pnt AIS::ProjectPointOnLine const gp_Pnt &  aPoint,
const gp_Lin &  aLine
[static]
 

static Standard_EXPORT gp_Pnt AIS::ProjectPointOnPlane const gp_Pnt &  aPoint,
const gp_Pln &  aPlane
[static]
 

static Standard_EXPORT gp_Pnt AIS::TranslatePointToBound const gp_Pnt &  aPoint,
const gp_Dir &  aDir,
const Bnd_Box &  aBndBox
[static]
 


The documentation for this class was generated from the following file:
Generated on Mon Aug 25 13:55:03 2008 for OpenCASCADE by  doxygen 1.4.1