-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How many things can a node be (or reference)? #1433
Comments
Since a mesh instance and a camera instance at the same node are currently manifestly allowed, I think a light instance should also be allowed. Besides, how would you phrase this requirement? You can say that a light cannot be instantiated at a node that instantiates a mesh or a camera, but what if some other extension defines Xs that can be instantiated at nodes. You haven't excluded a node instantiating a light and an X. In order to solve this it seems like extensions would need global knowledge of all other extensions, or you'd have to have some way of formalizing "defines Xs that can be instantiated at nodes" (eg. if a node had had a (Joints definitely do not belong on that list :) Properly speaking "a node is a joint" refers to a property of the set of joints—that there is one that references the node—not a property of the node in question.) |
My understanding is that a node is just a scene transform state applied to "transformable" objects whatever they are. |
The camera is not ignored in Babylon. Babylon will load the camera but it will not use it by default. I would post a screenshot, but this example seems to place the camera inside the box which doesn't show anything. |
While conceptually true, all engines I'm familiar with do have a real concept of a node, and preserve node hierarchies. Users may expect meshes grouped under a parent node to remain grouped in some way for runtime behavior; the transform state is not the only meaning associated with a node.
Agreed, seems like this is the right interpretation of the spec. I'll consider the current behavior of three.js a bug, filed as mrdoob/three.js#14875.
Ah good to know, thanks. |
Will consider this resolved; no spec change needed. |
My mental model has been that a node referencing a mesh is a mesh in the scene graph. A mesh is a node in most engines, I think (it can have a TRS transform) so appending it as a child of a node would just be needless cruft in the scene graph. However, can a single node be more than one (or all) of the following, simultaneously?
I made a quick test of a mesh-camera (mesh-camera.zip). It passes validation, but the camera is ignored in three.js and BabylonJS.
If this is not the intention, we may want to take the step of disallowing use of KHR_lights_punctual on a node that is already a mesh, camera, or joint before ratifying it.
1 Not entirely sure if joints belong in this list, since they're somewhat implicit in glTF 2.0.
The text was updated successfully, but these errors were encountered: