Engines/FlatRedBallXNA/FlatRedBall/Graphics/GenericEffect.cs
/// <summary>
/// Sets the parameters for the skinned effect
/// </summary>
Sets the parameters for the skinned effect
Sets the parameters for the skinned effect
private void SetSkinningEffectParameters()
        {
#if !MONOGAME
            mSkinnedEffect.World              = this.World;
            mSkinnedEffect.View               = this.View;
            mSkinnedEffect.Projection         = this.Projection;
            if (this.LightingEnabled)
            {
                mSkinnedEffect.DirectionalLight0.DiffuseColor     = this.DirectionalLight0.DiffuseColor;
                mSkinnedEffect.DirectionalLight0.Direction        = this.DirectionalLight0.Direction;
                mSkinnedEffect.DirectionalLight0.Enabled          = this.DirectionalLight0.Enabled;
                mSkinnedEffect.DirectionalLight0.SpecularColor    = this.DirectionalLight0.SpecularColor;
                mSkinnedEffect.DirectionalLight1.DiffuseColor     = this.DirectionalLight1.DiffuseColor;
                mSkinnedEffect.DirectionalLight1.Direction        = this.DirectionalLight1.Direction;
                mSkinnedEffect.DirectionalLight1.Enabled          = this.DirectionalLight1.Enabled;
                mSkinnedEffect.DirectionalLight1.SpecularColor    = this.DirectionalLight1.SpecularColor;
                mSkinnedEffect.DirectionalLight2.DiffuseColor     = this.DirectionalLight2.DiffuseColor;
                mSkinnedEffect.DirectionalLight2.Direction        = this.DirectionalLight2.Direction;
                mSkinnedEffect.DirectionalLight2.Enabled          = this.DirectionalLight2.Enabled;
                mSkinnedEffect.DirectionalLight2.SpecularColor    = this.DirectionalLight2.SpecularColor;
            }
            mSkinnedEffect.DiffuseColor       = this.DiffuseColor;
            mSkinnedEffect.AmbientLightColor  = this.AmbientLightColor;
            mSkinnedEffect.FogColor           = this.FogColor;
            mSkinnedEffect.FogEnabled         = this.FogEnabled;
            mSkinnedEffect.FogStart           = this.FogStart;
            mSkinnedEffect.FogEnd             = this.FogEnd;
            mSkinnedEffect.SpecularColor      = this.SpecularColor;
            mSkinnedEffect.SpecularPower      = this.SpecularPower;
            mSkinnedEffect.Alpha              = this.Alpha;
            mSkinnedEffect.Texture            = this.Texture;
            mSkinnedEffect.PreferPerPixelLighting = this.PreferPerPixelLighting;
            mSkinnedEffect.EmissiveColor      = this.EmissiveColor;
            mSkinnedEffect.WeightsPerVertex   = this.WeightsPerVertex;
            mSkinnedEffect.SetBoneTransforms( mBoneTransforms );
#endif
        }
private void SetSkinningEffectParameters ( ) { if ! MONOGAME mSkinnedEffect . World = this . World ; mSkinnedEffect . View = this . View ; mSkinnedEffect . Projection = this . Projection ; if ( this . LightingEnabled ) { mSkinnedEffect . DirectionalLight0 . DiffuseColor = this . DirectionalLight0 . DiffuseColor ; mSkinnedEffect . DirectionalLight0 . Direction = this . DirectionalLight0 . Direction ; mSkinnedEffect . DirectionalLight0 . Enabled = this . DirectionalLight0 . Enabled ; mSkinnedEffect . DirectionalLight0 . SpecularColor = this . DirectionalLight0 . SpecularColor ; mSkinnedEffect . DirectionalLight1 . DiffuseColor = this . DirectionalLight1 . DiffuseColor ; mSkinnedEffect . DirectionalLight1 . Direction = this . DirectionalLight1 . Direction ; mSkinnedEffect . DirectionalLight1 . Enabled = this . DirectionalLight1 . Enabled ; mSkinnedEffect . DirectionalLight1 . SpecularColor = this . DirectionalLight1 . SpecularColor ; mSkinnedEffect . DirectionalLight2 . DiffuseColor = this . DirectionalLight2 . DiffuseColor ; mSkinnedEffect . DirectionalLight2 . Direction = this . DirectionalLight2 . Direction ; mSkinnedEffect . DirectionalLight2 . Enabled = this . DirectionalLight2 . Enabled ; mSkinnedEffect . DirectionalLight2 . SpecularColor = this . DirectionalLight2 . SpecularColor ; } mSkinnedEffect . DiffuseColor = this . DiffuseColor ; mSkinnedEffect . AmbientLightColor = this . AmbientLightColor ; mSkinnedEffect . FogColor = this . FogColor ; mSkinnedEffect . FogEnabled = this . FogEnabled ; mSkinnedEffect . FogStart = this . FogStart ; mSkinnedEffect . FogEnd = this . FogEnd ; mSkinnedEffect . SpecularColor = this . SpecularColor ; mSkinnedEffect . SpecularPower = this . SpecularPower ; mSkinnedEffect . Alpha = this . Alpha ; mSkinnedEffect . Texture = this . Texture ; mSkinnedEffect . PreferPerPixelLighting = this . PreferPerPixelLighting ; mSkinnedEffect . EmissiveColor = this . EmissiveColor ; mSkinnedEffect . WeightsPerVertex = this . WeightsPerVertex ; mSkinnedEffect . SetBoneTransforms ( mBoneTransforms ) ; endif }
Sets the parameters for the skinned effect
Sets the parameters for the skinned effect