Home | All Classes | Grouped Classes | Index | Search

Class CL_Rectf

2D (left,top,right,bottom) floating point rectangle structure. More...

Derived from: none
Derived by: none
Group: Core (Math)

#include <ClanLib/core.h>

Construction:

CL_Rectf

Constructs an rectangle.

operator +=

Rect += Rect operator.

operator -=

Rect -= Rect operator.

operator +

Rect + Rect operator.

operator -

Rect - Rect operator.

operator ==

Rect == Rect operator.

operator !=

Rect != Rect operator.

Attributes:

left

X1-coordinate.

top

Y1-coordinate.

right

X2-coordinate.

bottom

Y2-coordinate.

get_width

Returns the width of the rectangle.

get_height

Returns the height of the rectangle.

get_size

Returns the size of the rectangle.

is_inside

Returns true if point is inside the rectangle.

is_overlapped

Returns true if rectangle passed is overlapping or inside this rectangle.

get_rot_bounds

Returns another CL_Rectf containing a rotated version of this one.

Operations:

set_size

Sets the size of the rectangle, maintaining top/left position.

calc_union

Calculates and returns the union of two rectangles.

normalize

Normalize rectangle. Ensures that left

apply_alignment

Applies an origin and offset pair to this rectangle

Detailed description:



Questions or comments, write to the
ClanLib mailing list.