Models inside jME3 are stored as Spatials
, with Spatials
mostly being either a Node
or a Geometry
.
Nodes
just contain other Spatials
(but can transform their position, rotation, etc) while Geometries
just contain Mesh
es and the Material
s and other information associated with the Mesh
.
The easiest way to do this is to open the model in the SDK and use the Scene Explorer window to view the layout of Nodes
and Meshes
. You can then determine what you need to do, as often you need to drill down through a few Nodes
, find the Geometry
you are interested in, and then get the Mesh
from that Geometry
.
Alternatively programmatically you can just recurse down through the Node
structure, iterating over each child. If the child is a Node
then scan that too, if it is a Geometry then get the Mesh
.