15 #ifndef __maxToEggConverter__H 16 #define __maxToEggConverter__H 18 #pragma conform(forScope, off) 22 #define MTEC Logger::ST_MAP_ME_TO_APP_SPECIFIC_SYSTEM4 27 #define PHYSIQUE_CLASSID Class_ID(PHYSIQUE_CLASS_ID_A, PHYSIQUE_CLASS_ID_B) 46 struct PandaMaterial {
49 std::vector<int> _map_channels;
55 typedef std::map<Mtl*,PandaMaterial> MaterialMap;
59 std::string _program_name;
63 MaterialMap _material_map;
67 bool convert_char_model();
68 bool convert_char_chan(
double start_frame,
double end_frame,
69 double frame_inc,
double output_frame_rate);
73 void get_transform(INode *max_node,
EggGroup *egg_group);
74 LMatrix4d get_object_transform(INode *max_node);
75 void get_joint_transform(INode *max_node,
EggGroup *egg_group);
76 void get_joint_transform(INode *max_node, INode *parent_node,
79 bool make_nurbs_curve(INode *max_node, NURBSCVCurve *curve,
80 TimeValue time,
EggGroup *egg_group);
81 void make_polyset(INode *max_node,
84 Shader *default_shader =
nullptr);
86 Point3 get_max_vertex_normal(Mesh *mesh,
int faceNo,
int vertNo);
87 VertColor get_max_vertex_color(Mesh *mesh,
int FaceNo,
int VertexNo);
88 VertColor get_max_vertex_color(Mesh *mesh,
int FaceNo,
int VertexNo,
int channel);
89 UVVert get_max_vertex_texcoord(Mesh *mesh,
int faceNo,
int vertNo,
int channel);
91 void get_vertex_weights(INode *max_node,
EggVertexPool *vpool);
93 const PandaMaterial &get_panda_material(Mtl *mtl, MtlID
id);
94 void analyze_diffuse_maps(PandaMaterial &pandaMat, Texmap *m);
95 void analyze_opacity_maps(PandaMaterial &pandaMat, Texmap *m);
96 void analyze_gloss_maps(PandaMaterial &pandaMat, Texmap *m);
97 void analyze_glow_maps(PandaMaterial &pandaMat, Texmap *m);
98 void analyze_normal_maps(PandaMaterial &pandaMat, Texmap *m);
99 void add_map_channel(PandaMaterial &pandaMat,
int channel);
100 void apply_texture_properties(
EggTexture &tex,
int channel);
101 std::string generate_tex_name();
102 std::string get_uv_name(
int n);
107 Modifier* FindSkinModifier (INode* node,
const Class_ID &type);
bool convert(MaxEggOptions *options)
Fills up the egg_data structure according to the global Max model data.
A base class for nodes in the hierarchy that are not leaf nodes.
Defines a texture map that may be applied to geometry.
This is a collection of textures by TRef name.
This is the primary interface into all the egg data, and the root of the egg file structure.
The main glue of the egg hierarchy, this corresponds to the <Group>, <Instance>, and <Joint> type nod...
Describes a single instance of a node in the Max scene graph, relating it to the corresponding egg st...
This class supervises the construction of an EggData structure from a Max model.
A collection of vertices.
Describes a complete tree of max nodes for conversion.