XSIImageFX.h

00001 //***************************************************************************************
00002 //
00003 // File supervisor: Crosswalk team
00004 //
00005 // Copyright 2008 Autodesk, Inc.  All rights reserved.
00006 // Use of this software is subject to the terms of the Autodesk license agreement
00007 // provided at the time of installation or download, or which otherwise accompanies
00008 // this software in either electronic or hard copy form.
00009 //
00010 //***************************************************************************************
00011 
00012 #ifndef _XSIIMAGEFX_H
00013 #define _XSIIMAGEFX_H
00014 
00015 #include "Template.h"
00016 class CSLImage;
00017 
00022 class XSIEXPORT CSLImageFX
00023     : public CSLTemplate
00024 {
00025 public:
00027     enum EScalingType
00028     {
00029         SI_NONE,    
00030         SI_FULL,    
00031         SI_HALF,    
00032         SI_QUARTER, 
00033         SI_128,     
00034         SI_256,     
00035         SI_512,     
00036         SI_CUSTOM,  
00037     };
00038 
00044     CSLImageFX(CSLScene* in_pScene, CSLModel *in_pModel, CdotXSITemplate* in_pTemplate);
00045 
00047     virtual ~CSLImageFX();
00048 
00052     ETemplateType Type(){ return XSI_IMAGE_FX; }
00053 
00054     virtual CSLAnimatableType* ParameterFromName(SI_Char *in_szName);
00055 
00056     virtual CSLAnimatableType* ParameterFromType(EFCurveType in_Type, SI_Char *in_szParameterName);
00057 
00061     SI_Float GetHue();
00062 
00066     SI_Void SetHue( SI_Float in_fValue );
00067 
00071     SI_Float GetGain();
00072 
00076     SI_Void SetGain( SI_Float in_fValue );
00077 
00081     SI_Float GetSaturation();
00082 
00086     SI_Void SetSaturation( SI_Float in_fValue );
00087 
00091     SI_Float GetBrightness();
00092 
00096     SI_Void SetBrightness( SI_Float in_fValue );
00097 
00101     SI_Float GetBlurRadius();
00102 
00106     SI_Void SetBlurRadius( SI_Float in_fValue );
00107 
00111     SI_Float GetBlurAmount();
00112 
00116     SI_Void SetBlurAmount( SI_Float in_fValue );
00117 
00121     SI_Bool GetBlurAlpha();
00122 
00126     SI_Void SetBlurAlpha( SI_Bool in_bValue );
00127 
00131     EScalingType GetScalingType();
00132 
00136     SI_Void SetScalingType( EScalingType in_Type );
00137 
00141     SI_Float GetHorizontalScale();
00142 
00146     SI_Void SetHorizontalScale( SI_Float in_fValue );
00147 
00151     SI_Float GetVerticalScale();
00152 
00156     SI_Void SetVerticalScale( SI_Float in_fValue );
00157 
00161     SI_Bool GetFlipHorizontal();
00162 
00166     SI_Void SetFlipHorizontal( SI_Bool in_bValue );
00167 
00171     SI_Bool GetFlipVertical();
00172 
00176     SI_Void SetFlipVertical( SI_Bool in_bValue );
00177 
00181     SI_Bool GetRGBA2Greyscale();
00182 
00186     SI_Void SetRGBA2Greyscale( SI_Bool in_bValue );
00187 
00191     SI_Bool GetConvertTo16Bits();
00192 
00196     SI_Void SetConvertTo16Bits( SI_Bool in_bValue );
00197 
00198     CSLFloatProxy*                          GetHueProxy() { return &m_Hue; };
00199     CSLFloatProxy*                          GetGainProxy() { return &m_Gain; };
00200     CSLFloatProxy*                          GetSaturationProxy() { return &m_Saturation; };
00201     CSLFloatProxy*                          GetBrightnessProxy() { return &m_Brightness; };
00202     CSLFloatProxy*                          GetBlurRadiusProxy() { return &m_BlurRadius; };
00203     CSLFloatProxy*                          GetBlurAmountProxy() { return &m_BlurAmount; };
00204     CSLBoolProxy*                           GetBlurAlphaProxy() { return &m_BlurAlpha; };
00205     CSLEnumProxy<EScalingType, SI_CUSTOM>*  GetScalingTypeProxy() { return &m_ScalingType; };
00206     CSLFloatProxy*                          GetScaleXProxy() { return &m_ScaleX; };
00207     CSLFloatProxy*                          GetScaleYProxy() { return &m_ScaleY; };
00208     CSLBoolProxy*                           GetFlipHorizontalProxy() { return &m_FlipHorizontal; };
00209     CSLBoolProxy*                           GetFlipVerticalProxy() { return &m_FlipVertical; };
00210     CSLBoolProxy*                           GetRGBA2GreyscaleProxy() { return &m_RGBA2Greyscale; };
00211     CSLBoolProxy*                           GetBitsPerChannelProxy() { return &m_BitsPerChannel; };
00212 
00213 private:
00214     CSLFloatProxy m_Hue;
00215     CSLFloatProxy m_Gain;
00216     CSLFloatProxy m_Saturation;
00217     CSLFloatProxy m_Brightness;
00218     CSLFloatProxy m_BlurRadius;
00219     CSLFloatProxy m_BlurAmount;
00220     CSLBoolProxy m_BlurAlpha;
00221     CSLEnumProxy<EScalingType, SI_CUSTOM> m_ScalingType;
00222     CSLFloatProxy m_ScaleX;
00223     CSLFloatProxy m_ScaleY;
00224     CSLBoolProxy m_FlipHorizontal;
00225     CSLBoolProxy m_FlipVertical;
00226     CSLBoolProxy m_RGBA2Greyscale;
00227     CSLBoolProxy m_BitsPerChannel;
00228 
00229     SI_Void *m_pReserved;
00230 };
00231 
00232 #endif