3

I have a few separators such as desk, lamp, and frame in my scene graph. When I add them to a separator called, "root," are they then made into nodes? Like if I wanted to use them with a path, is there an equivalent to path->containsNode for separators?

Also, is there a way to identify a separator? Let's say that I would like to place a lamp on a desk. I think the best way would be to check if the lamp collides with a specific separator like desk?

Thanks!

emsr
  • 14,521
  • 6
  • 47
  • 61
m00nbeam360
  • 1,347
  • 2
  • 19
  • 35

1 Answers1

2

The class SoSeparator inherits from [SoNode][2] via SoGroup in the C++ inheritance sense. In other words, any SoSeparator* (i.e. your lamp, desk, ...) is a node. Just use any SoSeparator* anywhere it calls for a SoNode* argument and you should be good.

Do you have a good C++ book, and a copy of The Inventor Mentor on hand?

Community
  • 1
  • 1
emsr
  • 14,521
  • 6
  • 47
  • 61