---
name: "al_destroy_shader"
section: "3"
platform: "linux"
package: "allegro"
version: "5.2.11.3-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/al_destroy_shader"
---

# al\_destroy\_shader(3)

Allegro 5 API

## NAME

al\_destroy\_shader - Allegro 5 API

## SYNOPSIS

-

  ```
  #include <allegro5/allegro.h>
  void al_destroy_shader(ALLEGRO_SHADER *shader)
  ```

## DESCRIPTION

Destroy a shader. Any bitmaps which currently use the shader will implicitly stop using the shader. In multi-threaded programs, be careful that no such bitmaps are being accessed by other threads at the time.

As a convenience, if the target bitmap of the calling thread is using the shader then the shader is implicitly unused before being destroyed.

This function does nothing if the shader argument is NULL.

## SINCE

5\.1.0

## SEE ALSO

[al\_create\_shader(3)](/al_create_shader/3.md)
