Go to
the documentation of this file.
00001 #if defined(JAMBUILD)
00002 #include <Mudbox/mudbox.h>
00003 #include <MapExtractor/MapExtractorInterface.h>
00004 #else
00005 #include "../../include/Mudbox/mudbox.h"
00006 #include "../../include/MapExtractor/MapExtractorInterface.h"
00007 #endif
00008
00009 #ifndef COMPILING_MAPEXTRACTORAPI_DLL
00010 #define MEADLL MUDBOX_DLLIMPORT
00011 #else
00012 #define MEADLL MUDBOX_DLLEXPORT
00013 #endif
00014
00015 namespace mapextraction
00016 {
00018 MEADLL class Extractor CreateNewOperation( void );
00020 MEADLL int OperationCount( void );
00022 MEADLL class Extractor OperationByIndex( int iIndex );
00023
00025 enum UtilizerType
00026 {
00027 utilTexture,
00028 utilPtex,
00029 utilVertex,
00030
00031 utilUnknown
00032 };
00033
00035 enum LocateMethod
00036 {
00037 locRaycast,
00038
00039 locSubdivision,
00040
00041 locCustom,
00042
00043 locUnknown
00044 };
00045
00047 enum Space
00048 {
00049 spaceWorld,
00050 spaceObject,
00051 spaceTangent,
00052
00053
00054 spaceRawTangent,
00055
00056 spaceNormal,
00057 spaceUnknown
00058 };
00059
00061 enum VertexAction
00062 {
00063 vaVertexColor,
00064 vaMove,
00065 vaDisplace,
00066 vaFreeze,
00067 vaSculptLayerMask,
00068 vaUnknown
00069 };
00070
00072 enum Antialiasing
00073 {
00074 aaOff,
00075 aa2X,
00076 aa4X,
00077 aa6X,
00078 aa8X,
00079 aaUnknown
00080 };
00081
00083 enum Sampling
00084 {
00085 sampleFurthestOutside,
00086 sampleFurthestInside,
00087 sampleClosesToTarget,
00088 sampleUnknown
00089 };
00090
00092 enum Quality
00093 {
00094 qualFastest,
00095 qualFast,
00096 qualNormal,
00097 qualGood,
00098 qualBest,
00099 qualUnknown
00100 };
00101
00103 enum Resolution
00104 {
00105 res256,
00106 res512,
00107 res1024,
00108 res2048,
00109 res4096,
00110 resUnknown
00111 };
00112
00114 enum Compatibility
00115 {
00116 compMaya,
00117 compMax,
00118 compUnknown
00119 };
00120
00122 class MEADLL Component
00123 {
00124 protected:
00125 Component( void );
00126 mudbox::aptr<mapextractionmodules::Component> m_pComponent;
00127
00128 public:
00130 inline bool IsEnabled( void ) const { return m_pComponent->m_bEnabled; };
00132 inline void SetEnabled( bool bEnable ) { m_pComponent.CheckValidity(); m_pComponent->m_bEnabled = bEnable; m_pComponent->m_pMapExtractor->ValidityChanged(); };
00133
00135 enum VertexAction VertexAction( void ) const;
00137 void SetVertexAction( enum VertexAction eAction );
00139 QString FileName( void ) const;
00142 void SetFileName( const QString &sFileName );
00144 bool Preview( void ) const;
00146 void SetPreview( bool bEnable );
00148 Space VertexMoveSpace( void ) const;
00150 void SetVertexMoveSpace( Space eSpace );
00151
00152 mudbox::Vector VertexFactor( void ) const;
00153
00154 void SetVertexFactor( const mudbox::Vector &vFactor );
00155
00156 mudbox::Vector VertexOffset( void ) const;
00157
00158 void SetVertexOffset( const mudbox::Vector &vOffset );
00160 QString LayerNameForVertexAction( void ) const;
00162 void SetLayerNameForVertexAction( const QString &sLayerName );
00163
00164 friend class Extractor;
00165 };
00166
00168 class MEADLL DisplacementComponent : public Component
00169 {
00170 public:
00172 bool NormalizeToSearchDistance( void ) const;
00174 void SetNormalizeToSearchDistance( bool bNormalize );
00175 };
00176
00178 class MEADLL VectorDisplacementComponent : public DisplacementComponent
00179 {
00180 public:
00182 enum Space Space( void ) const;
00184 void SetSpace( enum Space eSpace );
00185 };
00186
00188 class MEADLL NormalComponent : public Component
00189 {
00190 public:
00192 enum Space Space( void ) const;
00194 void SetSpace( enum Space eSpace );
00196 bool Smooth( void ) const;
00198 void SetSmooth( bool bSmooth );
00200 enum Compatibility Compatibility( void ) const;
00202 void SetCompatibility( enum Compatibility eCompatibility );
00203 };
00204
00206 class MEADLL AmbientOcclusionComponent : public Component
00207 {
00208 public:
00210 enum Quality Quality( void ) const;
00212 void SetQuality( enum Quality eQuality );
00214 Resolution ShadowMapResolution( void ) const;
00216 void SetShadowMapresolution( Resolution eResolution );
00218 float ShadowDarkness( void ) const;
00220 void SetShadowDarkness( float fDarkness );
00222 float ShadowContrast( void ) const;
00224 void SetShadowContrast( float fContrast );
00226 float Filter( void ) const;
00228 void SetFilter( float fFilter );
00229 };
00230
00232 class MEADLL PaintLayerScanComponent : public Component
00233 {
00234 public:
00245 QString ChannelName( void ) const;
00256 void SetChannelName( const QString &sChannelName );
00258 int LayerIndex( void ) const;
00260 void SetLayerIndex( int iIndex );
00261 };
00262
00264 class MEADLL SculptLayerScanComponent : public Component
00265 {
00266 public:
00268 QString Layer( void ) const;
00270 void SetLayer( const QString &sLayerName );
00271 };
00272
00275 class MEADLL Extractor
00276 {
00277 Extractor( void );
00278 mudbox::aptr<mapextractionmodules::MapExtractor> m_pMapExtractor;
00279 bool m_bOwn;
00280 public:
00281 ~Extractor( void );
00283 int SourceCount( void ) const;
00285 mudbox::SubdivisionLevel *Source( int iIndex ) const;
00287 void SetSourceCount( int iCount );
00289 void SetSource( int iIndex, mudbox::SubdivisionLevel *pSource );
00291 bool SourceSmoothing( void ) const;
00293 void SetSourceSmoothing( bool bSourceSmoothing );
00294
00296 int TargetCount( void ) const;
00298 mudbox::SubdivisionLevel *Target( int iIndex ) const;
00300 void SetTargetCount( int iCount );
00302 void SetTarget( int iIndex, mudbox::SubdivisionLevel *pTarget );
00304 bool TargetSmoothing( void ) const;
00306 void SetTargetSmoothing( bool bTargetSmoothing );
00308 bool TargetUVSmoothing( void ) const;
00310 void SetTargetUVSmoothing( bool bSmoothUV );
00312 bool TargetCreases( void ) const;
00314 void SetTargetCreases( bool bUse );
00315
00316
00318 enum UtilizerType UtilizerType( void ) const;
00320 void SetUtilizerType( enum UtilizerType eUtilizerType );
00322 int MapWidth( void ) const;
00324 int MapHeight( void ) const;
00326 void SetMapWidth( int iWidth );
00328 void SetMapHeight( int iHeight );
00330 enum Antialiasing Antialiasing( void ) const;
00332 void SetAntialiasing( enum Antialiasing eAntialiasing );
00334 int EdgeBleeding( void ) const;
00337 void SetEdgeBleeding( int iPixels );
00338
00339
00341 class DisplacementComponent DisplacementComponent( void ) const;
00343 class VectorDisplacementComponent VectorDisplacementComponent( void ) const;
00345 class NormalComponent NormalComponent( void ) const;
00347 class AmbientOcclusionComponent AmbientOcclusionComponent( void ) const;
00349 class PaintLayerScanComponent PaintLayerScanComponent( void ) const;
00351 class SculptLayerScanComponent SculptLayerScanComponent( void ) const;
00352
00353
00355 enum LocateMethod LocateMethod( void ) const;
00357 void SetLocateMethod( enum LocateMethod eLocateMethod );
00359 enum Sampling Sampling( void ) const;
00361 void SetSampling( enum Sampling );
00364 float SearchDistance( void ) const;
00367 void SetSearchDistance( float fSearchDistance );
00369 bool TestBothSides( void ) const;
00371 void SetTestBothSides( bool bBothSides );
00375 bool PickLowestLevel( void ) const;
00377 void SetPickLowestLevel( bool bPickLowest );
00378
00380 bool Execute( bool bInterface = true );
00381
00382 friend MEADLL Extractor CreateNewOperation( void );
00383 friend MEADLL Extractor OperationByIndex( int );
00384 };
00385 };