---
name: "SDL_Rect"
section: "3"
platform: "linux"
package: "libsdl1.2-dev"
version: "1.2.15+dfsg2-8"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/SDL_Rect"
---

# SDL\_Rect(3)

Defines a rectangular area

## NAME

SDL\_Rect - Defines a rectangular area

## STRUCTURE DEFINITION

```
typedef struct{
  Sint16 x, y;
  Uint16 w, h;
} SDL_Rect;
```

## STRUCTURE DATA

- **x, y**

  Position of the upper-left corner of the rectangle

- **w, h**

  The width and height of the rectangle

## DESCRIPTION

A **SDL\_Rect** defines a rectangular area of pixels. It is used by **SDL\_BlitSurface** to define blitting regions and by several other video functions.

## SEE ALSO

**SDL\_BlitSurface**, **SDL\_UpdateRect**
