[vtkusers] How to initialize vtkAngleWidget with three points specified?

Karthik Krishnan karthik.krishnan at kitware.com
Sat Nov 27 20:10:14 EST 2010


Here is a minimal example demonstrating the use of vtkAngleWidget and
its 2D rep and initializing it with either user specified display
positions -or- user specified world positions for the two end points
and the center. Please find it attached.

You can run it by supplying the display positions of its end points

     AngleWidget2D --InitializeDisplayPositions 240 240 240 10 230 2 220 11 230

or by supplying the world positions for the end points:

     AngleWidget2D --InitializeDisplayPositions 240 240 240 10 230 2 220 11 230

Does this answer your question ? We'll try to add this as a test to
the test suite one of these days :)

--
karthik

On Fri, Nov 26, 2010 at 1:05 PM,  <swl0397 at 126.com> wrote:
> Hi Karthik,
>
> Thanks for for your work!
>
> I have been trying to initialize vtkAngleWidget with three points specified, but vtkAngleWidget has not SetPoint1WorldPosition()、SetPoint2WorldPosition() and SetCenterWorldPosition() function
> So I don't know how to initialize it, Can you tell me what I am doing that, please?
>
-------------- next part --------------
PROJECT(AngleWidget2D)
FIND_PACKAGE( VTK REQUIRED )
include(${VTK_USE_FILE})
add_executable( AngleWidget2D AngleWidget2D.cxx )
target_link_libraries( AngleWidget2D vtkWidgets vtkFiltering vtkGraphics vtkCommon vtkRendering )
-------------- next part --------------
A non-text attachment was scrubbed...
Name: AngleWidget2D.cxx
Type: text/x-c++src
Size: 5514 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101128/56021663/attachment.cxx>


More information about the vtkusers mailing list