[vtkusers] How to forward mouse move event to polydata algorithm and get there direction of projection
Jana Sefcikova
neollie at gmail.com
Wed Jun 20 02:17:44 EDT 2012
Hi all,
I would like inform my polydata algorithm about change of direction of
projection.
How it could be realised ?
I am attaching my code. As an example of polydata algorithm I inherited
from vtkSphereSource and method that I do not know connect to the rest is
MySphereSource::printDirectionOfProjection.
- One way could be put the vtkInteractorStyleTrackballCamera style ( or
someone else ?) into algorithm as widgets do, but this does not seam to me
very nice.
- Opposite way could be add algorithm's observer to the style such
as vtkCameraObserver in the code. But this method looks like eating the
event -> sphere doesn't rotate anymore and I do not know how to
get GetDirectionOfProjection there . Do you have any idea why ?
What could be correct ?
Thanks in advance
Jana
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120620/bc03f818/attachment.htm>
-------------- next part --------------
cmake_minimum_required(VERSION 2.6)
PROJECT(DisplayCoordinateAxes)
find_package(VTK REQUIRED)
include(${VTK_USE_FILE})
if (APPLE)
add_executable(DisplayCoordinateAxes MACOSX_BUNDLE DisplayCoordinateAxes.cxx)
else()
add_executable(DisplayCoordinateAxes DisplayCoordinateAxes.cxx)
endif()
if(VTK_LIBRARIES)
target_link_libraries(DisplayCoordinateAxes ${VTK_LIBRARIES})
else()
target_link_libraries(DisplayCoordinateAxes vtkHybrid vtkWidgets )
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DisplayCoordinateAxes.cxx
Type: application/octet-stream
Size: 5247 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120620/bc03f818/attachment.obj>
More information about the vtkusers
mailing list