I’d like to instantiate a mesh several times, under different nodes. These nodes can include transforms and rotations as well as scales.
At the same time, I want to instantiate rigid bodies which have this (non-convex) mesh as collision shape (in order to test non-convex collision detection). Instantiating the geometry which defines the mesh works fine, and giving the rigid body takes over the node’s translation and rotation, but not the scale. Searching on the forum did not give me a direct result, except for this: viewtopic.php?f=3&t=1242&p=4390&hilit=scale#p4390, which could imply that rigid bodies under a node cannot take this node’s scale. In this case, I would not understand the design decision behind this, though.
Otherwise, I would be thankful for a hint on how to use the same mesh in several (possibly scaled) instances, both for graphics and physics.
Some example code which does not seem to work (at least not in bullet physics):
<geometry id=“Sphere-Geometry” name=“Sphere-Geometry”>
… Mesh data for a triangulated sphere …
<visual_scene id=“Scene” name=“Scene”>
<node id=“Sphere1-Node” name=“Sphere1-Node”>
<scale>2.0 2.0 2.0</scale>
<physics_scene id=“Scene-Physics” name=“Scene-Physics”>
<instance_rigid_body body=“Sphere1-RigidBody” target="#Sphere1-Node"/>
The sphere-mesh is graphically shown twice as big, but has only its original collision size. Any hint on what I could be missing is appreciated.