|
Open PaperOpt
|
#include <SurfAcc.h>
Public Member Functions | |
| SurfAcc () | |
| ~SurfAcc () | |
| SurfAcc (double sizeX, double sizeY, int nSegX, int nSegY) | |
| void | ResetAccs (double value=0) |
| void | SetAccs (const SurfAcc *source) |
| void | SetAccs (const Array2D< float > *source) |
| void | CalcPollySupport (double totVal, V2< double > *p1, V2< double > *p2, V2< double > *p3, V2< double > *p4, double linSmpPerSq=5) |
| void | AddSupportToAcc () |
| double | Calc3DegIntegral (double c1, double c2, double c3) const |
| double | CalcPiecLinIntegral (double g1, double g2, double k) const |
| void | CalcPollyHeights (double h2, double h4, V2< double > *p1, V2< double > *p2, V2< double > *p3, V2< double > *p4, int useMin=1, double linSmpPerSq=5) |
| double | GetMinHeightSpan () |
| void | AddHeightsToAcc (int keepMax=1) |
| void | SaveSurfAccBinary (string filename) |
| void | ReadSurfAccFromBinary (string filename) |
| const double * | GetAccumulator () |
| double * | GetAccumulatorModify () |
| double | GetBoxSizeX () |
| double | GetBoxSizeY () |
| double | GetTotal () const |
| double | GetMean () const |
this class mainly used to estimate the depth and height of fiber in the volume
| p3d::SurfAcc::SurfAcc | ( | ) | [inline] |
| p3d::SurfAcc::~SurfAcc | ( | ) | [inline] |
| SurfAcc::SurfAcc | ( | double | sizeX, |
| double | sizeY, | ||
| int | nSegX, | ||
| int | nSegY | ||
| ) |
| void SurfAcc::AddHeightsToAcc | ( | int | keepMax = 1 | ) |

| void SurfAcc::AddSupportToAcc | ( | ) |
Adds support to accumulator

| double SurfAcc::Calc3DegIntegral | ( | double | c1, |
| double | c2, | ||
| double | c3 | ||
| ) | const |
Integrate f(acc(x,y)) over support (linear weight) where f(x)=x^3*c3+x^2*c2+x*c1
| c1 | |
| c2 | |
| c3 | |
| p4 |

| double SurfAcc::CalcPiecLinIntegral | ( | double | g1, |
| double | g2, | ||
| double | k | ||
| ) | const [inline] |
Integrates linear->0 at g1 from left and from 0 from g2 by k. No Use Now
| g1 | |
| g2 | |
| k |
No Use Now
| void SurfAcc::CalcPollyHeights | ( | double | h2, |
| double | h4, | ||
| V2< double > * | p1, | ||
| V2< double > * | p2, | ||
| V2< double > * | p3, | ||
| V2< double > * | p4, | ||
| int | useMin = 1, |
||
| double | linSmpPerSq = 5 |
||
| ) |
Same assumptions as CalcPollySupport h2=height 2->3, h4=height 4->1 Assumes all heights >= 0
| h2 | |
| h4 | |
| p1 | |
| p2 | |
| p3 | |
| p4 | |
| useMin | |
| linSmpPerSq |


| void SurfAcc::CalcPollySupport | ( | double | totVal, |
| V2< double > * | p1, | ||
| V2< double > * | p2, | ||
| V2< double > * | p3, | ||
| V2< double > * | p4, | ||
| double | linSmpPerSq = 5 |
||
| ) |
Assumption1: poly is approximately rectangular when chosing first axis of interpolation. Try to give the short side first for speed. Assumption2: Cordinatesystem approximately square
| totVal | |
| p1 | |
| p2 | |
| p3 | |
| p4 | |
| linSmpPerSq |


| const double* p3d::SurfAcc::GetAccumulator | ( | ) | [inline] |

| double* p3d::SurfAcc::GetAccumulatorModify | ( | ) | [inline] |

| double p3d::SurfAcc::GetBoxSizeX | ( | ) | [inline] |

| double p3d::SurfAcc::GetBoxSizeY | ( | ) | [inline] |

| double SurfAcc::GetMean | ( | ) | const |

| double SurfAcc::GetMinHeightSpan | ( | ) |
Returns min heightspan between support and base. Negative if below base
| double p3d::SurfAcc::GetTotal | ( | ) | const [inline] |

| void SurfAcc::ReadSurfAccFromBinary | ( | string | filename | ) |
read the height buffer from the binary file
| filename | string the path of the file |
| void SurfAcc::ResetAccs | ( | double | value = 0 | ) |

| void SurfAcc::SaveSurfAccBinary | ( | string | filename | ) |
save the surface-accumulator in binary file
| filename | string the path of the file |
| void SurfAcc::SetAccs | ( | const SurfAcc * | source | ) |

| void SurfAcc::SetAccs | ( | const Array2D< float > * | source | ) |
