- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- File List
- File Members

# FCDocument/FCDEffectProfileFX.h

Go to the documentation of this file.

    00001 /*
    00002     Copyright (C) 2005-2007 Feeling Software Inc.
    00003     Portions of the code are:
    00004     Copyright (C) 2005-2007 Sony Computer Entertainment America
    00005
    00006     MIT License: http://www.opensource.org/licenses/mit-license.php
    00007 */
    00008 /*
    00009     Based on the FS Import classes:
    00010     Copyright (C) 2005-2006 Feeling Software Inc
    00011     Copyright (C) 2005-2006 Autodesk Media Entertainment
    00012     MIT License: http://www.opensource.org/licenses/mit-license.php
    00013 */
    00014
    00020 #ifndef _FCD_EFFECT_PROFILE_FX_H_
    00021 #define _FCD_EFFECT_PROFILE_FX_H_
    00022
    00023 #ifndef _FU_DAE_ENUM_H_
    00024 #include "FUtils/FUDaeEnum.h"
    00025 #endif // _FU_DAE_ENUM_H_
    00026 #ifndef _FCD_EFFECT_PROFILE_H_
    00027 #include "FCDocument/FCDEffectProfile.h"
    00028 #endif // _FCD_EFFECT_PROFILE_H_
    00029
    00030 class FCDocument;
    00031 class FCDEffect;
    00032 class FCDEffectCode;
    00033 class FCDEffectParameter;
    00034 class FCDEffectParameterSurface;
    00035 class FCDEffectTechnique;
    00036
    00055 class FCOLLADA_EXPORT FCDEffectProfileFX : public FCDEffectProfile
    00056 {
    00057 private:
    00058     DeclareObjectType(FCDEffectProfile);
    00059     DeclareParameter(uint32, FUParameterQualifiers::SIMPLE, type, FC("Profile Language")); // FUDaeProfileType::Type
    00060     DeclareParameter(fstring, FUParameterQualifiers::SIMPLE, platform, FC("Platform"));
    00061
    00062     DeclareParameterContainer(FCDEffectCode, codes, FC("Code Inclusions"));
    00063     DeclareParameterContainer(FCDEffectTechnique, techniques, FC("Effect Techniques"));
    00064
    00065 public:
    00069     FCDEffectProfileFX(FCDocument* document, FCDEffect* parent);
    00070
    00072     virtual ~FCDEffectProfileFX();
    00073
    00079     virtual FUDaeProfileType::Type GetType() const { return (FUDaeProfileType::Type) *type; }
    00080
    00083     void SetType(FUDaeProfileType::Type _type) { type = _type; }
    00084
    00088     const fstring& GetPlatform() const { return platform; }
    00089
    00093     void SetPlatform(const fstring& _platform) { platform = _platform; SetDirtyFlag(); }
    00094
    00099     DEPRECATED(3.05A, GetTechniqueCount and GetTechnique(index)) void GetTechniqueList() const {}
    00100
    00103     size_t GetTechniqueCount() const { return techniques.size(); }
    00104
    00110     FCDEffectTechnique* GetTechnique(size_t index) { FUAssert(index < GetTechniqueCount(), return NULL); return techniques.at(index); }
    00111     const FCDEffectTechnique* GetTechnique(size_t index) const { FUAssert(index < GetTechniqueCount(), return NULL); return techniques.at(index); }
    00115     FCDEffectTechnique* AddTechnique();
    00116
    00119     DEPRECATED(3.05A, GetCodeCount and GetCode(index)) void GetCodeList() {}
    00120
    00123     size_t GetCodeCount() const { return codes.size(); }
    00124
    00128     inline FCDEffectCode* GetCode(size_t index) { FUAssert(index < GetCodeCount(), return NULL); return codes.at(index); }
    00129     inline const FCDEffectCode* GetCode(size_t index) const { FUAssert(index < GetCodeCount(), return NULL); return codes.at(index); }
    00135     inline FCDEffectCode* FindCode(const char* sid) { return const_cast<FCDEffectCode*>(const_cast<const FCDEffectProfileFX*>(this)->FindCode(sid)); }
    00136     const FCDEffectCode* FindCode(const char* sid) const;
    00140     FCDEffectCode* AddCode();
    00141
    00147     virtual FCDEffectProfile* Clone(FCDEffectProfile* clone = NULL) const;
    00148
    00153     DEPRECATED(3.05A, not recommended) void Flatten() {}
    00154 };
    00155
    00156 #endif // _FCD_EFFECT_PROFILE_H_