47 operator = (
const EggNode ©) {
48 EggNamedObject::operator = (copy);
85 return (_under_flags & UF_under_instance) != 0;
97 return (_under_flags & UF_under_transform) != 0;
110 return (_under_flags & UF_local_coord) != 0;
136 if (_vertex_frame == (
LMatrix4d *)NULL) {
139 return *_vertex_frame;
168 if (_vertex_frame_inv == (
LMatrix4d *)NULL) {
171 return *_vertex_frame_inv;
184 if (_node_frame_inv == (
LMatrix4d *)NULL) {
187 return *_node_frame_inv;
204 if (_vertex_to_node == (
LMatrix4d *)NULL) {
207 return *_vertex_to_node;
224 if (_node_to_vertex == (
LMatrix4d *)NULL) {
227 return *_node_to_vertex;
240 return _vertex_frame;
265 return _vertex_frame_inv;
278 return _node_frame_inv;
290 return _vertex_to_node;
302 return _node_to_vertex;
316 r_transform(mat, inv, CS_default);
317 r_transform_vertices(mat);
334 r_transform_vertices(mat);
352 r_flatten_transforms();
void transform(const LMatrix4d &mat)
Applies the indicated transformation to the node and all of its descendants.
This is a 4-by-4 transform matrix.
const LMatrix4d & get_node_frame_inv() const
Returns the inverse of the matrix returned by get_node_frame().
const LMatrix4d * get_node_frame_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_node_frame() matr...
const LMatrix4d & get_vertex_frame() const
Returns the coordinate frame of the vertices referenced by primitives at or under this node...
A base class for nodes in the hierarchy that are not leaf nodes.
int get_depth() const
Returns the number of nodes above this node in the egg hierarchy.
const LMatrix4d * get_node_to_vertex_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_node_to_vertex() ...
const LMatrix4d * get_vertex_frame_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_vertex_frame() ma...
const LMatrix4d * get_vertex_to_node_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_vertex_to_node() ...
bool is_local_coord() const
Returns true if this node's vertices are not in the global coordinate space.
bool is_under_transform() const
Returns true if there is a <Transform> entry somewhere in the egg tree at or above this node...
const LMatrix4d & get_node_frame() const
Returns the coordinate frame of the node itself.
static const LMatrix4d & ident_mat()
Returns an identity matrix.
const LMatrix4d & get_node_to_vertex() const
Returns the transformation matrix suitable for converting vertices in the coordinate space of the nod...
void transform_vertices_only(const LMatrix4d &mat)
Applies the indicated transformation only to vertices that appear in global space within vertex pools...
void flatten_transforms()
Removes any transform and instance records from this node in the scene graph and below.
This is a fairly low-level base class–any egg object that has a name.
bool is_under_instance() const
Returns true if there is an <Instance> node somewhere in the egg tree at or above this node...
A base class for things that may be directly added into the egg hierarchy.
const LMatrix4d * get_node_frame_inv_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_node_frame_inv() ...
const LMatrix4d * get_vertex_frame_inv_ptr() const
Returns either a NULL pointer or a unique pointer shared by nodes with the same get_vertex_frame_inv(...
const LMatrix4d & get_vertex_to_node() const
Returns the transformation matrix suitable for converting the vertices as read from the egg file into...
const LMatrix4d & get_vertex_frame_inv() const
Returns the inverse of the matrix returned by get_vertex_frame().