Replies: 3 comments 8 replies
-
I guess there is a problem with children release.
this discussion may help you: Regarding the intersection of the rectangles, is this what you were looking for? |
Beta Was this translation helpful? Give feedback.
-
Rather than create the rectangle on the fly what I would recommend is create a fixed size rectangle at start up and scale and place it using a vsg::MatrixTransform, updating the transforms matrix each time I want to position/size it. Putting a vsg::Switch above the subgraph if I want to toggle it on/off. For picking the objects in the scene using the extents of the rectangle the tool to use is the new vsg::PolytopeIntersector that I check into VSG master last week. There's a option for section up the polytope based on window coords, the vsgintersection example now has a code path for PolytopeIntersector so have a look at vsgExamples master for this addition. |
Beta Was this translation helpful? Give feedback.
-
I'm sorry, I don't have the time available to investigate what you are doing wrong. |
Beta Was this translation helpful? Give feedback.
-
I'm trying to create a rectangular selection by the mouse. Meanwhile I have managed to draw my selection rectangle as a separate
vsg::View
and have it properly rendered before I enter the vsgadvanceToNextFrame()
main loop. But when I try to update the rectangle position (actually I'm deleting the old rectangle, and creating a new one inside of the loop) I encounter two problems:What am I doing wrong?
Here is my main loop with the rectangle update section:
The complete
select-rectangle.cpp
example is here:https://gist.github.com/dov/90763c1138e0db214430e1d4c2325cff
While, I'm at it, I'd love to get some tips of how I can intersect the rectangle with the scene and find either of the following:
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions