DRAW XNA TIENG ANH

8 226 0
DRAW XNA TIENG ANH

Đang tải... (xem toàn văn)

Thông tin tài liệu

DRAW XNA TIENG ANH tập hợp tất cả các lệnh draw trong xna 4.0 cho các bạn có thể hiểu tiếng anh. dùng tham khảo rất tiện dụng. ngoài ra bạn có thể tìm thêm DRAW XNA TIENG VIET có phần giải thích từng lệnh draw bằng tiếng việt.

7/17/2017 SpriteBatch.Draw Method SpriteBatch.Draw Method XNA Game Studio 4.0 Adds a sprite to a batch of sprites to be rendered Overload List Name Description SpriteBatch.Draw (Texture2D, Rectangle, Color) Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, and color SpriteBatch.Draw (Texture2D, Rectangle, Nullable, Color) Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, source rectangle, and color SpriteBatch.Draw (Texture2D, Rectangle, Nullable, Color, Single, Vector2, SpriteEffects, Single) Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, source rectangle, color, rotation, origin, effects and layer SpriteBatch.Draw (Texture2D, Vector2, Color) Adds a sprite to a batch of sprites for rendering using the specified texture, position and color SpriteBatch.Draw (Texture2D, Vector2, Nullable, Color) Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, and color SpriteBatch.Draw (Texture2D, Vector2, Nullable, Color, Single, Vector2, Single, SpriteEffects, Single) Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, color, rotation, origin, scale, effects, and layer SpriteBatch.Draw (Texture2D, Vector2, Nullable, Color, Single, Vector2, Vector2, SpriteEffects, Single) Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, color, rotation, origin, scale, effects and layer See Also Tasks https://msdn.microsoft.com/en-us/library/microsoft.xna.framework.graphics.spritebatch.draw(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Rectangle, Color) SpriteBatch.Draw Method (Texture2D, Rectangle, Color) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, and color Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Rectangle destinationRectangle, Color color ) Parameters texture A texture destinationRectangle A rectangle that specifies (in screen coordinates) the destination for drawing the sprite color The color to tint a sprite Use Color.White for full color with no tinting Exceptions Exception type Condition ArgumentNullExceptio n texture is null InvalidOperationExcep tion Draw was called, but Begin has not yet been called Begin must be called successfully before you can call Draw Remarks Before making any calls to Draw, you must call Begin Once all calls to Draw are complete, call End https://msdn.microsoft.com/en-us/library/ff433986(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Rectangle, Nullable, Color) SpriteBatch.Draw Method (Texture2D, Rectangle, Nullable, Color) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, source rectangle, and color Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Rectangle destinationRectangle, Nullable sourceRectangle, Color color ) Parameters texture A texture destinationRectangle A rectangle that specifies (in screen coordinates) the destination for drawing the sprite If this rectangle is not the same size as the source rectangle, the sprite will be scaled to fit sourceRectangle A rectangle that specifies (in texels) the source texels from a texture Use null to draw the entire texture color The color to tint a sprite Use Color.White for full color with no tinting Exceptions Exception type Condition ArgumentNullExceptio n texture is null InvalidOperationExcep tion Draw was called, but Begin has not yet been called Begin must be called successfully before you can call Draw https://msdn.microsoft.com/en-us/library/ff433987(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Rectangle, Nullable, Color, Single, Vector2, SpriteEffects, Single) SpriteBatch.Draw Method (Texture2D, Rectangle, Nullable, Color, Single, Vector2, SpriteEffects, Single) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, destination rectangle, source rectangle, color, rotation, origin, effects and layer Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Rectangle destinationRectangle, Nullable sourceRectangle, Color color, float rotation, Vector2 origin, SpriteEffects effects, float layerDepth ) Parameters texture A texture destinationRectangle A rectangle that specifies (in screen coordinates) the destination for drawing the sprite If this rectangle is not the same size as the source rectangle, the sprite will be scaled to fit sourceRectangle A rectangle that specifies (in texels) the source texels from a texture Use null to draw the entire texture color The color to tint a sprite Use Color.White for full color with no tinting rotation Specifies the angle (in radians) to rotate the sprite about its center origin The sprite origin; the default is (0,0) which represents the upper-left corner effects Effects to apply layerDepth The depth of a layer By default, represents the front layer and represents a back layer Use SpriteSortMode if you want sprites to be sorted during drawing https://msdn.microsoft.com/en-us/library/ff433992(d=printer,v=xnagamestudio.40).aspx 1/3 7/17/2017 SpriteBatch.Draw Method (Texture2D, Vector2, Color) SpriteBatch.Draw Method (Texture2D, Vector2, Color) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, position and color Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Vector2 position, Color color ) Parameters texture A texture position The location (in screen coordinates) to draw the sprite color The color to tint a sprite Use Color.White for full color with no tinting Exceptions Exception type Condition ArgumentNullExceptio n texture is null InvalidOperationExcep tion Draw was called, but Begin has not yet been called Begin must be called successfully before you can call Draw Remarks Before making any calls to Draw, you must call Begin Once all calls to Draw are complete, call End https://msdn.microsoft.com/en-us/library/ff433991(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color) SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, and color Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Vector2 position, Nullable sourceRectangle, Color color ) Parameters texture A texture position The location (in screen coordinates) to draw the sprite sourceRectangle A rectangle that specifies (in texels) the source texels from a texture Use null to draw the entire texture color The color to tint a sprite Use Color.White for full color with no tinting Exceptions Exception type Condition ArgumentNullExceptio n texture is null InvalidOperationExcep tion Draw was called, but Begin has not yet been called Begin must be called successfully before you can call Draw Remarks https://msdn.microsoft.com/en-us/library/ff433990(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color, Single, Vector2, Single, SpriteEffects, Single) SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color, Single, Vector2, Single, SpriteEffects, Single) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, color, rotation, origin, scale, effects, and layer Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Vector2 position, Nullable sourceRectangle, Color color, float rotation, Vector2 origin, float scale, SpriteEffects effects, float layerDepth ) Parameters texture A texture position The location (in screen coordinates) to draw the sprite sourceRectangle A rectangle that specifies (in texels) the source texels from a texture Use null to draw the entire texture color The color to tint a sprite Use Color.White for full color with no tinting rotation Specifies the angle (in radians) to rotate the sprite about its center origin The sprite origin; the default is (0,0) which represents the upper-left corner scale Scale factor effects Effects to apply layerDepth The depth of a layer By default, represents the front layer and represents a back layer Use SpriteSortMode if you want sprites to be sorted during drawing https://msdn.microsoft.com/en-us/library/ff433988(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color, Single, Vector2, Vector2, SpriteEffects, Single) SpriteBatch.Draw Method (Texture2D, Vector2, Nullable, Color, Single, Vector2, Vector2, SpriteEffects, Single) XNA Game Studio 4.0 Adds a sprite to a batch of sprites for rendering using the specified texture, position, source rectangle, color, rotation, origin, scale, effects and layer Namespace: Microsoft.Xna.Framework.Graphics Assembly: Microsoft.Xna.Framework.Graphics (in microsoft.xna.framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Vector2 position, Nullable sourceRectangle, Color color, float rotation, Vector2 origin, Vector2 scale, SpriteEffects effects, float layerDepth ) Parameters texture A texture position The location (in screen coordinates) to draw the sprite sourceRectangle A rectangle that specifies (in texels) the source texels from a texture Use null to draw the entire texture color The color to tint a sprite Use Color.White for full color with no tinting rotation Specifies the angle (in radians) to rotate the sprite about its center origin The sprite origin; the default is (0,0) which represents the upper-left corner scale Scale factor effects Effects to apply layerDepth The depth of a layer By default, represents the front layer and represents a back layer Use SpriteSortMode if you want sprites to be sorted during drawing https://msdn.microsoft.com/en-us/library/ff433989(d=printer,v=xnagamestudio.40).aspx 1/2 ... and color Namespace: Microsoft .Xna. Framework.Graphics Assembly: Microsoft .Xna. Framework.Graphics (in microsoft .xna. framework.graphics.dll) Syntax C# public void Draw ( Texture2D texture, Rectangle... tion Draw was called, but Begin has not yet been called Begin must be called successfully before you can call Draw Remarks Before making any calls to Draw, you must call Begin Once all calls to Draw. .. https://msdn.microsoft.com/en-us/library/ff433986(d=printer,v=xnagamestudio.40).aspx 1/2 7/17/2017 SpriteBatch .Draw Method (Texture2D, Rectangle, Nullable, Color) SpriteBatch .Draw Method (Texture2D, Rectangle, Nullable, Color) XNA

Ngày đăng: 19/07/2017, 13:41

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan