Skip to content
This repository was archived by the owner on Dec 13, 2025. It is now read-only.

VRageMath.Rectangle

Malware edited this page Dec 25, 2018 · 51 revisions

Index

Rectangle Struct

public struct Rectangle: 

Namespace: VRageMath
Assembly: VRage.Math.dll

Example

Remarks

Fields

Member Description
X Specifies the x-coordinate of the rectangle.
Y Specifies the y-coordinate of the rectangle.
Width Specifies the width of the rectangle.
Height Specifies the height of the rectangle.

Properties

Member Description
Left Returns the x-coordinate of the left side of the rectangle.
Right Returns the x-coordinate of the right side of the rectangle.
Top Returns the y-coordinate of the top of the rectangle.
Bottom Returns the y-coordinate of the bottom of the rectangle.
Location Gets or sets the upper-left value of the Rectangle.
Center Gets the Point that specifies the center of the rectangle.

Methods

Member Description
Offset(Point) Changes the position of the Rectangle.
Offset(int, int) Changes the position of the Rectangle.
Inflate(int, int) Pushes the edges of the Rectangle out by the horizontal and vertical values specified.
Contains(int, int) Determines whether this Rectangle contains a specified point represented by its x- and y-coordinates.
Contains(Point) Determines whether this Rectangle contains a specified Point.
Contains(ref Point, ref bool) Determines whether this Rectangle contains a specified Point.
Contains(Rectangle) Determines whether this Rectangle entirely contains a specified Rectangle.
Contains(ref Rectangle, ref bool) Determines whether this Rectangle entirely contains a specified Rectangle.
Intersects(Rectangle) Determines whether a specified Rectangle intersects with this Rectangle.
Intersects(ref Rectangle, ref bool) Determines whether a specified Rectangle intersects with this Rectangle.
Intersect(Rectangle, Rectangle) Creates a Rectangle defining the area where one rectangle overlaps with another rectangle.
Intersect(ref Rectangle, ref Rectangle, ref Rectangle) Creates a Rectangle defining the area where one rectangle overlaps with another rectangle.
Union(Rectangle, Rectangle) Creates a new Rectangle that exactly contains two other rectangles.
Union(ref Rectangle, ref Rectangle, ref Rectangle) Creates a new Rectangle that exactly contains two other rectangles.
Equals(Rectangle) Determines whether the specified Object is equal to the Rectangle.
Equals(object) Returns a value that indicates whether the current instance is equal to a specified object.
ToString() Retrieves a string representation of the current object.
GetHashCode() Gets the hash code for this object.

Clone this wiki locally