NanoShaper
0.7.2
NanoShaper is a tool able to triangulate and inspect an arbitray triangulated surface or several types of molecular surfaces
|
This class builds and converts to a DelPhi suitable representation the Connolly-Richards Surface. All the gathered info is analytically computed both the intersections and the projections. First the alpha shape of the set of atoms is computed, then from that the Connolly surface is computed by build all the patches. More...
#include <ConnollySurface.h>
Public Member Functions | |
ConnollySurface () | |
ConnollySurface (DelPhiShared *ds) | |
ConnollySurface (ConfigFile *cf, DelPhiShared *ds) | |
virtual bool | build () |
virtual bool | save (char *fileName) |
virtual bool | load (char *fileName) |
virtual void | printSummary () |
virtual bool | getProjection (double p[3], double *proj1, double *proj2, double *proj3, double *normal1, double *normal2, double *normal3) |
virtual void | getRayIntersection (double p1[3], double p2[3], vector< pair< double, double * > > &intersections, int thdID, bool computeNormals) |
virtual void | init () |
virtual void | init (ConfigFile *cf) |
virtual void | clear () |
virtual void | preProcessPanel () |
virtual void | postRayCasting () |
virtual bool | preBoundaryProjection () |
void | setProbeRadius (double pr) |
double | getProbeRadius () |
void | setSavePovRay (bool ss) |
bool | getSavePovRay () |
void | setAuxGrid (unsigned int dim, unsigned int max) |
void | setAuxGrid2D (unsigned int dim, unsigned int max) |
void | setMaxProbes (int m) |
int | getMaxProbes () |
void | setSIPerfil (double si) |
double | getSIPerfil () |
This class builds and converts to a DelPhi suitable representation the Connolly-Richards Surface. All the gathered info is analytically computed both the intersections and the projections. First the alpha shape of the set of atoms is computed, then from that the Connolly surface is computed by build all the patches.
ConnollySurface::ConnollySurface | ( | ) |
Default constructor
ConnollySurface::ConnollySurface | ( | DelPhiShared * | ds | ) |
set DelPhi environment
ConnollySurface::ConnollySurface | ( | ConfigFile * | cf, |
DelPhiShared * | ds | ||
) |
set configuration and DelPhi environment
bool ConnollySurface::build | ( | ) | [virtual] |
Compute connolly surface. Call it after load
Implements Surface.
void ConnollySurface::clear | ( | ) | [virtual] |
function for the denstructor
Implements Surface.
bool ConnollySurface::getProjection | ( | double | p[3], |
double * | proj1, | ||
double * | proj2, | ||
double * | proj3, | ||
double * | normal1, | ||
double * | normal2, | ||
double * | normal3 | ||
) | [virtual] |
Get a projection of a point on the surface. Return projection and normal
Implements Surface.
void ConnollySurface::getRayIntersection | ( | double | p1[3], |
double | p2[3], | ||
vector< pair< double, double * > > & | intersections, | ||
int | thdID, | ||
bool | computeNormals | ||
) | [virtual] |
Get all the intersections of a ray that goes from P1 to P2 over the surface. The interesctions are returned with increasing distance order. the first double in the vector is the t parameter for the intersection of the parametric line and the surface, the double pointer is the normal vector. During ray surface intersection the previously built auxiliary grid is used to speed up computations
Implements Surface.
void ConnollySurface::init | ( | ) | [virtual] |
function for the constructor without arguments
Implements Surface.
void ConnollySurface::init | ( | ConfigFile * | cf | ) | [virtual] |
functions for the constructor with config file argument
Implements Surface.
bool ConnollySurface::load | ( | char * | fileName | ) | [virtual] |
Load the surface from a file in .ses format
Implements Surface.
void ConnollySurface::postRayCasting | ( | ) | [virtual] |
this function is called after ray casting to perform any post processing, such as memory clean-up, after ray casting
Reimplemented from Surface.
bool ConnollySurface::preBoundaryProjection | ( | ) | [virtual] |
this function is called before boundary grid projection to perform any pre-processing, such as memory setup-up.
Reimplemented from Surface.
void ConnollySurface::preProcessPanel | ( | ) | [virtual] |
pre-process panel to accelerate ray-tracing
Reimplemented from Surface.
void ConnollySurface::printSummary | ( | ) | [virtual] |
Print number of cells and types
Implements Surface.
bool ConnollySurface::save | ( | char * | fileName | ) | [virtual] |
Save it in a simple ASCII format (.ses)
Implements Surface.
void ConnollySurface::setAuxGrid | ( | unsigned int | dim, |
unsigned int | max | ||
) | [inline] |
for the 3d grid set the max grid size and the maximal number of patches inside a grid cube
void ConnollySurface::setAuxGrid2D | ( | unsigned int | dim, |
unsigned int | max | ||
) | [inline] |
for the 2d grid set the max grid size and the maximal number of patches inside a grid cube. The grid cube itself does not exist just a reference, indeed the real quantity is MAX_CONNOLLY_CELLS_2D that is the number of patches along the grid tube
void ConnollySurface::setMaxProbes | ( | int | m | ) | [inline] |
set the max number of probes to be tested for self intersections grid. The higher the probe radius the higher this parameter should be.