---
name: "_getpixel"
section: "3alleg"
platform: "linux"
package: "liballegro-doc"
version: "2:4.2.2-2.2"
release: "Debian 6.0 (Squeeze)"
platforms: ["linux"]
url: "https://new.carta.tech/_getpixel"
---

# \_getpixel(3alleg)

Faster specific version of getpixel(). Allegro game programming library.

## NAME

\_getpixel, \_getpixel15, \_getpixel16, \_getpixel24, \_getpixel32 - Faster specific version of getpixel(). Allegro game programming library.

## SYNOPSIS

**#include \<allegro.h\>**

**int \_getpixel(BITMAP \*bmp, int x, int y);**

**int \_getpixel15(BITMAP \*bmp, int x, int y);**

**int \_getpixel16(BITMAP \*bmp, int x, int y);**

**int \_getpixel24(BITMAP \*bmp, int x, int y);**

**int \_getpixel32(BITMAP \*bmp, int x, int y);**

## DESCRIPTION

Faster inline versions of getpixel() for specific color depths. These  won't work in mode-X, and don't do any clipping, so you must make sure  the point lies inside the bitmap.

## RETURN VALUE

Returns the value of the pixel in the color format you specified.

## SEE ALSO

[**getpixel**(3alleg)](/getpixel/3alleg.md)
