Modules | |
Element Location Criteria | |
AutoLocate | |
Snapping | |
Functions | |
DgnPlatform::HitGeomType | mdlLocate_getHitGeomType () |
CurrentHitFuncs ( mdlLocate_getCurrPath, mdlLocate_getCurrModelRef, mdlLocate_getComponentOffset, mdlLocate_getCurrHeaderFilePos, mdlLocate_changeCurrPath, mdlLocate_changeCurrPathByElemRef, mdlLocate_getHitPoint, mdlLocate_getHitView ) CurrentHitElemFuncs ( mdlLocate_Linear_getParameters, mdlLocate_Multiline_getParameters, mdlLocate_BSpline_getParameters, mdlLocate_Dimension_getParameters, mdlLocate_getProjectedPoint ) More... | |
DisplayPathCP | mdlLocate_getCurrPath () |
Get the DisplayPathCP of the currently located element. More... | |
DgnModelRefP | mdlLocate_getCurrModelRef () |
Get the ModelRef for the Current Hit. More... | |
UInt32 | mdlLocate_getCurrHeaderFilePos () |
Get the filePos of the header of the Current Hit. More... | |
UInt32 | mdlLocate_getComponentOffset () |
Get the offset of the currently selected component of the Current Hit. More... | |
StatusInt | mdlLocate_changeCurrPath (UInt32 newFilePos, DgnModelRefP modelRef) |
Change the path of the Current Hit to a new element, using a new filePos and modelRef. More... | |
StatusInt | mdlLocate_changeCurrPathByElemRef (ElementRefP elemRef, DgnModelRefP modelRef) |
Change the path of the Current Hit to a new element, using a new elementRef/modelRef pair. More... | |
void | mdlLocate_hideElement (ElementRefP elemRef, DgnModelRefP modelRef, bool allowLocate, bool restoreHidden) |
Add an element to the list of hidden elements controlled by the Locate Process. More... | |
void | mdlLocate_hiliteElement (ElementRefP elemRef, DgnModelRefP modelRef) |
Add an element to the list of hilited elements controlled by the Locate Process. More... | |
void | mdlLocate_hilitePath (DisplayPathCP path) |
This function is equivalent to mdlLocate_hiliteElement, except that it accepts a full DgnPlatform::DisplayPath describing the element to be hilited. More... | |
void | mdlLocate_dropFromHilited (DisplayPathCP path) |
Remove a path from the list of hilited elements. More... | |
DisplayPathCP | mdlLocate_getHilitedPath (int index) |
Get the DgnPlatform::DisplayPath for one of the currently hilited elements. More... | |
StatusInt | mdlLocate_getHitPoint (DPoint3dP hitPoint) |
Get the point on the element that generated the Current Hit. More... | |
int | mdlLocate_getHitView () |
Determine which view was used to locate the Current Hit. More... | |
StatusInt | mdlLocate_Linear_getParameters (DSegment3dP segment, int *vertex, int *segmentNumber) |
Get the parameters that caused the Current Hit. More... | |
StatusInt | mdlLocate_Multiline_getParameters (DSegment3dP segPoints, int *vertex, int *segmentNumber, int *lineNumber, int *capNumber, int *patIndex) |
Get the parameters that caused the Current Hit, if it was generated from a multiline element. More... | |
StatusInt | mdlLocate_BSpline_getParameters (double *u, double *v) |
Get the parameters that caused the Current Hit, if it was generated from a bspline element. More... | |
StatusInt | mdlLocate_Dimension_getParameters (UInt32 *partName, int *pointNo, UInt32 *segment, UInt32 *partType, UInt32 *partSubType) |
Get the parameters that caused the Current Hit, if it was generated from a dimension element. More... | |
StatusInt | mdlLocate_getProjectedPoint (Dpoint3d *locatePoint, int *segment, int *view) |
Return information about the Current Hit. More... | |
StatusInt mdlLocate_BSpline_getParameters | ( | double * | u, |
double * | v | ||
) |
Get the parameters that caused the Current Hit, if it was generated from a bspline element.
[out] | u | the u parameter of the BSpline where the locate point is |
[out] | v | the v parameter of the BSpline where the locate point is |
StatusInt mdlLocate_changeCurrPath | ( | UInt32 | newFilePos, |
DgnModelRefP | modelRef | ||
) |
Change the path of the Current Hit to a new element, using a new filePos and modelRef.
[in] | newFilePos | filePos of the new element |
[in] | modelRef | specifies the model containing the new element |
StatusInt mdlLocate_changeCurrPathByElemRef | ( | ElementRefP | elemRef, |
DgnModelRefP | modelRef | ||
) |
Change the path of the Current Hit to a new element, using a new elementRef/modelRef pair.
[in] | elemRef | ElementRefP containing the new element |
[in] | modelRef | Specifies the model containing the new element |
StatusInt mdlLocate_Dimension_getParameters | ( | UInt32 * | partName, |
int * | pointNo, | ||
UInt32 * | segment, | ||
UInt32 * | partType, | ||
UInt32 * | partSubType | ||
) |
Get the parameters that caused the Current Hit, if it was generated from a dimension element.
[out] | partName | complete part identifier for part of dimension located, use ADIM_GETTYPE, ADIM_GETSUB and ADIM_GETSEG to decompose |
[out] | pointNo | closest point in dimension element to locate point |
[out] | segment | selected dimension segment index |
[out] | partType | type of the selected part of the dimension element, one of ADTYPE_xxx defined in mdldim.h. |
[out] | partSubType | sub type of the selected part of the dimension element, one of ADSUB_xxx defined in mdldim.h |
void mdlLocate_dropFromHilited | ( | DisplayPathCP | path | ) |
Remove a path from the list of hilited elements.
If any paths that match the input path will be dropped from the hilite list and will also be unhilited from the screen.
[in] | path | a DgnPlatform::DisplayPath to drop from hilite list. |
UInt32 mdlLocate_getComponentOffset | ( | ) |
Get the offset of the currently selected component of the Current Hit.
UInt32 mdlLocate_getCurrHeaderFilePos | ( | ) |
Get the filePos of the header of the Current Hit.
DgnModelRefP mdlLocate_getCurrModelRef | ( | ) |
Get the ModelRef for the Current Hit.
DisplayPathCP mdlLocate_getCurrPath | ( | ) |
Get the DisplayPathCP of the currently located element.
DisplayPathCP mdlLocate_getHilitedPath | ( | int | index | ) |
Get the DgnPlatform::DisplayPath for one of the currently hilited elements.
[in] | index | the index of the hilited element of interest. 0 means the first hilited element, -1 means the last one. |
DgnPlatform::HitGeomType mdlLocate_getHitGeomType | ( | ) |
CurrentHitFuncs ( mdlLocate_getCurrPath, mdlLocate_getCurrModelRef, mdlLocate_getComponentOffset, mdlLocate_getCurrHeaderFilePos, mdlLocate_changeCurrPath, mdlLocate_changeCurrPathByElemRef, mdlLocate_getHitPoint, mdlLocate_getHitView ) CurrentHitElemFuncs ( mdlLocate_Linear_getParameters, mdlLocate_Multiline_getParameters, mdlLocate_BSpline_getParameters, mdlLocate_Dimension_getParameters, mdlLocate_getProjectedPoint )
The MicroStation Element Location process begins by creating a Hit List containing all of the DgnPlatform::HitPaths that satisfy the Search Criteria and pass all active Locate Filters. The Hit List is sorted so that the "best" Hit is first, and each subsequent Hit is "better" than all of the Hits after it.
After the Location process completes, the first Hit in the Hit List becomes the Current Hit. The Current Hit Functions provide access to the Current Hit to interrogate the element. Certain of the Current Hit Functions extract type-specific information from the Current Hit. To determin which of these functions to use, call mdlLocate_getHitGeomType to get the element type for the Current Hit.
As the user presses the Reset button, the Current Hit is removed and the next entry in the Hit List becomes the Current Hit until there are no more Hits. Get the type of geometry that generated the Current Hit. This function can be used to determine which of the other Current Hit functions can be used to extract information from the Current Hit.
StatusInt mdlLocate_getHitPoint | ( | DPoint3dP | hitPoint | ) |
Get the point on the element that generated the Current Hit.
[out] | hitPoint | the point on the element that generated the Current Hit. |
int mdlLocate_getHitView | ( | ) |
Determine which view was used to locate the Current Hit.
StatusInt mdlLocate_getProjectedPoint | ( | Dpoint3d * | locatePoint, |
int * | segment, | ||
int * | view | ||
) |
Return information about the Current Hit.
[out] | locatePoint | is the point on the current element that is closest to the locate point. It is returned in the current coordinate system. |
[out] | segment | If the current element is a line string, shape, or curve, segment is the segment number from which locatePoint was derived. |
[out] | view | is the view number used to locate the current element. |
point, segment
, and view
are not set.) Otherwise, SUCCESS. void mdlLocate_hideElement | ( | ElementRefP | elemRef, |
DgnModelRefP | modelRef, | ||
bool | allowLocate, | ||
bool | restoreHidden | ||
) |
Add an element to the list of hidden elements controlled by the Locate Process.
All hidden elements are cleared (shown) by calling mdlLocate_clear or mdlLocate_init.
[in] | elemRef | the element ref to hide |
[in] | modelRef | the modelRef for elemRef |
[in] | allowLocate | true to allow locates/snaps to the hidden element. |
[in] | restoreHidden | true to show the hidden element again. |
void mdlLocate_hiliteElement | ( | ElementRefP | elemRef, |
DgnModelRefP | modelRef | ||
) |
Add an element to the list of hilited elements controlled by the Locate Process.
All hilited elements are cleared (unhilited) by calling mdlLocate_clear or mdlLocate_init.
[in] | elemRef | the element ref to hilite |
[in] | modelRef | the modelRef for elemRef |
void mdlLocate_hilitePath | ( | DisplayPathCP | path | ) |
This function is equivalent to mdlLocate_hiliteElement, except that it accepts a full DgnPlatform::DisplayPath describing the element to be hilited.
[in] | path | the DgnPlatform::DisplayPath to hilite. |
StatusInt mdlLocate_Linear_getParameters | ( | DSegment3dP | segment, |
int * | vertex, | ||
int * | segmentNumber | ||
) |
Get the parameters that caused the Current Hit.
if it was generated from a "linear" element.
[out] | segment | the segment of the element (in world coordinates) |
[out] | vertex | the vertex of the element that is nearest the locate point |
[out] | segmentNumber | the 0 based index of the segment number located |
StatusInt mdlLocate_Multiline_getParameters | ( | DSegment3dP | segPoints, |
int * | vertex, | ||
int * | segmentNumber, | ||
int * | lineNumber, | ||
int * | capNumber, | ||
int * | patIndex | ||
) |
Get the parameters that caused the Current Hit, if it was generated from a multiline element.
[out] | segPoints | the segment points closest to the locate point |
[out] | vertex | the multi-line vertex closest to the locate point |
[out] | segmentNumber | the 0 based index of the multi-line segment |
[out] | lineNumber | the index of the line within the multi-line |
[out] | capNumber | the index of the cap closest to the located point |
[out] | patIndex | the index of the pattern in the segment of the located point if a pattern is applied |