Skip to contents

Create a new rectangle object.

Usage

rectangle(x, y, width, height)

Arguments

x

A number. Rectangle top-left corner position x.

y

A number. Rectangle top-left corner position y.

width

A number. Rectangle width.

height

A number. Rectangle height.

Value

A rectangle

Note

This class has been auto-generated from the following Raylib struct definition:

typedef struct Rectangle {
    float x;                // Rectangle top-left corner position x
    float y;                // Rectangle top-left corner position y
    float width;            // Rectangle width
    float height;           // Rectangle height
} Rectangle;