From 67543bea123ba831ccb8639e5bff2fed6b76be32 Mon Sep 17 00:00:00 2001 From: Absolutely disgusting Date: Wed, 29 Oct 2025 17:26:09 +0400 Subject: [PATCH] Some renamings --- 2DGAMELIB/_2DGAMELIB/Med.cs | 2 +- 2DGAMELIB/_2DGAMELIB/Oth.cs | 4 ++-- 2DGAMELIB/_2DGAMELIB/{Rect.cs => Rectangle.cs} | 6 +++--- 2DGAMELIB/_2DGAMELIB/RenderArea.cs | 2 +- 2DGAMELIB/_2DGAMELIB/Sce.cs | 4 ++-- 2DGAMELIB/_2DGAMELIB/WPFImage.cs | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) rename 2DGAMELIB/_2DGAMELIB/{Rect.cs => Rectangle.cs} (88%) diff --git a/2DGAMELIB/_2DGAMELIB/Med.cs b/2DGAMELIB/_2DGAMELIB/Med.cs index d52cdea..7f8c578 100644 --- a/2DGAMELIB/_2DGAMELIB/Med.cs +++ b/2DGAMELIB/_2DGAMELIB/Med.cs @@ -21,7 +21,7 @@ namespace _2DGAMELIB public bool ShowFPS; public bool Drive = true; - public Rect Base = new Rect(4.0, 3.0, 0.4); + public Rectangle Base = new Rectangle(4.0, 3.0, 0.4); public Bitmap Dis; public Graphics GD; diff --git a/2DGAMELIB/_2DGAMELIB/Oth.cs b/2DGAMELIB/_2DGAMELIB/Oth.cs index 40ca93a..107a664 100644 --- a/2DGAMELIB/_2DGAMELIB/Oth.cs +++ b/2DGAMELIB/_2DGAMELIB/Oth.cs @@ -43,9 +43,9 @@ namespace _2DGAMELIB return Func(new Hsv(ref Color)).GetColor(); } - public static Rectangle GetRect(this Bitmap Bmp) + public static System.Drawing.Rectangle GetRect(this Bitmap Bmp) { - return new Rectangle(0, 0, Bmp.Width, Bmp.Height); + return new System.Drawing.Rectangle(0, 0, Bmp.Width, Bmp.Height); } public static LinearGradientBrush GetLGB(double Unit, Vector2D[] MM, Color Color1, Color Color2) diff --git a/2DGAMELIB/_2DGAMELIB/Rect.cs b/2DGAMELIB/_2DGAMELIB/Rectangle.cs similarity index 88% rename from 2DGAMELIB/_2DGAMELIB/Rect.cs rename to 2DGAMELIB/_2DGAMELIB/Rectangle.cs index fba70ef..98694aa 100644 --- a/2DGAMELIB/_2DGAMELIB/Rect.cs +++ b/2DGAMELIB/_2DGAMELIB/Rectangle.cs @@ -1,6 +1,6 @@ namespace _2DGAMELIB { - public class Rect + public class Rectangle { public double XRatio = 1.0; @@ -14,9 +14,9 @@ namespace _2DGAMELIB public Vector2D LocalCenter => new Vector2D(LocalWidth * 0.5, LocalHeight * 0.5); - public Rect(){} + public Rectangle(){} - public Rect(double XRatio, double YRatio, double Size) + public Rectangle(double XRatio, double YRatio, double Size) { SetXYRatio(XRatio, YRatio); this.Size = Size; diff --git a/2DGAMELIB/_2DGAMELIB/RenderArea.cs b/2DGAMELIB/_2DGAMELIB/RenderArea.cs index d070193..6946ad3 100644 --- a/2DGAMELIB/_2DGAMELIB/RenderArea.cs +++ b/2DGAMELIB/_2DGAMELIB/RenderArea.cs @@ -5,7 +5,7 @@ using System.Drawing.Imaging; namespace _2DGAMELIB { //Render Area - public class RenderArea : Rect + public class RenderArea : Rectangle { //Display Layer public Bitmap DisplayLayer; diff --git a/2DGAMELIB/_2DGAMELIB/Sce.cs b/2DGAMELIB/_2DGAMELIB/Sce.cs index 3c8b053..58eb2bd 100644 --- a/2DGAMELIB/_2DGAMELIB/Sce.cs +++ b/2DGAMELIB/_2DGAMELIB/Sce.cs @@ -17,7 +17,7 @@ namespace _2DGAMELIB private int h; - private Rectangle r; + private System.Drawing.Rectangle r; private ColorMatrix cm = new ColorMatrix(); @@ -31,7 +31,7 @@ namespace _2DGAMELIB GS = Graphics.FromImage(Start); End = new Bitmap(w, h); GE = Graphics.FromImage(End); - r = new Rectangle(0, 0, w, h); + r = new System.Drawing.Rectangle(0, 0, w, h); } public void TransformAlpha(Graphics Graphics, double Rate) diff --git a/2DGAMELIB/_2DGAMELIB/WPFImage.cs b/2DGAMELIB/_2DGAMELIB/WPFImage.cs index 4ce5857..d6985ac 100644 --- a/2DGAMELIB/_2DGAMELIB/WPFImage.cs +++ b/2DGAMELIB/_2DGAMELIB/WPFImage.cs @@ -97,7 +97,7 @@ namespace _2DGAMELIB gl.ActiveTexture(Silk.NET.OpenGL.GLEnum.Texture0); gl.BindTexture(Silk.NET.OpenGL.GLEnum.Texture2D, texture); - BitmapData data = bmp.LockBits(new Rectangle(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, System.Drawing.Imaging.PixelFormat.Format32bppArgb); + BitmapData data = bmp.LockBits(new System.Drawing.Rectangle(0, 0, bmp.Width, bmp.Height), ImageLockMode.ReadOnly, System.Drawing.Imaging.PixelFormat.Format32bppArgb); gl.TexImage2D( Silk.NET.OpenGL.GLEnum.Texture2D,