---
name: "voice_check"
section: "3alleg4"
platform: "linux"
package: "allegro4-doc"
version: "2:4.4.3.1-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/voice_check/3alleg4"
---

# voice\_check(3alleg4)

Checks whether a voice is currently allocated. Allegro game programming library.

## NAME

voice\_check - Checks whether a voice is currently allocated. Allegro game programming library.

## SYNOPSIS

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

**SAMPLE \*voice\_check(int voice);**

## DESCRIPTION

Checks whether a voice is currently allocated.

## RETURN VALUE

Returns a pointer to the sample that the voice is using, or NULL if the voice is inactive (ie. it has been deallocated, or the release\_voice() function has been called and the sample has then finished playing).

## SEE ALSO

**allocate\_voice**(3alleg4), **voice\_start**(3alleg4), **voice\_get\_position**(3alleg4)
