mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-05-28 17:16:29 +03:00
Changed some enum names.
This commit is contained in:
@@ -67,7 +67,7 @@ class EE_API cGameObject {
|
||||
Uint32 mFlags;
|
||||
cLayer * mLayer;
|
||||
|
||||
virtual EE_RENDERTYPE RenderTypeFromFlags();
|
||||
virtual EE_RENDER_MODE RenderTypeFromFlags();
|
||||
|
||||
void AutoFixTilePos();
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace EE { namespace Gaming {
|
||||
|
||||
class EE_API cGameObjectSubTextureEx : public cGameObjectSubTexture {
|
||||
public:
|
||||
cGameObjectSubTextureEx( const Uint32& Flags, cLayer * Layer, cSubTexture * SubTexture = NULL, const eeVector2f& Pos = eeVector2f(), EE_BLEND_MODE Blend = ALPHA_NORMAL, EE_RENDERTYPE Render = RN_NORMAL, eeFloat Angle = 0.f, eeFloat Scale = 1.f, eeColorA Color = eeColorA() );
|
||||
cGameObjectSubTextureEx( const Uint32& Flags, cLayer * Layer, cSubTexture * SubTexture = NULL, const eeVector2f& Pos = eeVector2f(), EE_BLEND_MODE Blend = ALPHA_NORMAL, EE_RENDER_MODE Render = RN_NORMAL, eeFloat Angle = 0.f, eeFloat Scale = 1.f, eeColorA Color = eeColorA() );
|
||||
|
||||
virtual ~cGameObjectSubTextureEx();
|
||||
|
||||
@@ -21,7 +21,7 @@ class EE_API cGameObjectSubTextureEx : public cGameObjectSubTexture {
|
||||
virtual void FlagSet( const Uint32& Flag );
|
||||
protected:
|
||||
EE_BLEND_MODE mBlend;
|
||||
EE_RENDERTYPE mRender;
|
||||
EE_RENDER_MODE mRender;
|
||||
eeFloat mAngle;
|
||||
eeFloat mScale;
|
||||
eeColorA mColor;
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
#ifndef EE_GRAPHICS_BLENDMODE_HPP
|
||||
#define EE_GRAPHICS_BLENDMODE_HPP
|
||||
|
||||
#include <eepp/declares.hpp>
|
||||
#include <eepp/graphics/renders.hpp>
|
||||
|
||||
namespace EE { namespace Graphics {
|
||||
|
||||
class BlendMode {
|
||||
class EE_API BlendMode {
|
||||
public:
|
||||
/** Set a blend function.
|
||||
* @param SrcFactor Source Factor
|
||||
|
||||
@@ -8,9 +8,6 @@
|
||||
|
||||
namespace EE { namespace Graphics {
|
||||
|
||||
#define FONT_TYPE_TTF (1)
|
||||
#define FONT_TYPE_TEX (2)
|
||||
|
||||
/** @brief Font interface class. */
|
||||
class EE_API cFont {
|
||||
public:
|
||||
|
||||
@@ -136,10 +136,10 @@ class EE_API cSprite {
|
||||
const eeUint& CurrentSubFrame() const;
|
||||
|
||||
/** Set the Render Type */
|
||||
void RenderType( const EE_RENDERTYPE& Effect );
|
||||
void RenderType( const EE_RENDER_MODE& Effect );
|
||||
|
||||
/** Get the Render Type */
|
||||
const EE_RENDERTYPE& RenderType() const;
|
||||
const EE_RENDER_MODE& RenderType() const;
|
||||
|
||||
/** Set the Blend Mode */
|
||||
void BlendMode( const EE_BLEND_MODE& Blend );
|
||||
@@ -250,7 +250,7 @@ class EE_API cSprite {
|
||||
* @param Blend The Blend Mode
|
||||
* @param Effect The Render Type
|
||||
*/
|
||||
void Draw( const EE_BLEND_MODE& Blend, const EE_RENDERTYPE& Effect );
|
||||
void Draw( const EE_BLEND_MODE& Blend, const EE_RENDER_MODE& Effect );
|
||||
|
||||
/** Draw the sprite to the screen forcing the Blend Mode
|
||||
* @param Blend The Blend Mode
|
||||
@@ -260,7 +260,7 @@ class EE_API cSprite {
|
||||
/** Draw the sprite to the screen forcing the Render Type
|
||||
* @param Effect The Render Type
|
||||
*/
|
||||
void Draw( const EE_RENDERTYPE& Effect );
|
||||
void Draw( const EE_RENDER_MODE& Effect );
|
||||
|
||||
/** Set the number of repeations of the animation. Any number below 0 the animation will loop. */
|
||||
void SetRepeations( const int& Repeations );
|
||||
@@ -362,7 +362,7 @@ class EE_API cSprite {
|
||||
eeInt mRepeations; //!< Number of repetions of the animation, default -1 that equals to loop.
|
||||
|
||||
EE_BLEND_MODE mBlend;
|
||||
EE_RENDERTYPE mEffect;
|
||||
EE_RENDER_MODE mEffect;
|
||||
|
||||
eeUint mCurrentFrame;
|
||||
eeFloat mfCurrentFrame;
|
||||
|
||||
@@ -51,9 +51,9 @@ class EE_API cSubTexture {
|
||||
|
||||
void OffsetY( const Int32& offsety );
|
||||
|
||||
void Draw( const eeFloat& X, const eeFloat& Y, const eeColorA& Color = eeColorA(), const eeFloat& Angle = 0.f, const eeFloat& Scale = 1.f, const EE_BLEND_MODE& Blend = ALPHA_NORMAL, const EE_RENDERTYPE& Effect = RN_NORMAL, const bool& ScaleRendered = true );
|
||||
void Draw( const eeFloat& X, const eeFloat& Y, const eeColorA& Color = eeColorA(), const eeFloat& Angle = 0.f, const eeFloat& Scale = 1.f, const EE_BLEND_MODE& Blend = ALPHA_NORMAL, const EE_RENDER_MODE& Effect = RN_NORMAL, const bool& ScaleRendered = true );
|
||||
|
||||
void Draw( const eeFloat& X, const eeFloat& Y, const eeFloat& Angle, const eeFloat& Scale, const eeColorA& Color0 = eeColorA(), const eeColorA& Color1 = eeColorA(), const eeColorA& Color2 = eeColorA(), const eeColorA& Color3 = eeColorA(), const EE_BLEND_MODE& Blend = ALPHA_NORMAL, const EE_RENDERTYPE& Effect = RN_NORMAL, const bool& ScaleRendered = true );
|
||||
void Draw( const eeFloat& X, const eeFloat& Y, const eeFloat& Angle, const eeFloat& Scale, const eeColorA& Color0 = eeColorA(), const eeColorA& Color1 = eeColorA(), const eeColorA& Color2 = eeColorA(), const eeColorA& Color3 = eeColorA(), const EE_BLEND_MODE& Blend = ALPHA_NORMAL, const EE_RENDER_MODE& Effect = RN_NORMAL, const bool& ScaleRendered = true );
|
||||
|
||||
void Draw( const eeQuad2f Q, const eeFloat& X, const eeFloat& Y, const eeFloat& Angle = 0.f, const eeFloat& Scale = 1.f, const eeColorA& Color0 = eeColorA(), const eeColorA& Color1 = eeColorA(), const eeColorA& Color2 = eeColorA(), const eeColorA& Color3 = eeColorA(), const EE_BLEND_MODE& Blend = ALPHA_NORMAL );
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@ class EE_API cTexture : public cImage {
|
||||
* @param ScaleCentered If true the texture will be scaled centered, otherwise will be scale from the Top - Left Corner
|
||||
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
|
||||
*/
|
||||
void Draw( const eeFloat &x, const eeFloat &y, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDERTYPE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
void Draw( const eeFloat &x, const eeFloat &y, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
|
||||
/** Render the texture on screen. Extended because can set the vertex colors individually
|
||||
* @param x The x position on screen
|
||||
@@ -144,7 +144,7 @@ class EE_API cTexture : public cImage {
|
||||
* @param ScaleCentered If true the texture will be scaled centered, otherwise will be scale from the Top - Left Corner
|
||||
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
|
||||
*/
|
||||
void DrawEx( const eeFloat &x, const eeFloat &y, const eeFloat &width = 0.0f, const eeFloat &height = 0.0f, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color0 = eeColorA(255,255,255,255), const eeColorA& Color1 = eeColorA(255,255,255,255), const eeColorA& Color2 = eeColorA(255,255,255,255), const eeColorA& Color3 = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDERTYPE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
void DrawEx( const eeFloat &x, const eeFloat &y, const eeFloat &width = 0.0f, const eeFloat &height = 0.0f, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color0 = eeColorA(255,255,255,255), const eeColorA& Color1 = eeColorA(255,255,255,255), const eeColorA& Color2 = eeColorA(255,255,255,255), const eeColorA& Color3 = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
|
||||
/** Render the texture on screen
|
||||
* @param x The x position on screen
|
||||
@@ -159,7 +159,7 @@ class EE_API cTexture : public cImage {
|
||||
* @param ScaleCentered If true the texture will be scaled centered, otherwise will be scale from the Top - Left Corner
|
||||
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
|
||||
*/
|
||||
void DrawEx2( const eeFloat &x, const eeFloat &y, const eeFloat &width = 0.0f, const eeFloat &height = 0.0f, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDERTYPE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
void DrawEx2( const eeFloat &x, const eeFloat &y, const eeFloat &width = 0.0f, const eeFloat &height = 0.0f, const eeFloat &Angle = 0, const eeFloat &Scale = 1.0f, const eeColorA& Color = eeColorA(255,255,255,255), const EE_BLEND_MODE &blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, const bool &ScaleCentered = true, const eeRecti& texSector = eeRecti(0,0,0,0) );
|
||||
|
||||
/** Render a GL_QUAD on Screen
|
||||
* @param Q The eeQuad2f
|
||||
|
||||
@@ -30,7 +30,7 @@ class EE_API cTTFFont : public cFont {
|
||||
* @param OutlineColor The Outline Color
|
||||
* @return If success
|
||||
*/
|
||||
bool Load( const std::string& Filepath, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
bool Load( const std::string& Filepath, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
/** Load Font from pack
|
||||
* @param Pack Pointer to the pack instance
|
||||
@@ -44,7 +44,7 @@ class EE_API cTTFFont : public cFont {
|
||||
* @param OutlineColor The Outline Color
|
||||
* @return If success
|
||||
*/
|
||||
bool LoadFromPack( cPack* Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
bool LoadFromPack( cPack* Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
/** Load a True Type Font from memory
|
||||
* @param TTFData The pointer to the data
|
||||
@@ -58,7 +58,7 @@ class EE_API cTTFFont : public cFont {
|
||||
* @param OutlineColor The Outline Color
|
||||
* @return If success
|
||||
*/
|
||||
bool LoadFromMemory( Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
bool LoadFromMemory( Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
/** Save the texture generated from the TTF file to disk */
|
||||
bool SaveTexture( const std::string& Filepath, const EE_SAVE_TYPE& Format = EE_SAVE_TYPE_PNG );
|
||||
@@ -82,7 +82,7 @@ class EE_API cTTFFont : public cFont {
|
||||
eeColor mFontColor;
|
||||
eeColor mOutlineColor;
|
||||
|
||||
EE_TTF_FONTSTYLE mStyle;
|
||||
EE_TTF_FONT_STYLE mStyle;
|
||||
|
||||
eeFloat mTexWidth;
|
||||
eeFloat mTexHeight;
|
||||
@@ -97,7 +97,7 @@ class EE_API cTTFFont : public cFont {
|
||||
|
||||
void UpdateLoading();
|
||||
|
||||
bool iLoad( const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, Uint8 OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator );
|
||||
bool iLoad( const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, Uint8 OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator );
|
||||
|
||||
void MakeOutline( Uint8 *in, Uint8 *out, Int16 w, Int16 h);
|
||||
|
||||
|
||||
@@ -14,11 +14,11 @@ namespace EE { namespace Graphics {
|
||||
|
||||
class EE_API cTTFFontLoader : public cObjectLoader {
|
||||
public:
|
||||
cTTFFontLoader( const std::string& FontName, const std::string& Filepath, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
cTTFFontLoader( const std::string& FontName, const std::string& Filepath, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
cTTFFontLoader( const std::string& FontName, cPack * Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
cTTFFontLoader( const std::string& FontName, cPack * Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
cTTFFontLoader( const std::string& FontName, Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONTSTYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
cTTFFontLoader( const std::string& FontName, Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONT_STYLE Style = EE_TTF_STYLE_NORMAL, const bool& VerticalDraw = false, const Uint16& NumCharsToGen = 512, const eeColor& FontColor = eeColor(), const Uint8& OutlineSize = 0, const eeColor& OutlineColor = eeColor(0,0,0), const bool& AddPixelSeparator = true );
|
||||
|
||||
~cTTFFontLoader();
|
||||
|
||||
@@ -37,7 +37,7 @@ class EE_API cTTFFontLoader : public cObjectLoader {
|
||||
std::string mFontName;
|
||||
std::string mFilepath;
|
||||
eeUint mSize;
|
||||
EE_TTF_FONTSTYLE mStyle;
|
||||
EE_TTF_FONT_STYLE mStyle;
|
||||
bool mVerticalDraw;
|
||||
Uint16 mNumCharsToGen;
|
||||
eeColor mFontColor;
|
||||
|
||||
@@ -3,24 +3,29 @@
|
||||
|
||||
namespace EE { namespace Graphics {
|
||||
|
||||
enum FONT_HALIGN {
|
||||
enum EE_FONT_TYPE {
|
||||
FONT_TYPE_TTF = 1,
|
||||
FONT_TYPE_TEX = 2
|
||||
};
|
||||
|
||||
enum EE_FONT_HALIGN {
|
||||
FONT_DRAW_LEFT = (0 << 0),
|
||||
FONT_DRAW_RIGHT = (1 << 0),
|
||||
FONT_DRAW_CENTER = (2 << 0),
|
||||
FONT_DRAW_HALIGN_MASK = (3 << 0)
|
||||
};
|
||||
|
||||
inline Uint32 FontHAlignGet( Uint32 Flags ) {
|
||||
return Flags & FONT_DRAW_HALIGN_MASK;
|
||||
}
|
||||
|
||||
enum FONT_VALIGN {
|
||||
enum EE_FONT_VALIGN {
|
||||
FONT_DRAW_TOP = (0 << 2),
|
||||
FONT_DRAW_BOTTOM = (1 << 2),
|
||||
FONT_DRAW_MIDDLE = (2 << 2),
|
||||
FONT_DRAW_VALIGN_MASK = (3 << 2)
|
||||
};
|
||||
|
||||
inline Uint32 FontHAlignGet( Uint32 Flags ) {
|
||||
return Flags & FONT_DRAW_HALIGN_MASK;
|
||||
}
|
||||
|
||||
inline Uint32 FontVAlignGet( Uint32 Flags ) {
|
||||
return Flags & FONT_DRAW_VALIGN_MASK;
|
||||
}
|
||||
|
||||
@@ -30,8 +30,8 @@ enum EE_BLEND_MODE {
|
||||
ALPHA_CUSTOM //!< Disable the Predefined blend mode for the use of custom blend funcs.
|
||||
};
|
||||
|
||||
/** @enum EE_RENDERTYPE Defines the method to use to render a texture. */
|
||||
enum EE_RENDERTYPE {
|
||||
/** @enum EE_RENDER_MODE Defines the method to use to render a texture. */
|
||||
enum EE_RENDER_MODE {
|
||||
RN_NORMAL = 0, //!< Render the texture without any change
|
||||
RN_MIRROR = 1, //!< Render the texture mirrored
|
||||
RN_FLIP = 2, //!< Render the texture fliped
|
||||
@@ -50,8 +50,8 @@ enum EE_SAVE_TYPE {
|
||||
EE_SAVE_TYPE_DDS = 3
|
||||
};
|
||||
|
||||
/** @enum EE_TTF_FONTSTYLE Set the TTF Font style. */
|
||||
enum EE_TTF_FONTSTYLE {
|
||||
/** @enum EE_TTF_FONT_STYLE Set the TTF Font style. */
|
||||
enum EE_TTF_FONT_STYLE {
|
||||
EE_TTF_STYLE_NORMAL = 0,
|
||||
EE_TTF_STYLE_BOLD = 1,
|
||||
EE_TTF_STYLE_ITALIC = 2,
|
||||
|
||||
@@ -21,7 +21,7 @@ class EE_API cUIGfx : public cUIComplexControl {
|
||||
|
||||
cSubTexture * SubTexture;
|
||||
eeColorA SubTextureColor;
|
||||
EE_RENDERTYPE SubTextureRender;
|
||||
EE_RENDER_MODE SubTextureRender;
|
||||
};
|
||||
|
||||
cUIGfx( const cUIGfx::CreateParams& Params );
|
||||
@@ -44,15 +44,15 @@ class EE_API cUIGfx : public cUIComplexControl {
|
||||
|
||||
void Color( const eeColorA& color );
|
||||
|
||||
const EE_RENDERTYPE& RenderType() const;
|
||||
const EE_RENDER_MODE& RenderType() const;
|
||||
|
||||
void RenderType( const EE_RENDERTYPE& render );
|
||||
void RenderType( const EE_RENDER_MODE& render );
|
||||
|
||||
const eeVector2i& AlignOffset() const;
|
||||
protected:
|
||||
cSubTexture * mSubTexture;
|
||||
eeColorA mColor;
|
||||
EE_RENDERTYPE mRender;
|
||||
EE_RENDER_MODE mRender;
|
||||
eeVector2i mAlignOffset;
|
||||
|
||||
virtual void OnSizeChange();
|
||||
|
||||
@@ -20,7 +20,7 @@ class EE_API cUISprite : public cUIComplexControl {
|
||||
inline ~CreateParams() {}
|
||||
|
||||
cSprite * Sprite;
|
||||
EE_RENDERTYPE SpriteRender;
|
||||
EE_RENDER_MODE SpriteRender;
|
||||
bool DeallocSprite;
|
||||
};
|
||||
|
||||
@@ -44,14 +44,14 @@ class EE_API cUISprite : public cUIComplexControl {
|
||||
|
||||
void Color( const eeColorA& color );
|
||||
|
||||
const EE_RENDERTYPE& RenderType() const;
|
||||
const EE_RENDER_MODE& RenderType() const;
|
||||
|
||||
void RenderType( const EE_RENDERTYPE& render );
|
||||
void RenderType( const EE_RENDER_MODE& render );
|
||||
|
||||
const eeVector2i& AlignOffset() const;
|
||||
protected:
|
||||
cSprite * mSprite;
|
||||
EE_RENDERTYPE mRender;
|
||||
EE_RENDER_MODE mRender;
|
||||
eeVector2i mAlignOffset;
|
||||
cSubTexture * mSubTextureLast;
|
||||
bool mDealloc;
|
||||
|
||||
@@ -90,9 +90,9 @@ class EE_API cUITheme : public tResourceManager<cUISkin> {
|
||||
|
||||
cSubTexture * GetIconByName( const std::string& name );
|
||||
|
||||
virtual cUIGfx * CreateGfx( cSubTexture * SubTexture, cUIControl * Parent = NULL, const eeSize& Size = eeSize(), const eeVector2i& Pos = eeVector2i(), const Uint32& Flags = UI_CONTROL_DEFAULT_FLAGS_CENTERED | UI_AUTO_SIZE, eeColorA SubTextureColor = eeColorA(255,255,255,255), EE_RENDERTYPE SubTextureRender = RN_NORMAL );
|
||||
virtual cUIGfx * CreateGfx( cSubTexture * SubTexture, cUIControl * Parent = NULL, const eeSize& Size = eeSize(), const eeVector2i& Pos = eeVector2i(), const Uint32& Flags = UI_CONTROL_DEFAULT_FLAGS_CENTERED | UI_AUTO_SIZE, eeColorA SubTextureColor = eeColorA(255,255,255,255), EE_RENDER_MODE SubTextureRender = RN_NORMAL );
|
||||
|
||||
virtual cUISprite * CreateSprite( cSprite * Sprite, cUIControl * Parent = NULL, const eeSize& Size = eeSize(), const eeVector2i& Pos = eeVector2i(), const Uint32& Flags = UI_CONTROL_DEFAULT_FLAGS_CENTERED | UI_AUTO_SIZE, bool DeallocSprite = true, EE_RENDERTYPE SpriteRender = RN_NORMAL );
|
||||
virtual cUISprite * CreateSprite( cSprite * Sprite, cUIControl * Parent = NULL, const eeSize& Size = eeSize(), const eeVector2i& Pos = eeVector2i(), const Uint32& Flags = UI_CONTROL_DEFAULT_FLAGS_CENTERED | UI_AUTO_SIZE, bool DeallocSprite = true, EE_RENDER_MODE SpriteRender = RN_NORMAL );
|
||||
|
||||
virtual cUICheckBox * CreateCheckBox( cUIControl * Parent = NULL, const eeSize& Size = eeSize(), const eeVector2i& Pos = eeVector2i(), const Uint32& Flags = UI_CONTROL_DEFAULT_FLAGS );
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE QtCreatorProject>
|
||||
<!-- Written by Qt Creator 2.6.0, 2012-12-03T17:50:23. -->
|
||||
<!-- Written by Qt Creator 2.6.0, 2012-12-04T15:52:52. -->
|
||||
<qtcreator>
|
||||
<data>
|
||||
<variable>ProjectExplorer.Project.ActiveTarget</variable>
|
||||
|
||||
@@ -105,8 +105,8 @@ Uint32 cGameObject::DataId() {
|
||||
void cGameObject::DataId( Uint32 Id ){
|
||||
}
|
||||
|
||||
EE_RENDERTYPE cGameObject::RenderTypeFromFlags() {
|
||||
EE_RENDERTYPE Render = RN_NORMAL;
|
||||
EE_RENDER_MODE cGameObject::RenderTypeFromFlags() {
|
||||
EE_RENDER_MODE Render = RN_NORMAL;
|
||||
|
||||
if ( ( mFlags & GObjFlags::GAMEOBJECT_MIRRORED ) && ( mFlags & GObjFlags::GAMEOBJECT_FLIPED ) ) {
|
||||
Render = RN_FLIPMIRROR;
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
namespace EE { namespace Gaming {
|
||||
|
||||
cGameObjectSubTextureEx::cGameObjectSubTextureEx( const Uint32& Flags, cLayer * Layer, cSubTexture * SubTexture, const eeVector2f& Pos, EE_BLEND_MODE Blend, EE_RENDERTYPE Render, eeFloat Angle, eeFloat Scale, eeColorA Color ) :
|
||||
cGameObjectSubTextureEx::cGameObjectSubTextureEx( const Uint32& Flags, cLayer * Layer, cSubTexture * SubTexture, const eeVector2f& Pos, EE_BLEND_MODE Blend, EE_RENDER_MODE Render, eeFloat Angle, eeFloat Scale, eeColorA Color ) :
|
||||
cGameObjectSubTexture( Flags, Layer, SubTexture, Pos ),
|
||||
mBlend( Blend ),
|
||||
mRender( Render ),
|
||||
|
||||
@@ -526,7 +526,7 @@ void cSprite::SetReverseFromStart() {
|
||||
mCurrentFrame = Size;
|
||||
}
|
||||
|
||||
void cSprite::Draw( const EE_BLEND_MODE& Blend, const EE_RENDERTYPE& Effect ) {
|
||||
void cSprite::Draw( const EE_BLEND_MODE& Blend, const EE_RENDER_MODE& Effect ) {
|
||||
if ( SPR_FGET( SPRITE_FLAG_AUTO_ANIM ) )
|
||||
Update();
|
||||
|
||||
@@ -549,7 +549,7 @@ void cSprite::Draw( const EE_BLEND_MODE& Blend ) {
|
||||
Draw( Blend, mEffect );
|
||||
}
|
||||
|
||||
void cSprite::Draw( const EE_RENDERTYPE& Effect ) {
|
||||
void cSprite::Draw( const EE_RENDER_MODE& Effect ) {
|
||||
Draw( mBlend, Effect );
|
||||
}
|
||||
|
||||
@@ -852,11 +852,11 @@ const eeUint& cSprite::CurrentSubFrame() const {
|
||||
return mCurrentSubFrame;
|
||||
}
|
||||
|
||||
void cSprite::RenderType( const EE_RENDERTYPE& Effect ) {
|
||||
void cSprite::RenderType( const EE_RENDER_MODE& Effect ) {
|
||||
mEffect = Effect;
|
||||
}
|
||||
|
||||
const EE_RENDERTYPE& cSprite::RenderType() const {
|
||||
const EE_RENDER_MODE& cSprite::RenderType() const {
|
||||
return mEffect;
|
||||
}
|
||||
|
||||
|
||||
@@ -165,12 +165,12 @@ void cSubTexture::OffsetY( const Int32& offsety ) {
|
||||
mOffsetY = offsety;
|
||||
}
|
||||
|
||||
void cSubTexture::Draw( const eeFloat& X, const eeFloat& Y, const eeColorA& Color, const eeFloat& Angle, const eeFloat& Scale, const EE_BLEND_MODE& Blend, const EE_RENDERTYPE& Effect, const bool& ScaleRendered ) {
|
||||
void cSubTexture::Draw( const eeFloat& X, const eeFloat& Y, const eeColorA& Color, const eeFloat& Angle, const eeFloat& Scale, const EE_BLEND_MODE& Blend, const EE_RENDER_MODE& Effect, const bool& ScaleRendered ) {
|
||||
if ( NULL != mTexture )
|
||||
mTexture->DrawEx( X + mOffsetX, Y + mOffsetY, mDestWidth, mDestHeight, Angle, Scale, Color, Color, Color, Color, Blend, Effect, ScaleRendered, mSrcRect );
|
||||
}
|
||||
|
||||
void cSubTexture::Draw( const eeFloat& X, const eeFloat& Y, const eeFloat& Angle, const eeFloat& Scale, const eeColorA& Color0, const eeColorA& Color1, const eeColorA& Color2, const eeColorA& Color3, const EE_BLEND_MODE& Blend, const EE_RENDERTYPE& Effect, const bool& ScaleRendered ) {
|
||||
void cSubTexture::Draw( const eeFloat& X, const eeFloat& Y, const eeFloat& Angle, const eeFloat& Scale, const eeColorA& Color0, const eeColorA& Color1, const eeColorA& Color2, const eeColorA& Color3, const EE_BLEND_MODE& Blend, const EE_RENDER_MODE& Effect, const bool& ScaleRendered ) {
|
||||
if ( NULL != mTexture )
|
||||
mTexture->DrawEx( X + mOffsetX, Y + mOffsetY, mDestWidth, mDestHeight, Angle, Scale, Color0, Color1, Color2, Color3, Blend, Effect, ScaleRendered, mSrcRect );
|
||||
}
|
||||
|
||||
@@ -411,7 +411,7 @@ bool cTexture::Compressed() const {
|
||||
return 0 != ( mFlags & TEX_FLAG_COMPRESSED );
|
||||
}
|
||||
|
||||
void cTexture::Draw( const eeFloat &x, const eeFloat &y, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color, const EE_BLEND_MODE &blend, const EE_RENDERTYPE &Effect, const bool &ScaleCentered, const eeRecti& texSector) {
|
||||
void cTexture::Draw( const eeFloat &x, const eeFloat &y, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color, const EE_BLEND_MODE &blend, const EE_RENDER_MODE &Effect, const bool &ScaleCentered, const eeRecti& texSector) {
|
||||
DrawEx( x, y, 0, 0, Angle, Scale, Color, Color, Color, Color, blend, Effect, ScaleCentered, texSector);
|
||||
}
|
||||
|
||||
@@ -436,7 +436,7 @@ void cTexture::DrawFast( const eeFloat& x, const eeFloat& y, const eeFloat& Angl
|
||||
BR->DrawOpt();
|
||||
}
|
||||
|
||||
void cTexture::DrawEx( const eeFloat &x, const eeFloat &y, const eeFloat &width, const eeFloat &height, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color0, const eeColorA& Color1, const eeColorA& Color2, const eeColorA& Color3, const EE_BLEND_MODE &blend, const EE_RENDERTYPE &Effect, const bool &ScaleCentered, const eeRecti& texSector) {
|
||||
void cTexture::DrawEx( const eeFloat &x, const eeFloat &y, const eeFloat &width, const eeFloat &height, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color0, const eeColorA& Color1, const eeColorA& Color2, const eeColorA& Color3, const EE_BLEND_MODE &blend, const EE_RENDER_MODE &Effect, const bool &ScaleCentered, const eeRecti& texSector) {
|
||||
cBatchRenderer * BR = cGlobalBatchRenderer::instance();
|
||||
|
||||
bool renderdiv = true;
|
||||
@@ -591,7 +591,7 @@ void cTexture::DrawEx( const eeFloat &x, const eeFloat &y, const eeFloat &width,
|
||||
BR->DrawOpt();
|
||||
}
|
||||
|
||||
void cTexture::DrawEx2( const eeFloat &x, const eeFloat &y, const eeFloat &width, const eeFloat &height, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color, const EE_BLEND_MODE &blend, const EE_RENDERTYPE &Effect, const bool &ScaleCentered, const eeRecti& texSector ) {
|
||||
void cTexture::DrawEx2( const eeFloat &x, const eeFloat &y, const eeFloat &width, const eeFloat &height, const eeFloat &Angle, const eeFloat &Scale, const eeColorA& Color, const EE_BLEND_MODE &blend, const EE_RENDER_MODE &Effect, const bool &ScaleCentered, const eeRecti& texSector ) {
|
||||
DrawEx( x, y, width, height, Angle, Scale, Color, Color, Color, Color, blend, Effect, ScaleCentered, texSector );
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ cTTFFont::~cTTFFont() {
|
||||
hkFontManager::instance()->Destroy();
|
||||
}
|
||||
|
||||
bool cTTFFont::LoadFromPack( cPack* Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
bool cTTFFont::LoadFromPack( cPack* Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
bool Ret = false;
|
||||
SafeDataPointer PData;
|
||||
|
||||
@@ -32,7 +32,7 @@ bool cTTFFont::LoadFromPack( cPack* Pack, const std::string& FilePackPath, const
|
||||
return Ret;
|
||||
}
|
||||
|
||||
bool cTTFFont::LoadFromMemory( Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
bool cTTFFont::LoadFromMemory( Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
if ( !mFilepath.size() )
|
||||
mFilepath = "from memory";
|
||||
|
||||
@@ -43,7 +43,7 @@ bool cTTFFont::LoadFromMemory( Uint8* TTFData, const eeUint& TTFDataSize, const
|
||||
return iLoad( Size, Style, VerticalDraw, NumCharsToGen, FontColor, OutlineSize, OutlineColor, AddPixelSeparator );
|
||||
}
|
||||
|
||||
bool cTTFFont::Load( const std::string& Filepath, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
bool cTTFFont::Load( const std::string& Filepath, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
mFilepath = Filepath;
|
||||
|
||||
if ( FileSystem::FileExists( Filepath ) ) {
|
||||
@@ -63,7 +63,7 @@ bool cTTFFont::Load( const std::string& Filepath, const eeUint& Size, EE_TTF_FON
|
||||
return false;
|
||||
}
|
||||
|
||||
bool cTTFFont::iLoad( const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, Uint8 OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
bool cTTFFont::iLoad( const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, Uint8 OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) {
|
||||
eeRect CurrentPos;
|
||||
eeSize GlyphRect;
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
namespace EE { namespace Graphics {
|
||||
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, const std::string& Filepath, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, const std::string& Filepath, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cObjectLoader( FontTTFLoader ),
|
||||
mLoadType( TTF_LT_PATH ),
|
||||
mFontName( FontName ),
|
||||
@@ -21,7 +21,7 @@ cTTFFontLoader::cTTFFontLoader( const std::string& FontName, const std::string&
|
||||
Create();
|
||||
}
|
||||
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, cPack * Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, cPack * Pack, const std::string& FilePackPath, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cObjectLoader( FontTTFLoader ),
|
||||
mLoadType( TTF_LT_PACK ),
|
||||
mFontName( FontName ),
|
||||
@@ -40,7 +40,7 @@ cTTFFontLoader::cTTFFontLoader( const std::string& FontName, cPack * Pack, const
|
||||
Create();
|
||||
}
|
||||
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONTSTYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cTTFFontLoader::cTTFFontLoader( const std::string& FontName, Uint8* TTFData, const eeUint& TTFDataSize, const eeUint& Size, EE_TTF_FONT_STYLE Style, const bool& VerticalDraw, const Uint16& NumCharsToGen, const eeColor& FontColor, const Uint8& OutlineSize, const eeColor& OutlineColor, const bool& AddPixelSeparator ) :
|
||||
cObjectLoader( FontTTFLoader ),
|
||||
mLoadType( TTF_LT_MEM ),
|
||||
mFontName( FontName ),
|
||||
|
||||
@@ -126,11 +126,11 @@ void cUIGfx::Color( const eeColorA& color ) {
|
||||
Alpha( color.A() );
|
||||
}
|
||||
|
||||
const EE_RENDERTYPE& cUIGfx::RenderType() const {
|
||||
const EE_RENDER_MODE& cUIGfx::RenderType() const {
|
||||
return mRender;
|
||||
}
|
||||
|
||||
void cUIGfx::RenderType( const EE_RENDERTYPE& render ) {
|
||||
void cUIGfx::RenderType( const EE_RENDER_MODE& render ) {
|
||||
mRender = render;
|
||||
}
|
||||
|
||||
|
||||
@@ -90,11 +90,11 @@ void cUISprite::Color( const eeColorA& color ) {
|
||||
Alpha( color.A() );
|
||||
}
|
||||
|
||||
const EE_RENDERTYPE& cUISprite::RenderType() const {
|
||||
const EE_RENDER_MODE& cUISprite::RenderType() const {
|
||||
return mRender;
|
||||
}
|
||||
|
||||
void cUISprite::RenderType( const EE_RENDERTYPE& render ) {
|
||||
void cUISprite::RenderType( const EE_RENDER_MODE& render ) {
|
||||
mRender = render;
|
||||
}
|
||||
|
||||
|
||||
@@ -417,7 +417,7 @@ cSubTexture * cUITheme::GetIconByName( const std::string& name ) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
cUIGfx * cUITheme::CreateGfx( cSubTexture * SubTexture, cUIControl * Parent, const eeSize& Size, const eeVector2i& Pos, const Uint32& Flags, eeColorA SubTextureColor, EE_RENDERTYPE SubTextureRender ) {
|
||||
cUIGfx * cUITheme::CreateGfx( cSubTexture * SubTexture, cUIControl * Parent, const eeSize& Size, const eeVector2i& Pos, const Uint32& Flags, eeColorA SubTextureColor, EE_RENDER_MODE SubTextureRender ) {
|
||||
cUIGfx::CreateParams GfxParams;
|
||||
GfxParams.Parent( Parent );
|
||||
GfxParams.PosSet( Pos );
|
||||
@@ -432,7 +432,7 @@ cUIGfx * cUITheme::CreateGfx( cSubTexture * SubTexture, cUIControl * Parent, con
|
||||
return Gfx;
|
||||
}
|
||||
|
||||
cUISprite * cUITheme::CreateSprite( cSprite * Sprite, cUIControl * Parent, const eeSize& Size, const eeVector2i& Pos, const Uint32& Flags, bool DeallocSprite, EE_RENDERTYPE SpriteRender ) {
|
||||
cUISprite * cUITheme::CreateSprite( cSprite * Sprite, cUIControl * Parent, const eeSize& Size, const eeVector2i& Pos, const Uint32& Flags, bool DeallocSprite, EE_RENDER_MODE SpriteRender ) {
|
||||
cUISprite::CreateParams SpriteParams;
|
||||
SpriteParams.Parent( Parent );
|
||||
SpriteParams.PosSet( Pos );
|
||||
|
||||
Reference in New Issue
Block a user