00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef __GB_Parameterization_H__
00021 #define __GB_Parameterization_H__
00022
00023 #include "GB_API.h"
00024 #include <UT/UT_PtrMatrix.h>
00025 #include <UT/UT_Vector.h>
00026
00027 class UT_Matrix;
00028
00029 enum GB_ParmType {
00030 GB_PARM_UNIFORM = 0,
00031 GB_PARM_CHORD = 1,
00032 GB_PARM_CENTRIPETAL = 2,
00033 GB_PARM_APPROXARC = 3
00034 };
00035
00036 class GB_API GB_Parameterization {
00037 public:
00038
00039
00040 int equalSpace(const UT_Matrix &dataPts, int wrapped,
00041 UT_Vector ¶m, int endDim=-1);
00042 int chordLength(const UT_Matrix &dataPts, int wrapped,
00043 UT_Vector ¶m, int endDim=-1);
00044 int centripetal(const UT_Matrix &dataPts, int wrapped,
00045 UT_Vector ¶m, int endDim=-1);
00046 int approxArcLength(const UT_Matrix &dataPts, int wrapped,
00047 UT_Vector ¶m, int endDim=-1);
00048
00049
00050
00051
00052
00053 int findClosest(const UT_Vector &parm, fpreal val, int &idx,
00054 int startIdx, int endIdx);
00055 };
00056
00057 #endif