1.5.1
CCC
 
PolyLine2D.hpp File Reference
#include "gstlearn_export.hpp"
#include "Basic/AStringable.hpp"
#include "Basic/ASerializable.hpp"
#include "Basic/VectorNumT.hpp"
#include "Basic/VectorHelper.hpp"
#include "Basic/NamingConvention.hpp"

Classes

struct  PolyPoint2D
 
class  PolyLine2D
 

Functions

double distanceBetweenPolylines (const PolyLine2D &poly1, const PolyLine2D &poly2, const PolyPoint2D &pldist1, const PolyPoint2D &pldist2)
 
GSTLEARN_EXPORT int dbUnfoldPolyline (Db *db, const PolyLine2D &polyline, const NamingConvention &namconv=NamingConvention("Unfold"))
 
GSTLEARN_EXPORT int dbFoldPolyline (DbGrid *dbin, Db *dbout, const VectorInt &cols, const PolyLine2D &polyline, const NamingConvention &namconv=NamingConvention("Fold"))
 
GSTLEARN_EXPORT int dbFromPolylines (Db *db, const PolyLine2D &top, const PolyLine2D &bot, int nb_neigh=0, bool flagMask=true, const NamingConvention &namconv=NamingConvention("Lines"))
 

Function Documentation

◆ dbFoldPolyline()

GSTLEARN_EXPORT int dbFoldPolyline ( DbGrid dbin,
Db dbout,
const VectorInt cols,
const PolyLine2D polyline,
const NamingConvention namconv 
)

Fold an input Db into an output Db with respect to a polyline

Returns
Error return code
Parameters
[in]dbinInput Db structure
[in]dboutOutput Db structure
[in]colsVector of the target variable ranks
[in]polylinePolyLine2D structure
[in]namconvNaming convention

◆ dbFromPolylines()

GSTLEARN_EXPORT int dbFromPolylines ( Db db,
const PolyLine2D top,
const PolyLine2D bot,
int  nb_neigh,
bool  flagMask,
const NamingConvention namconv 
)

Calculate quantities on the Db by comparison with top and bottom polylines

Parameters
dbPointer to the Db where relevant information will be stored
top2-D Polyline defining the Top surface
bot2-D Polyline defining the Bottom surface
nb_neighSize of neighborhood radius (for regularizing the angle calculation)
flagMaskMask if the target is outside the two polylines
namconvNaming convention
Returns
Error return code
Remarks
Three variables are created:
1 - Minimum distance between Target and Polylines
2 - Distance between Polylines at Target location
3 - Average angle of Polylines at Target location

◆ dbUnfoldPolyline()

GSTLEARN_EXPORT int dbUnfoldPolyline ( Db db,
const PolyLine2D polyline,
const NamingConvention namconv 
)

Unfold a 2-D Db with respect to a polyline

Returns
Error return code
Parameters
[in]dbDb structure
[in]polylinePolyLine2D structure
[in]namconvNaming convention

◆ distanceBetweenPolylines()

double distanceBetweenPolylines ( const PolyLine2D poly1,
const PolyLine2D poly2,
const PolyPoint2D pldist1,
const PolyPoint2D pldist2 
)