geometryexportcontext.h 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. /*
  2. ** Command & Conquer Renegade(tm)
  3. ** Copyright 2025 Electronic Arts Inc.
  4. **
  5. ** This program is free software: you can redistribute it and/or modify
  6. ** it under the terms of the GNU General Public License as published by
  7. ** the Free Software Foundation, either version 3 of the License, or
  8. ** (at your option) any later version.
  9. **
  10. ** This program is distributed in the hope that it will be useful,
  11. ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ** GNU General Public License for more details.
  14. **
  15. ** You should have received a copy of the GNU General Public License
  16. ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. /***********************************************************************************************
  19. *** C O N F I D E N T I A L --- W E S T W O O D S T U D I O S ***
  20. ***********************************************************************************************
  21. * *
  22. * Project Name : Max2W3D *
  23. * *
  24. * $Archive:: /Commando/Code/Tools/max2w3d/geometryexportcontext.h $*
  25. * *
  26. * Original Author:: Greg Hjelstrom *
  27. * *
  28. * $Author:: Greg_h $*
  29. * *
  30. * $Modtime:: 10/19/00 11:32a $*
  31. * *
  32. * $Revision:: 1 $*
  33. * *
  34. *---------------------------------------------------------------------------------------------*
  35. * Functions: *
  36. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  37. #ifndef GEOMETRYEXPORTCONTEXT_H
  38. #define GEOMETRYEXPORTCONTEXT_H
  39. #include <Max.h>
  40. class ChunkSaveClass;
  41. class MaxWorldInfoClass;
  42. class HierarchySaveClass;
  43. class INodeListClass;
  44. class Progress_Meter_Class;
  45. struct W3dExportOptionsStruct;
  46. /**
  47. ** ExportContextClass
  48. ** This class encapsulates a bunch of datastructures needed during the geometry export
  49. ** process.
  50. ** NOTE: The user must plug in a valid ProgressMeter before each export operation.
  51. */
  52. class GeometryExportContextClass
  53. {
  54. public:
  55. GeometryExportContextClass( char * model_name,
  56. ChunkSaveClass & csave,
  57. MaxWorldInfoClass & world_info,
  58. W3dExportOptionsStruct & options,
  59. HierarchySaveClass * htree,
  60. INode * origin,
  61. INodeListClass * origin_list,
  62. TimeValue curtime
  63. ) :
  64. CSave(csave),
  65. WorldInfo(world_info),
  66. Options(options),
  67. CurTime(curtime),
  68. HTree(htree),
  69. OriginList(origin_list),
  70. Origin(origin),
  71. OriginTransform(1),
  72. ProgressMeter(NULL)
  73. {
  74. ModelName = strdup(model_name);
  75. OriginTransform = Origin->GetNodeTM(CurTime);
  76. }
  77. ~GeometryExportContextClass(void)
  78. {
  79. delete[] ModelName;
  80. }
  81. char * ModelName;
  82. ChunkSaveClass & CSave;
  83. MaxWorldInfoClass & WorldInfo;
  84. W3dExportOptionsStruct & Options;
  85. TimeValue CurTime;
  86. HierarchySaveClass * HTree;
  87. INodeListClass * OriginList;
  88. INode * Origin;
  89. Matrix3 OriginTransform;
  90. Progress_Meter_Class * ProgressMeter;
  91. };
  92. #endif //GEOMETRYEXPORTCONTEXT_H