00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _SO_APPEARANCE_PRESERVER_
00025 #define _SO_APPEARANCE_PRESERVER_
00026
00027 #include <Inventor/SbBasic.h>
00028 #include <Inventor/SbString.h>
00029 #include <Inventor/SbLinear.h>
00030
00031 class SoTexture2 ;
00032 class SoTextureCoordinate2 ;
00033 class SoNode ;
00034 class APSTriObject ;
00035 class APS ;
00036
00037 class SoDEPRECATED SoAppearancePreserver
00076 {
00077 public:
00078
00082 typedef void SoAppearancePreserverProgressCB(void *userData,
00083 SoAppearancePreserver *aps,
00084 int percent);
00085
00089 SoAppearancePreserver();
00090
00094 ~SoAppearancePreserver();
00095
00100 void setSceneGraphs(SoNode *original, SoNode *simplified);
00101
00107 void setTextureSize(int width, int height);
00108
00113 void setTriangleMinSize(int size);
00114
00120 void setProgressCallback(SoAppearancePreserverProgressCB *cb, void *data=NULL);
00121
00133 SoNONUNICODE SoTexture2* getNormalMapTexture(const char *filename=NULL);
00134
00144 SoTexture2* getNormalMapTexture( const SbString& filename = "" );
00145
00157 SoNONUNICODE SoTexture2* getDisplacementMapTexture(const char *filename=NULL);
00158
00168 SoTexture2* getDisplacementMapTexture( const SbString& filename = "" );
00169
00178 SoTextureCoordinate2* getBumpCoords();
00179
00180 private:
00181
00182
00183
00184 APSTriObject * getBumpObject();
00185
00186 APS *m_aps;
00187 APSTriObject *m_apsHighLevel;
00188 APSTriObject *m_apsLowLevel;
00189
00190
00191 static void progressCB(int percent, void * data);
00192 SoAppearancePreserverProgressCB *m_callback;
00193 void *m_userData;
00194 };
00195
00196
00197 #endif
00198
00199
00200