AcisSLInterface
List of: Classes
Subjects: Skinning and Lofting
Contents: Advanced Surfacing

Purpose: Abstract base class that defines the skinning and lofting interfaces.

Derivation: AcisSLInterface : ACIS_OBJECT : -

Filename: skin/skin/sg_husk/skin/sur_intr.hxx

Description: Both the skinning and lofting operations use a common interface defined by this class, and consist of ten identical steps.


This class cannot be instantiated because it contains pure virtual methods which define the skinning and lofting interfaces. These methods are actually implemented in the AcisLoftingInterface and AcisSkinningInterface classes. The AcisSLInterface class also contains non virtual methods which implement functionality identical to both the skinning and lofting interfaces.

References: BASE position, SPAunit_vector

KERN BODY

Data: protected BODY* m_body;

Points to the BODY returned.


protected logical m_closed;

Stores the closed option setting.


protected BODY** m_wireList;

Points to a temporary list of wires used during skinning and lofting.


protected int m_numberOfWires;

Number of wires in the list.


protected logical * m_fixedWireList;

List of logicals that maintain which wires are fixed during the minimize twist step for skinning or lofting.


protected logical m_align;

Stores the align option setting.


protected logical m_allClosed;

TRUE if all the wire profiles are closed.


protected logical m_arcLength;

Stores the arc length option setting.


protected logical m_degenerate;

TRUE if any of the wire profiles is a degenerate point (zero length wire.)


protected logical m_haveAligned;

TRUE if wires have been aligned.


protected logical m_haveBrokenUp;

TRUE if the wires been broken up.


protected logical m_haveUnTwisted;

TRUE if the wires have been untwisted.


protected logical m_periodic;

Stores the periodic option setting.


protected logical m_solid;

Stores the solid option setting.


protected logical m_noTwist;

Stores the twist option setting.


protected logical m_simplify;

Stores the simplify option setting.


protected Mcurve_data* mcurve_data;

Stores mapping curve data.


protected logical m_haveStoredDefaultUntwist;

Whether or not the default untwist is stored.


protected SPAposition* m_defaultUntwist;

Stores the original untwisted state of the wires, prior to any mapping curves.


protected logical m_end_degenerate;

Whether end point is degenerate.


protected logical m_start_degenerate;

Whether start point is degenerate.


protected SPAposition m_end_point;

End point.


protected SPAposition m_start_point;

Start point.


protected AcisVersion m_version;

The version tag.

Constructor: public: AcisSLInterface::AcisSLInterface ();


C++ allocation constructor requests memory for this object but does not populate it.






public: AcisSLInterface::AcisSLInterface (


skin_options* opts // skin options


);


Creates an AcisSLInterface object and initializes its option settings.




Destructor: public: virtual AcisSLInterface::~AcisSLInterface ();


C++ destructor for AcisSLInterface which deallocates memory.



Methods: public: virtual outcome


AcisSLInterface::addGuide (


EDGE* guide // guide


);


Adds a guide to the Interface. The curve underlying the guide must be c1 continuous and non-looping. In addition, the guide must touch each wire profile within SPAresabs and start and stop exactly on the first and last profiles. Direction is not important. The guides can intersect the section profiles on or off vertices. If the guide does not lie on any vertices no surface edge is created. If the guide intersects the first profile off a vertex but intersects any other profile on a vertex, a surface edge is made. In addition to accepting guides the overloaded API supporting guide curves takes the logical flag "VirtualGuides". This flag toggles the guides from being local surface control to global surface control. For example, in the case of local surface control, the guide curve only affects the surface created from the edges of the wire that the guide intersects. In the case of "VirtualGuides" being TRUE, the guide affects all the surfaces made from the wire body cross sections.






public: virtual outcome


AcisSLInterface::addGuide (


COEDGE* guide // guide


);


Adds a guide to the Interface. The curve underlying the guide must be c1 continuous and non-looping. In addition, the guide must touch each wire profile within SPAresabs and start and stop exactly on the first and last profiles. Direction is not important. The guides can intersect the section profiles on or off vertices. If the guide does not lie on any vertices no surface edge is created. If the guide intersects the first profile off a vertex but intersects any other profile on a vertex, a surface edge is made. In addition to accepting guides the overloaded API supporting guide curves takes the logical flag "VirtualGuides". This flag toggles the guides from being local surface control to global surface control. For example, in the case of local surface control, the guide curve only affects the surface created from the edges of the wire that the guide intersects. In the case of "VirtualGuides" being TRUE, the guide affects all the surfaces made from the wire body cross sections.






public: virtual logical


AcisSLInterface::addMappingCurves (


int num, // number of curves


SPAposition* pts // list of points


);


Adds mapping curves. Profiles must be closed.






protected: virtual logical


AcisSLInterface::addMappingCurvesInternal (


int num, // number of curves


SPAposition* pts, // list of points


logical guides_used // flag for using



= FALSE // guide curves


);


Adds internal mapping curves. Profiles must be closed. This should be called internally only.






public: virtual outcome AcisSLInterface::addVertex (


COEDGE* coedge, // coedge to add vertex




// to middle of


WIRE* wire // wire to add vertex on


)= 0;


Adds a vertex to the middle of the specified coedge and to each of the corresponding coedges in the wire list.






public: virtual outcome AcisSLInterface::alignWires (


int start = 0 // Index of starting wire


int end = 0 // Index of ending wire


)= 0;


Aligns the directions of the wires in the skinning or lofting profiles.






public: virtual outcome


AcisSLInterface::breakupWires (


int start = 0 // Index of starting wire


int end = 0 // Index of ending wire


)= 0;


Creates an equal number of coedges in each wire of the skinning or lofting profiles. This is required to create the surfaces.






public: virtual outcome AcisSLInterface::buildEdges (


ENTITY_LIST& edge_list // list of created edges


)= 0;


Builds a list of edges that represent the extents of the surfaces if the wires were to be skinned at the present configuration. This function is intended to be used as a preview of the potential lofting body that will be created. The application developer may delete this list of edges at any time, allow the end user to move the vertices of a lofting or skinning wire and recreate the edges.






public: virtual outcome AcisSLInterface::buildFaces (


ENTITY_LIST& face_list // list of created faces


)= 0;


Builds a list of faces.






protected: logical


AcisSLInterface::checkMappingCurve (


int num, // number of positions


SPAposition* pos // list of positions


);


Determines if the mapping curve intersects another mapping curve.






public: virtual outcome


AcisSLInterface::clearGuides ();


Removes all guides from the interface.






public: outcome


AcisSLInterface::clearMappingCurves ();


Removes all mapping curves.






public: virtual outcome


AcisSLInterface::collapseWires (


ENTITY_LIST& wire_list // list of modified wires


)= 0;


Deletes a degenerate coedge in each wire of a list of wires. It will remove a degenerate coedge in each wire of a list of wires. In order for the coedges to be removed, each wire in the list must contain a degenerate coedge at the same position. That is, if the fifth coedge of wire one is degenerate, it and the other coedges will only be removed if the fifth coedge of every other wire is degenerate as well.






public: virtual outcome AcisSLInterface::createBody (


BODY*& body // created body


)= 0;


Builds the sheet body from the data in the skinning or lofting interface.






protected: logical


AcisSLInterface::doesMappingCurveExist (


int num, // number of positions


SPAposition* pts // list of positions


);


Determines if a mapping curve already exists.






public: virtual outcome


AcisSLInterface::estimateMinRadOfCurvature (


double& min_rad // returned minimum




// radius of curvature


)= 0;


Estimates the minimum radius of curvature of skin surfaces that is mathematically possible.






public: BODY* AcisSLInterface::getBody ();


Returns a pointer to the skinned or lofted body.






public: virtual curve*


AcisSLInterface::getGuideAt (


int
// index


) const;


The guides that have been added to the Interface are stored in an array. This function returns the guide that belongs to the provided index.






public: virtual outcome


AcisSLInterface::getGuides (


int& num,
// number of guides


curve**& guides
// guides


);


Get the guides from the interface.






public: logical AcisSLInterface::getMappingCurve (


int num,
// index into list of





// list of mapping





// curves


SPAposition*& pos_list
// returned list of



= *(SPAposition**)NULL_REF// positions


);


Returns a list of positions for the specified mapping curve.






public: logical AcisSLInterface::getMappingCurve (


int num, // index into list of




// mapping curves


curve*& curve // returned curve




// approximation of




// mapping curve


);


Returns a B-spline approximation of the ith mapping curve.






public: int


AcisSLInterface::getNumberOfGuides () const;


Returns the number of guides in the interface.






public: int AcisSLInterface::getNumberOfWires ();


Returns the number of wires in the temporary set of wires used for skinning or lofting.






public: virtual law**


AcisSLInterface::getProfileLaw (


int index // index


)= 0;


Returns the profile law.






public: virtual WIRE* AcisSLInterface::getWireAt (


int index
// index


);


Gets a pointer to the wire at the given index in the list of temporary wires.






public: BODY** AcisSLInterface::getWireList ();


Returns a pointer to the temporary set of wires that are used during the skinning or lofting operation. This method is identical in both the skinning and lofting interfaces.






public:virtual Loft_Connected_Coedge_List*


AcisSLInterface::get_internalCoedgeList ()= 0;


Returns the list of internal coedges.






public: virtual char*


AcisSLInterface::interfaceType ()= 0;


Returns the type of interface the object was instantiated as.






public: virtual outcome AcisSLInterface::makeWires (


BODY**& wire_list // list of wires


)= 0;


Creates a set of wires that are broken-up according to the skinning and lofting breakup algorithm. (The original wires or coedges that were sent in for input still exist.) It is this list of broken up wires that will be used in the skinning or lofting algorithm.






public: virtual outcome


AcisSLInterface::minimizeTwist (


int
// index of starting



start = 0, // profile to be aligned


int
// index of ending



end = 0 // profile to be aligned


)= 0;


Performs an alignment of the start vertices of the wires in the skinning/lofting profiles. This allows a surface of minimum twist to be built.






public: virtual outcome AcisSLInterface::modifyWire (


COEDGE*coedge1, // coedge to left




// of position


COEDGE* coedge2, // coedge to right




// of position


SPAposition pos, // position to adjust




// vertex to


WIRE* wire // wire this belongs to


)= 0;


This function modifies the position of a vertex on a coedge of a wire. It is used to alter the coedges of a wire of the skinning process so the end-user may control the body generated.






public: logical


AcisSLInterface::removeMappingCurve (


int index // index


);


Removes the specified mapping curve.






public: virtual outcome


AcisSLInterface::removeVertex (


WIRE* // wire list to remove



wire, // vertex from


SPAposition // position of vertex



pos // to be removed


)= 0;


Removes the specified vertex from the its coedge and a vertex from each of the corresponding coedges in each wire in the wire list.






public: outcome AcisSLInterface::setOptions (


logical arclen, // arclength option


logical no_twist, // no twist option


logica al ign_opt, // align option


logical simpl_opt // simplify option


);


Sets the value of each skinning/lofting option.






public: virtual outcome


AcisSLInterface::setStartVertex (


int index, // index of wire which




// contains the vertex


VERTEX* vertex // becomes new starting




// vertex


);


Sets the given vertex to be the starting vertex for the operation. Additionally, it sets the given wire to be fixed, meaning it is skipped over during the minimize twist operation.






public: virtual outcome


AcisSLInterface::setStartVertex (


WIRE* wire, // wire that contains




// the vertex


VERTEX* vertex // becomes new starting




// vertex


);


Sets the given vertex to be the starting vertex for the operation. Additionally, it sets the given wire to be fixed, meaning it is skipped over during the minimize twist operation.






public: virtual outcome


AcisSLInterface::setWireFixed (


int index // index of wire


);


Sets the wire given by the index to be fixed, meaning it is skipped over during the minimize twist operation.






public: virtual outcome


AcisSLInterface::setWireUnFixed (


int index // index of wire


);


Sets the given wire to be fixed, meaning it is skipped over during the minimize twist operation.






public: virtual outcome


AcisSLInterface::simplifyWires ();


Simplify the wire geometry.






public: virtual outcome


AcisSLInterface::validStartVertices (


WIRE* wire, // wire


ENTITY_LIST& vertex_list // vertices lying on




// the convex hull


);


Any vertex used as the starting vertex must lie on the convex hull. This method returns a list of vertices lying on the convex hull.






protected: int AcisSLInterface::vertexIndex (


SPAposition* pos, // position


WIRE* wire // wire


);


Given a position and a wire, determines the coedge number of that position on the wire.






protected: int AcisSLInterface::vertexIndex (


VERTEX* vertex, // vertex


WIRE* wire // wire


);


Given a vertex and a position, determines the number of the coedge begun at that vertex on the wire.

Internal Use: makeSurface
PDF/SKIN/06CL.PDF
HTM/DATA/SKIN/SKIN/06CL/0003.HTM