source file REDCID.h

Go to the documentation of this file.

#ifndef RED_CID_H
#define RED_CID_H

//************************************************************************************************************
// Copyright (c) 2005 Redway3D. All rights reserved. Redway3D is a registered trademark. Any reproduction and /
// or utilization of any material from this document without Redway3D?s express authorization are prohibited.
//************************************************************************************************************

#include "RED.h"


//******************************************************************************
//*** CID class list ***********************************************************
//******************************************************************************

// CID class values are generated from the result of RED::Object::GetIDFromString, using
// the #define statement string name without the "CID_class_" prefix.

#define CID_class_REDAnimationClip                                571070550U
#define CID_class_REDAnimationData                                584728402U
#define CID_class_REDBoundingSphere                               877678313U
#define CID_class_REDCloudsVolumeShape                            559073712U
#define CID_class_REDColor                                        2439948678U
#define CID_class_REDFastRandom                                   3940716606U
#define CID_class_REDFile                                         3593012356U
#define CID_class_REDFileHeader                                   1296168143U   
#define CID_class_REDFileInfo                                     629145555U
#define CID_class_REDFrameStatistics                              1280956183U
#define CID_class_REDGICache                                      1226417486U
#define CID_class_REDIAnimationClipController                     645590575U
#define CID_class_REDIChunkSaver                                  3975448845U
#define CID_class_REDICloudsVolumeShape                           294226899U
#define CID_class_REDIDataManager                                 2775010560U
#define CID_class_REDIFont                                        4107959230U
#define CID_class_REDIGeometryDatabase                            3635157216U
#define CID_class_REDIGraphicDevice                               3994499079U
#define CID_class_REDIGICache                                     1564090791U
#define CID_class_REDIImage                                       2166187871U
#define CID_class_REDIImage2D                                     871233402U
#define CID_class_REDIImage3D                                     720815675U
#define CID_class_REDIImageComposite                              517706381U
#define CID_class_REDIImageCube                                   736691069U
#define CID_class_REDIImageReadback                               3118874799U
#define CID_class_REDILicense                                     2211676379U
#define CID_class_REDILightShape                                  1968041037U
#define CID_class_REDILineShape                                   1681753932U
#define CID_class_REDIMaterial                                    151022973U
#define CID_class_REDIMaterialController                          950814786U
#define CID_class_REDIMaterialControllerProperty                  2438439636U
#define CID_class_REDIMeshShape                                   2659084432U
#define CID_class_REDIMoonLightShape                              1463328430U
#define CID_class_REDIOptions                                     813801071U
#define CID_class_REDIPhysicalLightShape                          3653430553U
#define CID_class_REDIPointShape                                  1302320041U
#define CID_class_REDIREDFile                                     3442428378U
#define CID_class_REDIReferenceManager                            3292380005U
#define CID_class_REDIReferenceSolving                            4201583082U
#define CID_class_REDIResourceManager                             680173313U
#define CID_class_REDIShape                                       2568002776U
#define CID_class_REDISkeletalAnimationBlender                    3485866354U
#define CID_class_REDISkeletalAnimationController                 3238872942U
#define CID_class_REDISkyLightShape                               635674704U
#define CID_class_REDISoftBucket                                  1219530593U
#define CID_class_REDISoftLight                                   4005091166U
#define CID_class_REDISoftRayContext                              2195351758U
#define CID_class_REDISoftRenderingContext                        3436860497U
#define CID_class_REDISoftShaderContext                           898522622U
#define CID_class_REDIStream                                      4037910143U
#define CID_class_REDISunLightShape                               1191661562U
#define CID_class_REDITextShape                                   3893234336U
#define CID_class_REDITransformShape                              1645693268U
#define CID_class_REDIUserData                                    3724688580U
#define CID_class_REDIViewpoint                                   3130956593U
#define CID_class_REDIViewpointRenderList                         2641102371U
#define CID_class_REDIVolumeShape                                 388402183U
#define CID_class_REDIWindow                                      2342574526U
#define CID_class_REDLayerSet                                     2124066072U
#define CID_class_REDLightSourceShape                             171356432U
#define CID_class_REDLineShape                                    901436824U
#define CID_class_REDMatrix                                       633931239U
#define CID_class_REDMap                                          541074757U
#define CID_class_REDNodeShape                                    2035526615U
#define CID_class_REDObject                                       1968697284U
#define CID_class_REDPassStatistics                               3441092405U
#define CID_class_REDPointShape                                   3429909046U
#define CID_class_REDPostProcess                                  3920872471U
#define CID_class_REDQuaternion                                   1338783530U
#define CID_class_REDRandom                                       3418463997U
#define CID_class_REDRayCutoffShader                              2892360795U
#define CID_class_REDRayGIDiffuseShader                           2893717236U
#define CID_class_REDRayGIReflectionColorShader                   1597982034U
#define CID_class_REDRayGIRefractionColorShader                   465120268U
#define CID_class_REDRayReflectionShader                          4078863050U
#define CID_class_REDRayRefractionShader                          3203994591U
#define CID_class_REDReflectionBackgroundShader                   199859712U
#define CID_class_REDReflectionShader                             3013852283U
#define CID_class_REDRenderCode                                   2486586152U
#define CID_class_REDRenderLayer                                  3237903663U
#define CID_class_REDRenderShader                                 3705764615U
#define CID_class_REDRenderShaderAAFilter                         3732164584U
#define CID_class_REDRenderShaderAmbient                          1373171862U
#define CID_class_REDRenderShaderAnisotropic                      57856230U
#define CID_class_REDRenderShaderData                             11714311U
#define CID_class_REDRenderShaderEdges                            4124633528U
#define CID_class_REDRenderShaderEnvironmental                    2275533128U
#define CID_class_REDRenderShaderLambert                          4109048992U
#define CID_class_REDRenderShaderLogo                             3813710004U
#define CID_class_REDRenderShaderMatteShadow                      2362466068U
#define CID_class_REDRenderShaderParameter                        4246110795U
#define CID_class_REDRenderShaderPhong                            3761443580U
#define CID_class_REDRenderShaderRefractionEffect                 1594461414U
#define CID_class_REDRenderShaderSectionCut                       2344771150U
#define CID_class_REDRenderShaderSolid                            3997837745U
#define CID_class_REDRenderShaderText                             2529880995U
#define CID_class_REDRenderShaderVertexColor                      1043004559U
#define CID_class_REDRenderShaderViewport                         852158030U
#define CID_class_REDResourceManager                              4261844886U
#define CID_class_REDRNG                                          2644204650U
#define CID_class_REDShader                                       571070976U
#define CID_class_REDShaderString                                 479595875U
#define CID_class_REDShapePath                                    773431222U
#define CID_class_REDState                                        1420506004U
#define CID_class_REDStateShader                                  1777735029U
#define CID_class_REDStateShaderPlatformData                      1617377536U
#define CID_class_REDStreamingPolicy                              735595479U
#define CID_class_REDString                                       1128593025U
#define CID_class_REDTextShape                                    3112786036U
#define CID_class_REDThread                                       3973712043U
#define CID_class_REDTimer                                        2649243509U
#define CID_class_REDTriangleShape                                2527523356U
#define CID_class_REDUserData                                     2270221045U
#define CID_class_REDUserDataRaw                                  2788365986U
#define CID_class_REDVector                                       3331591283U
#define CID_class_REDVector3                                      2753051153U
#define CID_class_REDVector4                                      981249970U
#define CID_class_REDViewpoint                                    3944335845U
#define CID_class_REDViewpointStatistics                          175252281U
#define CID_class_REDVolumeShape                                  3979683281U
#define CID_class_REDVolumetricEffect                             1705030156U
#define CID_class_REDVolumetricEffectLightVolume                  1246640798U
#define CID_class_REDVolumetricEffectBoxVolume                    2728400246U
#define CID_class_REDVolumetricEffectClouds                       3270486097U
#define CID_class_REDWindowRenderInfo                             95015719U
#define CID_class_RNETIMessage                                    1907827990U
#define CID_class_RNETIPeer                                       3553408195U
#define CID_class_RNETPeer                                        2571694746U


