Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 3 of 3

Thread: Inventor component selection?

  1. #1
    Junior Member Newbie
    Join Date
    Dec 2008
    Posts
    2

    Inventor component selection?

    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?

  2. #2
    Junior Member Newbie
    Join Date
    Jan 2005
    Location
    San Diego, CA
    Posts
    20

    Re: Inventor component selection?

    Quote Originally Posted by Pug620
    Can you select components through Inventor? - ie vertices, edges, and faces.
    Yes, but...
    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.

    -Mike
    Open Inventor User Forum: http://www.openinventor.net

  3. #3
    Junior Member Newbie
    Join Date
    Dec 2008
    Posts
    2

    Re: Inventor component selection?

    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

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •