Skip to content

Commit e42830b

Browse files
MarkOatesSiegeLord
authored andcommitted
Add "al_is_image_addon_initialized"
1 parent 50460b7 commit e42830b

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

addons/image/allegro5/allegro_image.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ extern "C" {
3232

3333

3434
ALLEGRO_IIO_FUNC(bool, al_init_image_addon, (void));
35+
ALLEGRO_IIO_FUNC(bool, al_is_image_addon_initialized, (void));
3536
ALLEGRO_IIO_FUNC(void, al_shutdown_image_addon, (void));
3637
ALLEGRO_IIO_FUNC(uint32_t, al_get_allegro_image_version, (void));
3738

addons/image/iio.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,14 @@ bool al_init_image_addon(void)
164164
}
165165

166166

167+
/* Function: al_is_image_addon_initialized
168+
*/
169+
bool is_image_addon_initialized(void)
170+
{
171+
return iio_inited;
172+
}
173+
174+
167175
/* Function: al_shutdown_image_addon
168176
*/
169177
void al_shutdown_image_addon(void)

docs/src/refman/image.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ contains textures compressed in the DXT1, DXT3 and DXT5 formats. Note that when
2929
loading a DDS file, the created bitmap will always be a video bitmap and will
3030
have the pixel format matching the format in the file.
3131

32+
## API: al_is_image_addon_initialized
33+
34+
Returns true if the image addon has been initialized, otherwise returns false.
35+
3236
## API: al_shutdown_image_addon
3337

3438
Shut down the image addon. This is done automatically at program exit,

0 commit comments

Comments
 (0)