2009. 6. 5. 15:49
Computer Vision
To do: draw a needle map
ref. Washington University's source code:
http://opencv.willowgarage.com/wiki/CxCore#CurvesandShapes
Line
Draws a line segment connecting two points
void cvLine( CvArr* img, CvPoint pt1, CvPoint pt2, CvScalar color,
int thickness=1, int line_type=8, int shift=0 );
- img
- The image.
- pt1
- First point of the line segment.
- pt2
- Second point of the line segment.
- color
- Line color.
- thickness
- Line thickness.
- line_type
- Type of the line:
-
8 (or omitted) - 8-connected line.
-
4 - 4-connected line.
-
CV_AA - antialiased line.
- shift
- Number of fractional bits in the point coordinates.
The function cvLine draws the line segment between pt1 and pt2 points in the image. The line is clipped by the image or ROI rectangle. For non-antialiased lines with integer coordinates the 8-connected or 4-connected Bresenham algorithm is used. Thick lines are drawn with rounding endings. Antialiased lines are drawn using Gaussian filtering. To specify the line color, the user may use the macro CV_RGB( r, g, b ).
Line
Draws a line segment connecting two points
void cvLine( CvArr* img, CvPoint pt1, CvPoint pt2, CvScalar color, int thickness=1, int line_type=8, int shift=0 );
- img
- The image.
- pt1
- First point of the line segment.
- pt2
- Second point of the line segment.
- color
- Line color.
- thickness
- Line thickness.
- line_type
- Type of the line:
-
8 (or omitted) - 8-connected line.
-
4 - 4-connected line.
-
CV_AA - antialiased line.
-
- shift
- Number of fractional bits in the point coordinates.
The function cvLine draws the line segment between pt1 and pt2 points in the image. The line is clipped by the image or ROI rectangle. For non-antialiased lines with integer coordinates the 8-connected or 4-connected Bresenham algorithm is used. Thick lines are drawn with rounding endings. Antialiased lines are drawn using Gaussian filtering. To specify the line color, the user may use the macro CV_RGB( r, g, b ).
'Computer Vision' 카테고리의 다른 글
photometric stereo 2009-06-10 (0) | 2009.06.10 |
---|---|
Photometric stereo 2009-06-07 (0) | 2009.06.08 |
photometric stereo 2009-05-15 (0) | 2009.05.15 |
Criminisi, Reid, Zisserman <Single View Metrology> (0) | 2009.05.06 |
Photometric stereo 2009-05-01 (0) | 2009.05.01 |