//******************************************************************************
//*** CID declaration macros ***************************************************
//******************************************************************************

#define SET_CID( cid_value )\
  static RED::CID GetClassID() { return cid_value; }


#define IMPLEMENT_AS()\
  virtual void* As( const RED::CID& iCID );\
  virtual const void* As( const RED::CID& iCID ) const;\
  template< class T_As > T_As* As() { return static_cast< T_As* >( As( T_As::GetClassID() ) ); }\
  template< class T_As > const T_As* As() const { return static_cast< const T_As* >( As( T_As::GetClassID() ) ); }


//******************************************************************************
//*** CID class definition *****************************************************
//******************************************************************************

namespace RED
{
  class REDFullExp CID
  {
    public:
      
      // Construction and destruction methods:
      // -------------------------------------
      
      CID( unsigned int iKey ) :
        _key( iKey )
      {
      }
      
      
      ~CID()
      {
      }
      
      
      // CID operations:
      // ---------------
      
      inline bool operator == ( const CID& iOther ) const;
      
      
      inline bool operator != ( const CID& iOther ) const;
      
      
      inline unsigned int GetKey() const;
      
      
    private:
      
      unsigned int _key;
  };
};


//******************************************************************************
//*** CID inline methods *******************************************************
//******************************************************************************

bool RED::CID::operator == ( const RED::CID& iOther ) const
{
  return( _key == iOther._key );
}


bool RED::CID::operator != ( const RED::CID& iOther ) const
{
  return( _key != iOther._key );
}


inline unsigned int RED::CID::GetKey() const
{
  return _key;
}


#endif