| Rect2d Structure | 
Namespace: OpenCvSharp
 Syntax
SyntaxThe Rect2d type exposes the following members.
 Constructors
Constructors| Name | Description | |
|---|---|---|
|  | Rect2d(Point2d, Size2d) | Initializes a new instance of the Rect2d class | 
|  | Rect2d(Double, Double, Double, Double) | Initializes a new instance of the Rect2d class | 
 Properties
Properties| Name | Description | |
|---|---|---|
|  | Bottom | 
            Gets the y-coordinate that is the sum of the Y and Height property values of this Rect2d structure.
             | 
|  | BottomRight | 
            Coordinate of the right-most rectangle corner [Point2d(X+Width, Y+Height)]
             | 
|  | Left | 
            Gets the x-coordinate of the left edge of this Rect2d structure. 
             | 
|  | Location | 
            Coordinate of the left-most rectangle corner [Point2d(X, Y)]
             | 
|  | Right | 
            Gets the x-coordinate that is the sum of X and Width property values of this Rect2d structure. 
             | 
|  | Size | 
            Size of the rectangle [CvSize(Width, Height)]
             | 
|  | Top | 
            Gets the y-coordinate of the top edge of this Rect2d structure. 
             | 
|  | TopLeft | 
            Coordinate of the left-most rectangle corner [Point2d(X, Y)]
             | 
 Methods
Methods| Name | Description | |
|---|---|---|
|  | Contains(Point2d) | 
            Determines if the specified point is contained within the rectangular region defined by this Rectangle. 
             | 
|  | Contains(Rect2d) | 
            Determines if the specified rectangle is contained within the rectangular region defined by this Rectangle. 
             | 
|  | Contains(Double, Double) | 
            Determines if the specified point is contained within the rectangular region defined by this Rectangle. 
             | 
|  | Equals(Object) | 
            Specifies whether this object contains the same members as the specified Object.
            (Overrides ValueTypeEquals(Object).) | 
|  | Equals(Rect2d) | 
            Specifies whether this object contains the same members as the specified Object.
             | 
|   | FromLTRB | |
|  | GetHashCode | 
            Returns a hash code for this object.
            (Overrides ValueTypeGetHashCode.) | 
|  | GetType | Gets the Type of the current instance.(Inherited from Object.) | 
|  | Inflate(Size2d) | 
            Inflates this Rect by the specified amount. 
             | 
|  | Inflate(Double, Double) | 
            Inflates this Rect by the specified amount. 
             | 
|   | Inflate(Rect, Int32, Int32) | 
            Creates and returns an inflated copy of the specified Rect2d structure.
             | 
|  | Intersect(Rect2d) | 
            Determines the Rect2d structure that represents the intersection of two rectangles. 
             | 
|   | Intersect(Rect2d, Rect2d) | 
            Determines the Rect2d structure that represents the intersection of two rectangles. 
             | 
|  | IntersectsWith | 
            Determines if this rectangle intersects with rect. 
             | 
|  | ToRect | |
|  | ToString | 
            Converts this object to a human readable string.
            (Overrides ValueTypeToString.) | 
|  | Union(Rect2d) | 
            Gets a Rect2d structure that contains the union of two Rect2d structures. 
             | 
|   | Union(Rect2d, Rect2d) | 
            Gets a Rect2d structure that contains the union of two Rect2d structures. 
             | 
 Operators
Operators| Name | Description | |
|---|---|---|
|   | Addition(Rect2d, Point2d) | 
            Shifts rectangle by a certain offset
             | 
|   | Addition(Rect2d, Size2d) | 
            Expands or shrinks rectangle by a certain amount
             | 
|   | BitwiseAnd | 
            Determines the Rect2d structure that represents the intersection of two rectangles. 
             | 
|   | BitwiseOr | 
            Gets a Rect2d structure that contains the union of two Rect2d structures. 
             | 
|   | Equality | 
            Compares two Rect2d objects. The result specifies whether the members of each object are equal.
             | 
|   | Inequality | 
            Compares two Rect2d objects. The result specifies whether the members of each object are unequal.
             | 
|   | Subtraction(Rect2d, Point2d) | 
            Shifts rectangle by a certain offset
             | 
|   | Subtraction(Rect2d, Size2d) | 
            Expands or shrinks rectangle by a certain amount
             | 
 Fields
Fields| Name | Description | |
|---|---|---|
|   | Empty | 
            Represents a Rect2d structure with its properties left uninitialized. 
             | 
|  | Height | |
|   | SizeOf | 
            sizeof(Rect)
             | 
|  | Width | |
|  | X | |
|  | Y | 
 See Also
See Also