コード例 #1
0
 public void AddTexture(string assetName, Texture texture)
 {
     this.textureDictionary.Add(assetName, texture);
     texture.Name = assetName;
 }
コード例 #2
0
 private static DrawImageParams CreateDrawImageParams(RectangleInt source, Vector origin,
     Texture texture = null, Rectangle? destination = null, float rotation = 0.0f, Color? color = null)
 {
     var expected = new DrawImageParams
     {
         Texture = texture,
         Source = source,
         Destination = destination.HasValue ? destination.Value : Rectangle.Empty,
         Rotation = rotation,
         Origin = origin,
         Color = color.HasValue ? color.Value : Color.White,
         ImageEffect = ImageEffect.None
     };
     return expected;
 }
コード例 #3
0
 public void AddTexture(Texture texture)
 {
     this.textureDictionary.Add(texture.Name, texture);
 }