# Rectangle3d struct

Namespace: [Rhino.Geometry](https://developer.rhino3d.com/api/rhinocommon/namespace/rhino.geometry.md) · Assembly: [RhinoCommon](https://developer.rhino3d.com/api/rhinocommon/assembly/rhinocommon.md)

```cs
[Serializable]
public struct Rectangle3d : IEpsilonComparable<Rectangle3d>, ICloneable
```

Represents the values of a plane and two intervals that form an oriented rectangle in three dimensions.

## Constructors

- [Rectangle3d](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/ctor.md): (3 overloads) Initializes a new rectangle from width and height.

## Properties

- [Area](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/area.md): Gets the unsigned Area of the rectangle.
- [BoundingBox](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/boundingbox.md): Gets the world aligned bounding box for this rectangle.
- [Center](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/center.md): Gets the point in the center of the rectangle.
- [Circumference](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/circumference.md): Gets the circumference of the rectangle.
- [Height](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/height.md): Gets the signed height of the rectangle. If the Y dimension is decreasing, the height will be negative.
- [IsValid](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/isvalid.md): Gets a value indicating whether or not this is a valid rectangle. A rectangle is considered to be valid when the base plane and both dimensions are valid.
- [Plane](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/plane.md): Gets or sets the base plane of the rectangle.
- [Unset](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/unset.md): (static) Gets a rectangle with Unset components.
- [Width](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/width.md): Gets the signed width of the rectangle. If the X dimension is decreasing, the width will be negative.
- [X](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/x.md): Gets or sets the dimensions of the rectangle along the base plane X-Axis (i.e. the width).
- [Y](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/y.md): Gets or sets the dimensions of the rectangle along the base plane Y-Axis (i.e. the height).

## Methods

- [ClosestPoint](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/closestpoint.md): (2 overloads) Gets the point on the rectangle that is closest to a test-point.
- [Contains](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/contains.md): (2 overloads) Determines if two plane parameters are included in this rectangle.
- [Corner](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/corner.md): Gets the corner at the given index.
- [CreateFromPolyline](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/createfrompolyline.md): (2 overloads, static) Attempts to create a rectangle from a polyline. This method only works well for polylines that already closely resemble rectangles. If the polyline contains more than four vertices, the least significant ones will be ignored. If the polylines is non-orthogonal, the discrepancies will be averaged away. This method should not be used as a Rectangle fitter.
- [EpsilonEquals](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/epsilonequals.md): Check that all values in other are within epsilon of the values in this
- [MakeIncreasing](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/makeincreasing.md): Ensures the X and Y dimensions are increasing or singleton intervals.
- [PointAt](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/pointat.md): (2 overloads) Gets a point along the rectangle boundary.
- [RecenterPlane](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/recenterplane.md): (2 overloads) Re-centers the base plane on one of the corners.
- [ICloneable.Clone](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/system-icloneable-clone.md)
- [ToNurbsCurve](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/tonurbscurve.md): Constructs a nurbs curve representation of this rectangle.
- [ToPolyline](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/topolyline.md): Constructs a polyline from this rectangle.
- [Transform](https://developer.rhino3d.com/api/rhinocommon/type/rhino.geometry.rectangle3d/transform.md): Transforms this rectangle. Note that rectangles cannot be skewed or tapered.
