View Full Version : Inventor component selection?
12-31-2008, 09:00 PM
Can you select components through Inventor? - ie vertices, edges, and faces. Maybe I'm missing something, but I didn't see any examples where you could and, while glancing through the API, I didn't see anything. Or is this something where it's just better to write the code in gl?
01-01-2009, 02:41 PM
Can you select components through Inventor? - ie vertices, edges, and faces.
Inventor does most of, but not quite all, the work for you. Compared to using GL directly, Inventor has a lot of advantages because it does real geometric picking (no rendering involved).
The SoRayPickAction gives you an SoPickedPoint object, which directly gives you the exact intersection point on the geometry, the surface normal at that point and some other stuff.
If you want to go deeper, call getDetail() and cast the returned object to the appropriate type, e.g. SoFaceDetail. This object gives you the vertices of the picked face and the index of the face in the geometry node.
If you're selecting faces you're done, else now you have to decide which vertex or edge is closest to the picked point.
Open Inventor User Forum: http://www.openinventor.net
01-01-2009, 04:09 PM
Thanks Mike; that's what I needed to know. Sounds pretty good to me, I'll give it a try. I got kind of burned on PyOpenGL's broken (if that's the right term) VBO, and had to pretty much start over, so I was leaning to bare-bones C++ OpenGL, but if Inventor can do the job - I'm all for it!
One quick ? - is http://www.openinventor.net a fork, takeover, or just a forum for users SGI's Open Inventor? I know that SGI made Inventor, but you're offer it as a product on your site, so I'm a little confused. I could probably find out myself... but I'm lazy :sleeping:
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.