---
name: "al_backup_dirty_bitmap"
section: "3alleg5"
platform: "linux"
package: "allegro5-doc"
version: "2:5.2.10.1+dfsg-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/al_backup_dirty_bitmap/3alleg5"
---

# al\_backup\_dirty\_bitmap(3alleg5)

Allegro 5 API

## NAME

al\_backup\_dirty\_bitmap - Allegro 5 API

## SYNOPSIS

-

  ```
  #include <allegro5/allegro.h>
  void al_backup_dirty_bitmap(ALLEGRO_BITMAP *bitmap)
  ```

## DESCRIPTION

On some platforms, notably Windows Direct3D and Android, textures may be lost at any time for events such as display resize or switching out of the app. On those platforms, bitmaps created without the ALLEGRO\_NO\_PRESERVE\_TEXTURE flag automatically get backed up to system memory every time al\_flip\_display is called.

This function gives you more control over when your bitmaps get backed up. By calling this function after modifying a bitmap, you can make sure the bitmap is backed up right away instead of during the next flip.

## SINCE

5\.2.1

*\[Unstable API\]:* This API is new and subject to refinement.

## SEE ALSO

al\_backup\_dirty\_bitmaps(3alleg5), al\_create\_bitmap(3alleg5)
