PDA

View Full Version : How to clear old drawLine and add new drawLine in Overlay



selvanathan
July 2, 2007, 10:01:34
Dear Sir,
I draw a line on Live display by using following code

m_pGrabber->getOverlay()->drawLine(RGB(255,255,0), 200,0, 200,480);

it works, but i need to change this line position dynamically

i used

void Test_Dlg::OnButton1()
{
a=a+10;
b=b+10;
m_pGrabber->getOverlay()->drawLine(RGB(255,255,0), a,0, b,480);
}
it works but old line not clears, how i clear old line.. plz help me..

thanks in advance:)

Stefan Geissler
July 2, 2007, 17:40:32
Hello Selvanathan

If the code you posted would delete old lines, then you would be able to draw just only one line.

In order to delete a previous drawing, you should draw the same again, but now with the dropout color. Then draw the new line. Please refer to:
http://www.imagingcontrol.com/support/documentation/class/meth_descOverlayBitmap_getDropOutColor.htm

selvanathan
July 4, 2007, 07:00:04
Dear Sir,
Thank u for u r reply. It working fine..:)

fliming
January 20, 2011, 05:38:40
hi

// We load the circle
var circle = new MapCircleOverlay(
mapManager.getPosition(),
10, “#FF0000″, 0.8, 3, “#FF0000″, 0.35

should be this

// We load the circle
var circle = new MapCircleOverlay(
myLatLng , 50, 2, “#FF0000″, 0.8, “#FF0000″, 0.35
);

mapManager doesn’t excist