C# Class MegaMan.Engine.Rendering.XnaRenderingContext

Inheritance: IRenderingContext
Exibir arquivo Open project: Tesserex/C--MegaMan-Engine

Public Methods

Method Description
Begin ( ) : void
CreateColorResource ( Common color ) : IResourceImage
DisableLayer ( int layer ) : void
Draw ( IResourceImage resource, int layer, MegaMan position, Rectangle sourceRect = null, bool flipHorizontal = false, bool flipVertical = false ) : void
EnableLayer ( int layer ) : void
End ( ) : void
GetOpacity ( ) : float
IsLayerEnabled ( int layer ) : bool
LoadResource ( MegaMan.Common.FilePath texturePath, string paletteName = null ) : IResourceImage
SetOpacity ( float opacity ) : void
XnaRenderingContext ( GraphicsDevice graphicsDevice ) : System

Private Methods

Method Description
AddTexture ( Microsoft.Xna.Framework.Graphics.Texture2D texture, string palette ) : IResourceImage
CreateAllLayers ( ) : void
EnableAllLayers ( ) : void
GenerateSwappedTextures ( Palette palette, Microsoft.Xna.Framework.Graphics.Texture2D image ) : List
GetTextureFromPath ( MegaMan.Common.FilePath path ) : Microsoft.Xna.Framework.Graphics.Texture2D
VerifyPaletteSwaps ( Palette palette, int id, Microsoft.Xna.Framework.Graphics.Texture2D texture ) : void

Method Details

Begin() public method

public Begin ( ) : void
return void

CreateColorResource() public method

public CreateColorResource ( Common color ) : IResourceImage
color Common
return IResourceImage

DisableLayer() public method

public DisableLayer ( int layer ) : void
layer int
return void

Draw() public method

public Draw ( IResourceImage resource, int layer, MegaMan position, Rectangle sourceRect = null, bool flipHorizontal = false, bool flipVertical = false ) : void
resource IResourceImage
layer int
position MegaMan
sourceRect MegaMan.Common.Geometry.Rectangle
flipHorizontal bool
flipVertical bool
return void

EnableLayer() public method

public EnableLayer ( int layer ) : void
layer int
return void

End() public method

public End ( ) : void
return void

GetOpacity() public method

public GetOpacity ( ) : float
return float

IsLayerEnabled() public method

public IsLayerEnabled ( int layer ) : bool
layer int
return bool

LoadResource() public method

public LoadResource ( MegaMan.Common.FilePath texturePath, string paletteName = null ) : IResourceImage
texturePath MegaMan.Common.FilePath
paletteName string
return IResourceImage

SetOpacity() public method

public SetOpacity ( float opacity ) : void
opacity float
return void

XnaRenderingContext() public method

public XnaRenderingContext ( GraphicsDevice graphicsDevice ) : System
graphicsDevice GraphicsDevice
return System