[vtkusers] vtk annotations/MFC drawing on the CDC

Prabhu Ramachandran prabhu at aero.iitm.ernet.in
Wed Feb 6 22:49:03 EST 2002


>>>>> "TC" == Ted Christiansen <ted at caept.com> writes:

    TC> Hello, Is it possible to draw on the CDC in the OnDraw
    TC> function:

[snip]

    TC> I tried it but as soon as any transformations happen then the
    TC> drawing disappears.  Anybody else tried this?  I need to do
    TC> some annotation in the view - text and a leader (line with
    TC> arrow head).  If anyone has an example of how to do this using
    TC> vtk classes I would appreciate it.  Thanks.

I'm not sure what exactly you want to oo but IIRC, Will recently
created a neat class called vtkCaptionActor2D that does the following:

vtkCaptionActor2D - draw text label associated with a point

Super Class:

 vtkActor2D

 vtkCaptionActor2D is a hybrid 2D/3D actor that is used to associate text 
 with a point (the AttachmentPoint) in the scene. The caption can be 
 drawn with a rectangular border and a leader connecting 
 the caption to the attachment point. Optionally, the leader can be 
 glyphed at its endpoint to create arrow heads or other indicators.

prabhu



More information about the vtkusers mailing list