Changeset 554
- Timestamp:
- 03/28/08 18:15:49 (9 months ago)
- Files:
-
- branches/morph-targets/libx42make/include/x42make-modelbuilder.h (modified) (1 diff)
- branches/morph-targets/x42maya/Export-Anim.cpp (modified) (2 diffs)
- branches/morph-targets/x42maya/Export-ConfigCmds.cpp (modified) (2 diffs)
- branches/morph-targets/x42maya/Export-Gather.cpp (modified) (2 diffs)
- branches/morph-targets/x42maya/Export.cpp (modified) (2 diffs)
- branches/morph-targets/x42maya/Export.h (modified) (2 diffs)
- branches/morph-targets/x42maya/X42FileTranslator.cpp (modified) (2 diffs)
- branches/morph-targets/x42maya/X42FileTranslator.h (modified) (2 diffs)
- branches/morph-targets/x42maya/common.h (modified) (1 diff)
- branches/morph-targets/x42maya/entry.cpp (modified) (1 diff)
- branches/morph-targets/x42maya/translator.cpp (added)
- branches/morph-targets/x42maya/translator.h (added)
- branches/morph-targets/x42maya/x42maya.vcproj (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/morph-targets/libx42make/include/x42make-modelbuilder.h
r545 r554 84 84 api_tag() { } 85 85 virtual ~api_tag() { } 86 }; 87 88 template< typename T > 89 class simple_api_tag : public api_tag 90 { 91 public: 92 explicit simple_api_tag( const T &val ) 93 : val( val ) 94 { 95 } 96 97 T& value() { return val; } 98 const T& value() const { return val; } 99 void value( const T &val ) 100 { 101 this->val = val; 102 } 103 104 static T& get_value( api_tag_ptr tag ) 105 { 106 simple_api_tag *p = dynamic_cast< simple_api_tag* >( tag.get() ); 107 108 if( !p ) 109 throw error( "invalid tag type" ); 110 111 return p->value(); 112 } 113 114 static const T& get_value( const_api_tag_ptr tag ) 115 { 116 const simple_api_tag *p = dynamic_cast< const simple_api_tag* >( tag.get() ); 117 118 if( !p ) 119 throw error( "invalid tag type" ); 120 121 return p->value(); 122 } 123 124 private: 125 T val; 86 126 }; 87 127 branches/morph-targets/x42maya/Export-Anim.cpp
r508 r554 22 22 23 23 #include "common.h" 24 25 namespace old 26 { 24 27 25 28 void ExModelData::GetAnimData( MTime startTime, MTime endTime, MTime stepTime ) … … 109 112 baseFrame = animIt.baseFrame(); 110 113 } 114 115 }; branches/morph-targets/x42maya/Export-ConfigCmds.cpp
r508 r554 22 22 23 23 #include "common.h" 24 25 namespace old 26 { 24 27 25 28 /* static */ void* X42Config::Creator( void ) … … 1514 1517 /* static */ ExModelData* X42Config::s_currModel; 1515 1518 /* static */ MString X42Config::s_destFileName; 1519 1520 }; branches/morph-targets/x42maya/Export-Gather.cpp
r512 r554 22 22 23 23 #include "common.h" 24 25 namespace old 26 { 24 27 25 28 /***** … … 1142 1145 tags.push_back( tag ); 1143 1146 } 1147 1148 }; branches/morph-targets/x42maya/Export.cpp
r506 r554 27 27 */ 28 28 29 namespace old 30 { 31 29 32 ExModelData::ExModelData( void ) 30 33 : verbose( false ), scaleScale( 1.0F ), … … 292 295 x42mod.write_data( ostm, model.persistFlags ); 293 296 } 297 298 }; branches/morph-targets/x42maya/Export.h
r506 r554 23 23 #ifndef INC_EXPORT_H 24 24 #define INC_EXPORT_H 25 26 namespace old 27 { 25 28 26 29 using namespace ::x42::make::old; … … 307 310 MPxFileTranslator::FileAccessMode mode ); 308 311 312 }; 313 309 314 #endif branches/morph-targets/x42maya/X42FileTranslator.cpp
r308 r554 22 22 23 23 #include "common.h" 24 25 namespace old 26 { 24 27 25 28 MPxFileTranslator::MFileKind X42FileTranslator::identifyFile( const MFileObject &file, const char *buffer, short size ) const … … 80 83 return new X42FileTranslator; 81 84 } 85 86 }; branches/morph-targets/x42maya/X42FileTranslator.h
r218 r554 24 24 #define INC_EXPORTX42_H 25 25 26 namespace old 27 { 28 26 29 class X42FileTranslator : public MPxFileTranslator 27 30 { … … 41 44 }; 42 45 46 }; 47 43 48 #endif branches/morph-targets/x42maya/common.h
r463 r554 147 147 #include "util.h" 148 148 149 #include "translator.h" 150 149 151 #include "X42FileTranslator.h" 150 152 #include "Export.h" branches/morph-targets/x42maya/entry.cpp
r471 r554 47 47 CHECK_ERR( err ); 48 48 49 V( plugin.registerFileTranslator( X42_TRANSLATOR_NAME, "", X42FileTranslator::Creator ) );50 V( plugin.registerCommand( X42_EXPORT_CONFIG_CMD_NAME, X42Config::Creator,X42Config::SyntaxCreator ) );49 V( plugin.registerFileTranslator( X42_TRANSLATOR_NAME, "", ::old::X42FileTranslator::Creator ) ); 50 V( plugin.registerCommand( X42_EXPORT_CONFIG_CMD_NAME, ::old::X42Config::Creator, ::old::X42Config::SyntaxCreator ) ); 51 51 52 52 MGlobal::executeCommand( "source x42maya.mel" ); branches/morph-targets/x42maya/x42maya.vcproj
r281 r554 660 660 </Filter> 661 661 <Filter 662 Name="Export" 662 Name="export" 663 > 664 <File 665 RelativePath=".\translator.cpp" 666 > 667 </File> 668 <File 669 RelativePath=".\translator.h" 670 > 671 </File> 672 </Filter> 673 <Filter 674 Name="old" 663 675 > 664 676 <File … … 680 692 <File 681 693 RelativePath=".\Export.h" 694 > 695 </File> 696 <File 697 RelativePath=".\X42FileTranslator.cpp" 698 > 699 </File> 700 <File 701 RelativePath=".\X42FileTranslator.h" 682 702 > 683 703 </File> … … 767 787 > 768 788 </File> 769 <File770 RelativePath=".\X42FileTranslator.cpp"771 >772 </File>773 <File774 RelativePath=".\X42FileTranslator.h"775 >776 </File>777 789 </Files> 778 790 <Globals>
