diff --git a/pandatool/src/mayaegg/mayaApi.cxx b/pandatool/src/mayaegg/mayaApi.cxx index cee5e5a3b1..e894f908eb 100644 --- a/pandatool/src/mayaegg/mayaApi.cxx +++ b/pandatool/src/mayaegg/mayaApi.cxx @@ -141,7 +141,6 @@ read(const Filename &filename) { stat.perror(filename.c_str()); return false; } - mayaegg_cat.info() << "done.\n"; return true; } diff --git a/pandatool/src/mayaegg/mayaShader.cxx b/pandatool/src/mayaegg/mayaShader.cxx index abde910f30..1a407a47d8 100644 --- a/pandatool/src/mayaegg/mayaShader.cxx +++ b/pandatool/src/mayaegg/mayaShader.cxx @@ -230,7 +230,11 @@ read_surface_shader(MObject shader) { void MayaShader:: read_surface_color(MObject color) { if (color.hasFn(MFn::kFileTexture)) { - _has_texture = get_string_attribute(color, "fileTextureName", _texture); + string filename; + _has_texture = get_string_attribute(color, "fileTextureName", filename); + if (_has_texture) { + _texture = Filename::from_os_specific(filename); + } get_vec2f_attribute(color, "coverage", _coverage); get_vec2f_attribute(color, "translateFrame", _translate_frame); diff --git a/pandatool/src/mayaegg/mayaShader.h b/pandatool/src/mayaegg/mayaShader.h index f4792f6822..adada511e2 100644 --- a/pandatool/src/mayaegg/mayaShader.h +++ b/pandatool/src/mayaegg/mayaShader.h @@ -50,7 +50,7 @@ public: double _transparency; bool _has_texture; - string _texture; + Filename _texture; LVector2f _coverage; LVector2f _translate_frame; diff --git a/pandatool/src/mayaegg/mayaToEggConverter.cxx b/pandatool/src/mayaegg/mayaToEggConverter.cxx index d1c1d140d6..10c7084b90 100644 --- a/pandatool/src/mayaegg/mayaToEggConverter.cxx +++ b/pandatool/src/mayaegg/mayaToEggConverter.cxx @@ -164,6 +164,10 @@ convert_file(const Filename &filename) { //////////////////////////////////////////////////////////////////// bool MayaToEggConverter:: convert_maya() { + if (_egg_data->get_coordinate_system() == CS_default) { + _egg_data->set_coordinate_system(_maya->get_coordinate_system()); + } + MStatus status; MItDag dag_iterator(MItDag::kDepthFirst, MFn::kTransform, &status); @@ -172,10 +176,8 @@ convert_maya() { return false; } - if (mayaegg_cat.is_debug()) { - mayaegg_cat.debug() - << "Traversing scene graph.\n"; - } + mayaegg_cat.info() + << "Converting from Maya.\n"; // This while loop walks through the entire Maya hierarchy, one node // at a time. Maya's MItDag object automatically performs a @@ -197,10 +199,10 @@ convert_maya() { if (all_ok) { mayaegg_cat.info() - << "\nDone, no errors.\n"; + << "Converted, no errors.\n"; } else { mayaegg_cat.info() - << "\nDone, errors encountered.\n"; + << "Errors encountered in conversion.\n"; } return all_ok; diff --git a/pandatool/src/mayaprogs/mayaToEgg.h b/pandatool/src/mayaprogs/mayaToEgg.h index f336d83caa..1474377db2 100644 --- a/pandatool/src/mayaprogs/mayaToEgg.h +++ b/pandatool/src/mayaprogs/mayaToEgg.h @@ -29,7 +29,6 @@ class MayaToEgg : public SomethingToEgg { public: MayaToEgg(); - ~MayaToEgg(); void run();