Kitware / VolView

Kitware VolView: an all-in-one radiological viewer!
https://volview.kitware.com
Apache License 2.0
178 stars 60 forks source link

Easiest way to get the world coordinate out of a clicked location for debugging #644

Closed sedghi closed 2 weeks ago

sedghi commented 1 month ago

Two questions:

CleanShot 2024-08-20 at 12 03 50@2x

Thanks!

PaulHax commented 1 month ago

How can I efficiently (easily) obtain a world coordinate from clicking on a viewport for debugging purposes?

console.log here? https://github.com/Kitware/VolView/blob/main/src/vtk/RulerWidget/behavior.ts#L92

What's the simplest method to retrieve the actor and mapper for each viewport? is there any utilities on window similar to vtk examples?

Tricker. Here is a spot where to can get the "slice" actor/mapper pair associated with a "view": https://github.com/Kitware/VolView/blob/main/src/components/vtk/VtkBaseSliceRepresentation.vue#L36

PaulHax commented 2 weeks ago

Any more questions are welcome.