8.4.2.37. subdiv
|
(packages/opencv/subdiv.lsh) |
dummy function that adds OpenCV C header files in C file
8.4.2.37.0. (cvsubdiv2dnextedge edge)
|
(packages/opencv/subdiv.lsh) |
/************ Basic quad-edge navigation and operations ************/
CV_INLINE CvSubdiv2DEdge cvSubdiv2DNextEdge( CvSubdiv2DEdge edge );
CV_INLINE CvSubdiv2DEdge cvSubdiv2DNextEdge( CvSubdiv2DEdge edge )
{
return CV_SUBDIV2D_NEXT_EDGE(edge);
}
8.4.2.37.1. (cvsubdiv2drotateedge edge rotate)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE CvSubdiv2DEdge cvSubdiv2DRotateEdge( CvSubdiv2DEdge edge, int rotate );
CV_INLINE CvSubdiv2DEdge cvSubdiv2DRotateEdge( CvSubdiv2DEdge edge, int rotate )
{
return (edge & ~3) + ((edge + rotate) & 3);
}
8.4.2.37.2. (cvsubdiv2dsymedge edge)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE CvSubdiv2DEdge cvSubdiv2DSymEdge( CvSubdiv2DEdge edge );
CV_INLINE CvSubdiv2DEdge cvSubdiv2DSymEdge( CvSubdiv2DEdge edge )
{
return edge ^ 2;
}
8.4.2.37.3. (cvsubdiv2dgetedge edge type)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE CvSubdiv2DEdge cvSubdiv2DGetEdge( CvSubdiv2DEdge edge, CvNextEdgeType type );
CV_INLINE CvSubdiv2DEdge cvSubdiv2DGetEdge( CvSubdiv2DEdge edge, CvNextEdgeType type )
{
CvQuadEdge2D* e = (CvQuadEdge2D*)(edge & ~3);
edge = e->next[(edge + (int)type) & 3];
return (edge & ~3) + ((edge + ((int)type >> 4)) & 3);
}
8.4.2.37.4. (cvsubdiv2dedgeorg edge)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE CvSubdiv2DPoint* cvSubdiv2DEdgeOrg( CvSubdiv2DEdge edge );
CV_INLINE CvSubdiv2DPoint* cvSubdiv2DEdgeOrg( CvSubdiv2DEdge edge )
{
CvQuadEdge2D* e = (CvQuadEdge2D*)(edge & ~3);
return e->pt[edge & 3];
}
8.4.2.37.5. (cvsubdiv2dedgedst edge)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE CvSubdiv2DPoint* cvSubdiv2DEdgeDst( CvSubdiv2DEdge edge );
CV_INLINE CvSubdiv2DPoint* cvSubdiv2DEdgeDst( CvSubdiv2DEdge edge )
{
CvQuadEdge2D* e = (CvQuadEdge2D*)(edge & ~3);
return e->pt[(edge + 2) & 3];
}
8.4.2.37.6. (cvtrianglearea a b c)
|
(packages/opencv/subdiv.lsh) |
CV_INLINE double cvTriangleArea( CvPoint2D32f a, CvPoint2D32f b, CvPoint2D32f c );
CV_INLINE double cvTriangleArea( CvPoint2D32f a, CvPoint2D32f b, CvPoint2D32f c )
{
return (b.x - a.x) * (c.y - a.y) - (b.y - a.y) * (c.x - a.x);
}
8.4.2.37.7. (cvcreatesubdiv2d subdiv_type header_size vtx_size quadedge_size storage)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvCreateSubdiv2D
// Purpose: creates initially empty planar subdivision structure
// Context:
// Parameters:
// subdiv_type - type of subdivision
// header_size - size of header(>= sizeof(CvSubdiv2D))
// quadedge_size - size of quad-edges(>= sizeof(CvQuadEdge2D))
// vtx_size - size of vertices(>= sizeof(CvSubdiv2DPoint))
// storage - size of memory storage
// Returns:
// created subdivision
//F*/
OPENCVAPI CvSubdiv2D* cvCreateSubdiv2D( int subdiv_type, int header_size,
int vtx_size, int quadedge_size,
CvMemStorage* storage );
8.4.2.37.8. (cvsubdiv2dlocate subdiv pt edge point)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvSubdiv2DLocate
// Purpose: finds location of the point within the Delaunay triangulation
// origin point of the second edge
// Context:
// Parameters:
// subdiv - subdivison
// pt - searched point
// _edge - bounding edge for facet, containing the point
// _point - vertex(if searched point coincides with the vertex)
//F*/
OPENCVAPI CvSubdiv2DPointLocation cvSubdiv2DLocate(
CvSubdiv2D* subdiv, CvPoint2D32f pt,
CvSubdiv2DEdge *_edge,
CvSubdiv2DPoint** _point CV_DEFAULT(0) );
8.4.2.37.9. (cvFindNearestPoint2D subdiv pt)
|
(packages/opencv/subdiv.lsh) |
/* Finds the nearest to the given point vertex in subdivision. */
CVAPI(CvSubdiv2DPoint*) cvFindNearestPoint2D( CvSubdiv2D* subdiv,
CvPoint2D32f pt );
8.4.2.37.10. (cvinitsubdivdelaunay2d subdiv rect)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvInitSubdivDelaunay2D
// Purpose: connect destination point of the first edge with
// origin point of the second edge
// Context:
// Parameters:
// subdiv - subdivison
// pt - searched point
// _edge - bounding edge for facet, containing the point
// _point - vertex(if searched point coincides with the vertex)
//F*/
OPENCVAPI void cvInitSubdivDelaunay2D( CvSubdiv2D* subdiv, CvRect rect );
8.4.2.37.11. (cvsubdivdelaunay2dinsert subdiv pt)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvSubdivDelaunay2DInsert
// Purpose: insert the point into the triangulation
// Context:
// Parameters:
// subdiv - subdivison
// pt - inserted point
//F*/
OPENCVAPI CvSubdiv2DPoint* cvSubdivDelaunay2DInsert( CvSubdiv2D* subdiv, CvPoint2D32f pt);
8.4.2.37.12. (cvcalcsubdivvoronoi2d subdiv)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvCalcSubdivVoronoi2D
// Purpose: calculates Voronoi tesselation( Coordinates of Voronoi points)
// Context:
// Parameters:
// subdiv - subdivison
// Note:
// Before calculations the function checks the flag, indicating that
// the Voronoi tesselation is already calculated.
// If subdivision is modified(some points have been inserted), the flag is cleared.
//F*/
OPENCVAPI void cvCalcSubdivVoronoi2D( CvSubdiv2D* subdiv );
8.4.2.37.13. (cvclearsubdivvoronoi2d subdiv)
|
(packages/opencv/subdiv.lsh) |
/*F///////////////////////////////////////////////////////////////////////////////////////
// Name: cvClearSubdivVoronoi2D
// Purpose: removes all Voronoi points from the tesselation.
// Context:
// Parameters:
// subdiv - subdivison
// Note:
// The function is called implicitly from the cvCalcSubdivVoronoi2D
// before Voronoi tesselation is calculated.
//F*/
OPENCVAPI void cvClearSubdivVoronoi2D( CvSubdiv2D* subdiv );