Rhino C++ API  7.21
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
ON_SectionAnalysisAppearance Class Reference

#include <opennurbs_plus_sections.h>

Public Member Functions

 ON_SectionAnalysisAppearance ()
 
double HairScale () const
 
bool operator!= (const ON_SectionAnalysisAppearance &other) const
 Compares every value except m_section_appearance_id and m_section_appearance_mark. More...
 
bool operator== (const ON_SectionAnalysisAppearance &other) const
 Compares every value except m_section_appearance_id and m_section_appearance_mark. More...
 
void SetAllColors (ON_Color color)
 
bool ShowIsoCurves () const
 

Static Public Member Functions

static double HairScaleFromUserInterfaceValue (int ui_value)
 
static int HairScaleUserInterfaceValue (double hair_scale)
 

Public Attributes

bool m_bHideIsoCurvesWhenSectionsAreVisible
 
bool m_bShowSectionCurve
 true to show the curve on the surface More...
 
bool m_bShowSectionHair
 
unsigned char m_class_version
 constructor sets m_class_version = 0; More...
 
ON_Color m_curve_color
 The color of the section curve. More...
 
double m_hair_angle_radians
 
ON_Color m_hair_color
 The sectional curvature "hair" color. More...
 
double m_hair_scale
 
double m_hair_spacing
 
ON_UUID m_section_appearance_id
 
ON__UINT64 m_section_appearance_mark
 

Static Public Attributes

static const ON_SectionAnalysisAppearance Default
 

Constructor & Destructor Documentation

◆ ON_SectionAnalysisAppearance()

ON_SectionAnalysisAppearance::ON_SectionAnalysisAppearance ( )

Member Function Documentation

◆ HairScale()

double ON_SectionAnalysisAppearance::HairScale ( ) const

Returns: (m_hair_scale > 0.0) ? m_hair_scale : 1.0.

◆ HairScaleFromUserInterfaceValue()

static double ON_SectionAnalysisAppearance::HairScaleFromUserInterfaceValue ( int  ui_value)
static

If m_hair_scale > 0.0, when curvature hair is drawn, its length is scaled by this factor. Description: This function provides a good way to use a linear user interface control to set m_hair_scale. Parameter: ui_value - [in] values from -10 to +10 make the most sense. 0: true length >0 lengthen hair <0 shorten hair Returns: 2^(ui_value/2.0) See Also: ON_SectionAnalysisAppearance::HairScaleUserInterfaceValue()

◆ HairScaleUserInterfaceValue()

static int ON_SectionAnalysisAppearance::HairScaleUserInterfaceValue ( double  hair_scale)
static

Returns: User interface value corresponding to the current value of HairScale(); See Also: ON_SectionAnalysisAppearance::HairScaleFromUserInterfaceValue()

◆ operator!=()

bool ON_SectionAnalysisAppearance::operator!= ( const ON_SectionAnalysisAppearance other) const

Compares every value except m_section_appearance_id and m_section_appearance_mark.

◆ operator==()

bool ON_SectionAnalysisAppearance::operator== ( const ON_SectionAnalysisAppearance other) const

Compares every value except m_section_appearance_id and m_section_appearance_mark.

◆ SetAllColors()

void ON_SectionAnalysisAppearance::SetAllColors ( ON_Color  color)

Description: Sets both m_curve_color and m_hair_color to the specified color.

◆ ShowIsoCurves()

bool ON_SectionAnalysisAppearance::ShowIsoCurves ( ) const

Returns: !m_bHideIsoCurvesWhenSectionsAreVisible || (!m_bShowSectionCurve && !m_bShowSectionHair)

Member Data Documentation

◆ Default

const ON_SectionAnalysisAppearance ON_SectionAnalysisAppearance::Default
static

◆ m_bHideIsoCurvesWhenSectionsAreVisible

bool ON_SectionAnalysisAppearance::m_bHideIsoCurvesWhenSectionsAreVisible

true to hide the iso-curves that are commonly drawn on surfaces when section curves are visible.

◆ m_bShowSectionCurve

bool ON_SectionAnalysisAppearance::m_bShowSectionCurve

true to show the curve on the surface

◆ m_bShowSectionHair

bool ON_SectionAnalysisAppearance::m_bShowSectionHair

Sectional curvature hair is visible when m_bShowSectionHair is true and m_hair_spacing > 0.0

◆ m_class_version

unsigned char ON_SectionAnalysisAppearance::m_class_version

constructor sets m_class_version = 0;

Fields may be be added to this class during the V5 lifecycle. If that happens, then m_class_version will be incremented.

◆ m_curve_color

ON_Color ON_SectionAnalysisAppearance::m_curve_color

The color of the section curve.

◆ m_hair_angle_radians

double ON_SectionAnalysisAppearance::m_hair_angle_radians

◆ m_hair_color

ON_Color ON_SectionAnalysisAppearance::m_hair_color

The sectional curvature "hair" color.

◆ m_hair_scale

double ON_SectionAnalysisAppearance::m_hair_scale

◆ m_hair_spacing

double ON_SectionAnalysisAppearance::m_hair_spacing

The frequency of curature hair in a sectional curvature display is controlled by two parameters, m_hair_spacing and m_hair_angle_radians. If m_hair_spacing > 0.0, then the maximum distance between hairs along a sectional curve will be at most m_hair_spacing. If m_hair_angle_radians > 0.0, then the maximum angle bewtween adjacent curature hairs will be around m_hair_angle_radians.

◆ m_section_appearance_id

ON_UUID ON_SectionAnalysisAppearance::m_section_appearance_id

The default copy constructor, operator=, and destructor work fine. Applications can use m_section_appearance_id to track section plane appearance settings. The default constructor sets m_section_appearance_id = ON_nil_id and nothing in opennurbs changes this value.

Rhino uses this value to detect when ON_PlanarSection.m_section_appearance needs to be updated.

◆ m_section_appearance_mark

ON__UINT64 ON_SectionAnalysisAppearance::m_section_appearance_mark

Applications can use m_update_mark for any purpose. The default constructor sets this value to 0 and nothing in opennurbs changes this value.

Rhino saves a time() value in m_section_appearance_mark and uses it to detect when ON_PlanarSection informtion needs to be updated.