PeriDyno 1.0.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
dyno::Curve Class Reference

#include <Curve.h>

Inheritance diagram for dyno::Curve:
Collaboration diagram for dyno::Curve:

Public Member Functions

 Curve ()
 
 Curve (CurveMode mode)
 
 Curve (const Curve &curve)
 
 ~Curve ()
 
void updateResampleBezierCurve (std::vector< Coord2D > &myBezierPoint_H)
 Resample Bezier curve.
 
void UpdateFieldFinalCoord () override
 Updating the data of a Field.
 
- Public Member Functions inherited from dyno::Canvas
 Canvas ()
 
 ~Canvas ()
 
void addPoint (float x, float y)
 
void addPointAndHandlePoint (Coord2D point, Coord2D handle_1, Coord2D handle_2)
 
void addFloatItemToCoord (float x, float y, std::vector< Coord2D > &coordArray)
 
void clearMyCoord ()
 
void setCurveClose (bool s)
 
void setInterpMode (bool useBezier)
 
void setResample (bool s)
 
void setUseSquard (bool s)
 
void useBezier ()
 
void useLinear ()
 
void setSpacing (double s)
 
void remapX (double minX, double maxX)
 
void remapY (double minY, double maxY)
 
void remapXY (double minX, double maxX, double minY, double maxY)
 
void setRange_MinX (float min, float max)
 
void setRange_MaxX (float min, float max)
 
void setRange_MinY (float min, float max)
 
void setRange_MaxY (float min, float max)
 
void setRange (float min, float max)
 
void addItemOriginalCoord (int x, int y)
 
void addItemHandlePoint (int x, int y)
 
virtual void updateBezierCurve ()
 
void updateBezierPointToBezierSet (Coord2D p0, Coord2D p1, Coord2D p2, Coord2D p3, std::vector< Coord2D > &bezierSet)
 
void updateResampleLinearLine ()
 
void resamplePointFromLine (std::vector< Coord2D > pointSet)
 
std::vector< Coord2DgetPoints ()
 
unsigned getPointSize ()
 
void convertCoordToStr (std::string VarName, std::vector< Canvas::Coord2D > Array, std::string &Str)
 
template<typename T>
void convertVarToStr (std::string VarName, T value, std::string &Str)
 
void setVarByStr (std::string Str, double &value)
 
void setVarByStr (std::string Str, float &value)
 
void setVarByStr (std::string Str, int &value)
 
void setVarByStr (std::string Str, bool &value)
 
void setVarByStr (std::string Str, Canvas::Interpolation &value)
 
void setVarByStr (std::string Str, Direction &value)
 

Additional Inherited Members

- Public Types inherited from dyno::Canvas
enum  Direction { x = 0 , y = 1 , count = 2 }
 
enum  Interpolation { Linear = 0 , Bezier = 1 , InterpolationCount = 2 }
 
enum  CurveMode { Open = 0 , Close = 1 }
 
- Public Attributes inherited from dyno::Canvas
Canvas::Interpolation mInterpMode = Linear
 
std::vector< Coord2DmCoord
 
std::vector< Coord2DmBezierPoint
 
std::vector< Coord2DmFinalCoord
 
std::vector< Coord2DmResamplePoint
 
std::vector< double > mLengthArray
 
std::vector< Coord2DmyHandlePoint
 
std::string InterpStrings [2] = { "Linear","Bezier" }
 
std::vector< OriginalCoordOriginalcoord
 
std::vector< OriginalCoordOriginalHandlePoint
 
float remapRange [8] = { -3,3,-3,3,-3,3,-3,3 }
 
double NminX = 0
 
double NmaxX = 1
 
double mNewMinY = 0
 
double NmaxY = 1
 
bool lockSize = false
 
bool useBezierInterpolation = false
 
bool resample = true
 
bool curveClose = false
 
bool useColseButton = true
 
bool useSquard = true
 
bool useSquardButton = true
 
float Spacing = 5
 
float segment = 10
 
float resampleResolution = 20
 
std::map< float, EndPointlength_EndPoint_Map
 
- Protected Member Functions inherited from dyno::Canvas
void rebuildHandlePoint (std::vector< Coord2D > coordSet)
 
void buildSegMent_Length_Map (std::vector< Coord2D > BezierPtSet)
 

Detailed Description

Definition at line 16 of file Curve.h.

Constructor & Destructor Documentation

◆ Curve() [1/3]

dyno::Curve::Curve ( )

Definition at line 8 of file Curve.cpp.

Here is the caller graph for this function:

◆ Curve() [2/3]

dyno::Curve::Curve ( CurveMode mode)
inline

Definition at line 21 of file Curve.h.

◆ Curve() [3/3]

dyno::Curve::Curve ( const Curve & curve)

Definition at line 14 of file Curve.cpp.

Here is the call graph for this function:

◆ ~Curve()

dyno::Curve::~Curve ( )
inline

Definition at line 27 of file Curve.h.

Member Function Documentation

◆ UpdateFieldFinalCoord()

void dyno::Curve::UpdateFieldFinalCoord ( )
overridevirtual

Updating the data of a Field.

Reimplemented from dyno::Canvas.

Definition at line 57 of file Curve.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateResampleBezierCurve()

void dyno::Curve::updateResampleBezierCurve ( std::vector< Coord2D > & myBezierPoint_H)

Resample Bezier curve.

Definition at line 120 of file Curve.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

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