SketchUp C API
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Related Functions
SUGuideLineRef Struct Reference

A guide line that has a start and end position. More...

#include <SketchUpAPI/model/guide_line.h>

Inherits SUDrawingElementRef.

Related Functions

(Note that these are not member functions.)

SUEntityRef SUGuideLineToEntity (SUGuideLineRef guide_line)
 Converts from an SUGuideLineRef to an SUEntityRef. This is essentially an upcast operation. More...
 
SUGuideLineRef SUGuideLineFromEntity (SUEntityRef entity)
 Converts from an SUEntityRef to an SUGuideLineRef. This is essentially a downcast operation so the given SUEntityRef must be convertible to an SUGuideLineRef. More...
 
SUDrawingElementRef SUGuideLineToDrawingElement (SUGuideLineRef guide_line)
 Converts from an SUGuideLineRef to an SUDrawingElementRef. This is essentially an upcast operation. More...
 
SUGuideLineRef SUGuideLineFromDrawingElement (SUDrawingElementRef drawing_elem)
 Converts from an SUDrawingElementRef to an SUGuideLineRef. This is essentially a downcast operation so the given element must be convertible to an SUGuideLineRef. More...
 
enum SUResult SUGuideLineCreateFinite (SUGuideLineRef *guide_line, const struct SUPoint3D *start, const struct SUPoint3D *end)
 Creates a finite guide line object. The guide line object must be subsequently deallocated with SUGuideLineRelease() unless it is associated with a parent object. The generated line will be a segment with start and end points. The end point can be obtained by adding the direction vector to the start point. More...
 
enum SUResult SUGuideLineCreateInfinite (SUGuideLineRef *guide_line, const struct SUPoint3D *point, const struct SUVector3D *direction)
 Creates a infinite guide line object. The guide line object must be subsequently deallocated with SUGuideLineRelease() unless it is associated with a parent object. The generated line will be infinite. Defined with a point along the line and a direction vector. More...
 
enum SUResult SUGuideLineRelease (SUGuideLineRef *guide_line)
 Releases a guide line object. The guide line object must have been created with SUGuideLineCreateFinite() or SUGuideLineCreateInfinite and not subsequently associated with a parent object (e.g. SUEntitiesRef). More...
 
enum SUResult SUGuideLineGetData (SUGuideLineRef guide_line, struct SUPoint3D *start, struct SUVector3D *direction, bool *isinfinite)
 Retrieves the data defining the line (a point, a direction vector, and a boolean flagging if the line is infinite). For finite lines start is the start point, and the end point can be obtained by adding the direction vector (direction) to the start point (start). For infinite lines start is simply a point on the guide line, and direction is always a unit vector. More...
 

Detailed Description

A guide line that has a start and end position.

Since
SketchUp 2016, API 4.0

Friends And Related Function Documentation

enum SUResult SUGuideLineCreateFinite ( SUGuideLineRef guide_line,
const struct SUPoint3D start,
const struct SUPoint3D end 
)
related

Creates a finite guide line object. The guide line object must be subsequently deallocated with SUGuideLineRelease() unless it is associated with a parent object. The generated line will be a segment with start and end points. The end point can be obtained by adding the direction vector to the start point.

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe guide line object.
[out]startThe guide line start position.
[out]endThe guide line end position.
Returns
enum SUResult SUGuideLineCreateInfinite ( SUGuideLineRef guide_line,
const struct SUPoint3D point,
const struct SUVector3D direction 
)
related

Creates a infinite guide line object. The guide line object must be subsequently deallocated with SUGuideLineRelease() unless it is associated with a parent object. The generated line will be infinite. Defined with a point along the line and a direction vector.

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe guide line object.
[out]pointA point on the guide line.
[out]directionThe guide line direction vector.
Returns
SUGuideLineRef SUGuideLineFromDrawingElement ( SUDrawingElementRef  drawing_elem)
related

Converts from an SUDrawingElementRef to an SUGuideLineRef. This is essentially a downcast operation so the given element must be convertible to an SUGuideLineRef.

Since
SketchUp 2016, API 4.0
Parameters
[in]drawing_elemThe given element reference.
Returns
  • The converted SUGuideLineRef if the downcast operation succeeds
  • If not, the returned reference will be invalid.
SUGuideLineRef SUGuideLineFromEntity ( SUEntityRef  entity)
related

Converts from an SUEntityRef to an SUGuideLineRef. This is essentially a downcast operation so the given SUEntityRef must be convertible to an SUGuideLineRef.

Since
SketchUp 2016, API 4.0
Parameters
[in]entityThe entity object.
Returns
  • The converted SUGuideLineRef if the downcast operation succeeds
  • If the downcast operation fails, the returned reference will be invalid
enum SUResult SUGuideLineGetData ( SUGuideLineRef  guide_line,
struct SUPoint3D start,
struct SUVector3D direction,
bool *  isinfinite 
)
related

Retrieves the data defining the line (a point, a direction vector, and a boolean flagging if the line is infinite). For finite lines start is the start point, and the end point can be obtained by adding the direction vector (direction) to the start point (start). For infinite lines start is simply a point on the guide line, and direction is always a unit vector.

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe guide line object.
[out]startA point on the guide line.
[out]directionThe guide line direction.
[out]isinfinitereturns true if infinite otherwise returns false
Returns
enum SUResult SUGuideLineRelease ( SUGuideLineRef guide_line)
related

Releases a guide line object. The guide line object must have been created with SUGuideLineCreateFinite() or SUGuideLineCreateInfinite and not subsequently associated with a parent object (e.g. SUEntitiesRef).

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe guide line object.
Returns
SUDrawingElementRef SUGuideLineToDrawingElement ( SUGuideLineRef  guide_line)
related

Converts from an SUGuideLineRef to an SUDrawingElementRef. This is essentially an upcast operation.

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe given guide line reference.
Returns
  • The converted SUEntityRef if guide_line is a valid guide line
  • If not, the returned reference will be invalid
SUEntityRef SUGuideLineToEntity ( SUGuideLineRef  guide_line)
related

Converts from an SUGuideLineRef to an SUEntityRef. This is essentially an upcast operation.

Since
SketchUp 2016, API 4.0
Parameters
[in]guide_lineThe guide line object.
Returns
  • The converted SUEntityRef if guide_line is a valid object
  • If not, the returned reference will be invalid

The documentation for this struct was generated from the following files: