MeshCore::FunctionContainer Class Reference

Helper class for the quadric fit. More...

#include <Approximation.h>

Public Types

typedef double(* Function) (double, double, double)
 WildMagic library uses function with this interface. More...
 

Public Member Functions

void Assign (const double *pKoef)
 Apply quadric coefficients. More...
 
bool CurvatureInfo (double x, double y, double z, double &rfCurv0, double &rfCurv1)
 
bool CurvatureInfo (double x, double y, double z, double &rfCurv0, double &rfCurv1, Wm4::Vector3< double > &rkDir0, Wm4::Vector3< double > &rkDir1, double &dDistance)
 Redirector to a method of the WildMagic library. More...
 
double F (double x, double y, double z)
 
 FunctionContainer (const double *pKoef)
 The constructor expects an array of quadric coefficients. More...
 
double Fx (double x, double y, double z)
 
double Fxx (double x, double y, double z)
 
double Fxy (double x, double y, double z)
 
double Fxz (double x, double y, double z)
 
double Fy (double x, double y, double z)
 
double Fyy (double x, double y, double z)
 
double Fyz (double x, double y, double z)
 
double Fz (double x, double y, double z)
 
double Fzz (double x, double y, double z)
 
Base::Vector3f GetGradient (double x, double y, double z) const
 
Base::Matrix4D GetHessian (double x, double y, double z) const
 
double & operator[] (int idx)
 Access to the quadric coefficients. More...
 
 ~FunctionContainer ()
 Destructor. More...
 

Protected Attributes

double dKoeff [10]
 Coefficients of quadric. More...
 
Wm4::ImplicitSurface< double > * pImplSurf
 Access to the WildMagic library. More...
 

Detailed Description

Helper class for the quadric fit.

Includes the partial derivates of the quadric and serves for calculation of the quadric properties.

Member Typedef Documentation

◆ Function

typedef double(* MeshCore::FunctionContainer::Function) (double, double, double)

WildMagic library uses function with this interface.

Constructor & Destructor Documentation

◆ FunctionContainer()

MeshCore::FunctionContainer::FunctionContainer ( const double *  pKoef)

The constructor expects an array of quadric coefficients.

Parameters
pKoefPointer to the quadric coefficients (double [10])

References Assign(), dKoeff, and pImplSurf.

◆ ~FunctionContainer()

MeshCore::FunctionContainer::~FunctionContainer ( )

Destructor.

Deletes the ImpicitSurface instance of the WildMagic library

References pImplSurf.

Member Function Documentation

◆ Assign()

void MeshCore::FunctionContainer::Assign ( const double *  pKoef)

Apply quadric coefficients.

Parameters
pKoefPointer to the quadric coefficients (double [10])

References dKoeff.

Referenced by FunctionContainer().

◆ CurvatureInfo() [1/2]

bool MeshCore::FunctionContainer::CurvatureInfo ( double  x,
double  y,
double  z,
double &  rfCurv0,
double &  rfCurv1 
)

References dKoeff, Fx(), Fy(), and Fz().

◆ CurvatureInfo() [2/2]

bool MeshCore::FunctionContainer::CurvatureInfo ( double  x,
double  y,
double  z,
double &  rfCurv0,
double &  rfCurv1,
Wm4::Vector3< double > &  rkDir0,
Wm4::Vector3< double > &  rkDir1,
double &  dDistance 
)

Redirector to a method of the WildMagic library.

Determines the principal curvatures and their directions at the given point.

Parameters
xX-coordinate
yY-coordinate
zZ-coordinate
rfCurv01. principal curvature
rfCurv12. principal curvature
rkDir0direction of 1. principal curvature
rkDir1direction of 2. principal curvature
dDistanceGives distances from the point to the quadric.
Returns
bool Success = true, otherwise false

References pImplSurf.

Referenced by MeshCore::QuadraticFit::GetCurvatureInfo(), and MeshCore::SurfaceFit::GetCurvatureInfo().

◆ F()

◆ Fx()

double MeshCore::FunctionContainer::Fx ( double  x,
double  y,
double  z 
)

References dKoeff.

Referenced by CurvatureInfo().

◆ Fxx()

double MeshCore::FunctionContainer::Fxx ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ Fxy()

double MeshCore::FunctionContainer::Fxy ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ Fxz()

double MeshCore::FunctionContainer::Fxz ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ Fy()

double MeshCore::FunctionContainer::Fy ( double  x,
double  y,
double  z 
)

References dKoeff.

Referenced by CurvatureInfo().

◆ Fyy()

double MeshCore::FunctionContainer::Fyy ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ Fyz()

double MeshCore::FunctionContainer::Fyz ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ Fz()

double MeshCore::FunctionContainer::Fz ( double  x,
double  y,
double  z 
)

References dKoeff.

Referenced by CurvatureInfo().

◆ Fzz()

double MeshCore::FunctionContainer::Fzz ( double  x,
double  y,
double  z 
)

References dKoeff.

◆ GetGradient()

Base::Vector3f MeshCore::FunctionContainer::GetGradient ( double  x,
double  y,
double  z 
) const

◆ GetHessian()

Base::Matrix4D MeshCore::FunctionContainer::GetHessian ( double  x,
double  y,
double  z 
) const

◆ operator[]()

double & MeshCore::FunctionContainer::operator[] ( int  idx)

Access to the quadric coefficients.

Parameters
idxIndex to coefficient
Returns
double& coefficient

References dKoeff.

Member Data Documentation

◆ dKoeff

double MeshCore::FunctionContainer::dKoeff[10]
protected

Coefficients of quadric.

Referenced by Assign(), CurvatureInfo(), F(), FunctionContainer(), Fx(), Fxx(), Fxy(), Fxz(), Fy(), Fyy(), Fyz(), Fz(), Fzz(), and operator[]().

◆ pImplSurf

Wm4::ImplicitSurface<double>* MeshCore::FunctionContainer::pImplSurf
protected

Access to the WildMagic library.

Referenced by CurvatureInfo(), FunctionContainer(), GetGradient(), GetHessian(), and ~FunctionContainer().


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