예제 #1
0
        public SpriteColors(SpriteColor c0, SpriteColor c1, SpriteColor c2, SpriteColor c3)
        {
            PreMultipliedAlpha = false;

            Color0 = c0;
            Color1 = c1;
            Color2 = c2;
            Color3 = c3;
        }
예제 #2
0
        // Lerp
        public void Lerp( SpriteColor from, SpriteColor to, float f01 )
        {
            byte f = (byte)( f01 * 255.0f );

            A = (byte)( from.A + ( ( to.A - from.A ) * f ) / 255 );
            R = (byte)( from.R + ( ( to.R - from.R ) * f ) / 255 );
            G = (byte)( from.G + ( ( to.G - from.G ) * f ) / 255 );
            B = (byte)( from.B + ( ( to.B - from.B ) * f ) / 255 );
        }
예제 #3
0
        // SpriteColors
        public SpriteColors(SpriteColor c)
        {
            PreMultipliedAlpha = false;

            Color0 = c;
            Color1 = c;
            Color2 = c;
            Color3 = c;
        }
예제 #4
0
        // Lerp
        public void Lerp(SpriteColor from, SpriteColor to, float f01)
        {
            byte f = (byte)(f01 * 255.0f);

            A = (byte)(from.A + ((to.A - from.A) * f) / 255);
            R = (byte)(from.R + ((to.R - from.R) * f) / 255);
            G = (byte)(from.G + ((to.G - from.G) * f) / 255);
            B = (byte)(from.B + ((to.B - from.B) * f) / 255);
        }
예제 #5
0
 // Init
 public void Init()
 {
     Texture.TextureIndex = 0;
     Texture.PUV = new Vector2( 0.0f );
     Texture.SUV = new Vector2( 1.0f );
     Color = 0xffffffff;
     AspectRatio = 1.0f;
     Scale = 1.0f;
     RenderState = new RenderState( (int)E_Effect.MultiTexture1, E_BlendState.AlphaBlend );
     LayerOffset = 0;
 }
예제 #6
0
        public SpriteColors( SpriteColor c0, SpriteColor c1, SpriteColor c2, SpriteColor c3 )
        {
            PreMultipliedAlpha = false;

            Color0 = c0;
            Color1 = c1;
            Color2 = c2;
            Color3 = c3;
        }
예제 #7
0
        // SpriteColors
        public SpriteColors( SpriteColor c )
        {
            PreMultipliedAlpha = false;

            Color0 = c;
            Color1 = c;
            Color2 = c;
            Color3 = c;
        }