1ALLEGRO_STATE(3) ALLEGRO_STATE(3)
2
3
4
6 ALLEGRO_STATE - Allegro 5 API
7
9 typedef struct ALLEGRO_STATE ALLEGRO_STATE;
10
12 Opaque type which is passed to al_store_state(3)/al_restore_state(3).
13
14 The various state kept internally by Allegro can be displayed like
15 this:
16
17 global
18 active system driver
19 current config
20 per thread
21 new bitmap params
22 new display params
23 active file interface
24 errno
25 current blending mode
26 current display
27 deferred drawing
28 current target bitmap
29 current transformation
30 current projection transformation
31 current clipping rectangle
32 bitmap locking
33 current shader
34
35 In general, the only real global state is the active system driver.
36 All other global state is per-thread, so if your application has multi‐
37 ple separate threads they never will interfere with each other. (Ex‐
38 cept if there are objects accessed by multiple threads of course. Usu‐
39 ally you want to minimize that though and for the remaining cases use
40 synchronization primitives described in the threads section or events
41 described in the events section to control inter-thread communication.)
42
43
44
45Allegro reference manual ALLEGRO_STATE(3)