ImageWindow::DrawLine
Draws a line in the Image Display window
int DrawLine(
int x0,
int y0,
int x1,
int y1
int DrawLine(
double x0,
double y0,
double x1,
double y1,
ProcUnit *ptrProcUnit,
int imageNo
);
Parameters
x0
|
Initial point X position coordinate of the straight line to be drawn (Pixel)
|
y0
|
Initial point Y position coordinate of the straight line to be drawn (Pixel)
|
x1
|
Terminal X position coordinate of the straight line to be drawn (Pixel)
|
y1
|
Terminal Y position coordinate of the straight line to be drawn (Pixel)
|
*ptrProcUnit
|
Pointer to processing unit information
|
imageNo
|
Image number
|
Return Value
Returns 0 when a straight line is successfully drawn.
Otherwise returns a non-zero value.
Description
Draws a straight line at the specified position in the Image Display window.
Example
int Sample::MeasureDispG(ProcUnit *ptrProcUnit, int subNo, ImageWindow *ptrImageWindow)
{
// Display a straight line
ptrImageWindow->DrawLine(100, 100, 200, 200);
// Display a straight line
ptrImageWindow->DrawLine(82.6, 85.8, 210.6, 223.4, ptrProcUnit, 0);
}