Package allegro-devel

A game programming library

http://alleg.sourceforge.net/

Allegro is a cross-platform library intended for use in computer games
and other types of multimedia programming. This package is needed to
build programs written with Allegro.

Library Functions (Section 3)
acquire_bitmap
Acquires the specified video bitmap prior to drawing onto it. You never need to call the function explicitly as it is low level, and will only give you a speed...
acquire_screen
Shortcut version of acquire_bitmap(screen);
active_dialog
Global pointer to the most recent activated dialog. This may be useful if an object needs to iterate through a list of all its siblings.
active_menu
When a menu callback procedure is triggered, this will be set to the menu item that was selected, so your routine can determine where it was called from.
add_clip_rect
Sets the clipping rectangle of the specified bitmap as the intersection of its current clipping rectangle and the rectangle described by the four coordinates.
adjust_sample
Alters the parameters of a sample while it is playing (useful for manipulating looped sounds). You can alter the volume, pan, and frequency, and can also clear...
al_assert
Raises an assert for an error at the specified file and line number. The file parameter is always given in ASCII format. By default, this will call the system...
alert
Displays a popup alert box, containing three lines of text (s1-s3), and with either one or two buttons. The text for these buttons is passed in `b1' and `b2'...
alert3
Like alert(), but with three buttons. Returns 1, 2, or 3.
al_ffblk
Cross platform structure storing file information. Allegro game programming library.
al_ffblk_get_size
This returns the size of the file returned by al_findfirst or al_findnext.
al_findclose
This closes a previously opened search with al_findfirst(). You need to call this on all successfully opened searches to avoid memory leaks in your program.
al_findfirst
Low-level function for searching files. This function finds the first file which matches the given wildcard specification and file attributes (see above). The...
al_findnext
This finds the next file in a search started by al_findfirst().
AL_ID
This macro can be used to create a packed 32 bit integer from 8 bit characters, on both 32 and 64 bit machines. These can be used for various things, like...
allegro_404_char
When Allegro cannot find a glyph it needs in a font, it will instead output the character given in allegro_404_char. By default, this is set to the caret...
ALLEGRO_DATE
Defined to an integer containing the release date of Allegro in the packed format `yyyymmdd'.
ALLEGRO_DATE_STR
Defined to a text string containing the year this version of Allegro was released, like `2004'.
allegro_error
Text string used by set_gfx_mode(), install_sound() and other functions to report error messages. If they fail and you want to tell the user why, this is the...
allegro_exit
Closes down the Allegro system. This includes returning the system to text mode and removing whatever mouse, keyboard, and timer routines have been installed...
allegro_icon
This is a pointer to the Allegro X11 icon, which is in the format of standard .xpm bitmap data. You do not normally have to bother with this at all: you can use...
allegro_id
Text string containing a date and version number for the library, in case you want to display these somewhere.
allegro_init
Macro which initialises the Allegro library. This is the same thing as calling install_allegro(SYSTEM_AUTODETECT, &errno, atexit).
allegro_message
Outputs a message, using a printf() format string. Usually you want to use this to report messages to the user in an OS independent way when some Allegro...
ALLEGRO_SUB_VERSION
Defined to the middle version of Allegro. From a version number like 4.1.16, this would be defined to the integer 1.
ALLEGRO_VERSION
Defined to the major version of Allegro. From a version number like 4.1.16, this would be defined to the integer 4.
ALLEGRO_VERSION_STR
Defined to a text string containing all version numbers and maybe some additional text. This could be `4.2.1 (SVN)' for an Allegro version obtained straight...
ALLEGRO_WIP_VERSION
Defined to the minor version of Allegro. From a version number like 4.1.16, this would be defined to the integer 16.
allocate_voice
Allocates a sound card voice and prepares it for playing the specified sample, setting up sensible default parameters (maximum volume, centre pan, no change of...
al_trace
Outputs a debugging trace message, using a printf() format string given in ASCII. If you have installed a custom trace handler it uses that, or if the...
append_filename
Concatenates the specified filename onto the end of the specified path, storing at most `size' bytes into the `dest' buffer. If `path' doesn't have a trailing...
apply_matrix
Multiplies the point (x, y, z) by the transformation matrix m, storing the result in (*xout, *yout, *zout).
apply_quat
Multiplies the point (x, y, z) by the quaternion q, storing the result in (*xout, *yout, *zout). This is quite a bit slower than apply_matrix_f(), so only use...
arc
Draws a circular arc with centre x, y and radius r, in an anticlockwise direction starting from the angle a1 and ending when it reaches a2. These values are...
ASSERT
Debugging helper macro. Normally compiles away to nothing, but if you defined the preprocessor symbol DEBUGMODE before including Allegro headers, it will check...
AUDIOSTREAM
Stores an audiostream. Allegro game programming library.
bestfit_color
Searches the specified palette for the closest match to the requested color, which are specified in the VGA hardware 0-63 format. Normally you should call...
BITMAP
Stores the contents of a bitmap. Allegro game programming library.
bitmap_color_depth
Returns the color depth of the specified bitmap (8, 15, 16, 24, or 32).
bitmap_mask_color
Returns the mask color for the specified bitmap (the value which is skipped when drawing sprites). For 256-color bitmaps this is zero, and for truecolor bitmaps...
black_palette
A palette containing solid black colors, used by the fade routines.
blit
Copies a rectangular area of the source bitmap to the destination bitmap. The source_x and source_y parameters are the top left corner of the area to copy from...
bmp_read_line
Selects the line of a bitmap that you are going to read from.
bmp_unwrite_line
Releases the bitmap memory after you are finished with it. You only need to call this once at the end of a drawing operation, even if you have called...
bmp_write_line
Selects the line of a bitmap that you are going to draw onto.
broadcast_dialog_message
Broadcasts a message to all the objects in the active dialog. If any of the dialog procedures return values other than D_O_K, it returns that value.
calc_spline
Calculates a series of npts values along a Bezier spline, storing them in the output x and y arrays. The Bezier curve is specified by the four x/y control...
calibrate_joystick
Most joysticks need to be calibrated before they can provide full analogue input. This function performs the next operation in the calibration series for the...
calibrate_joystick_name
Pass the number of the joystick you want to calibrate as the parameter.
canonicalize_filename
Converts any filename into its canonical form, i.e. the minimal absolute filename describing the same file and fixing incorrect forward/backward slashes for the...
centre_dialog
Moves an array of dialog objects so that it is centered in the screen.
check_cpu
Detects the CPU type, setting the following global variables. You don't normally need to call this, because allegro_init() will do it for you.
circle
Draws a circle with the specified centre and radius.
circlefill
Draws a filled circle with the specified centre and radius.
clear_bitmap
Clears the bitmap to color 0.
clear_keybuf
Empties the keyboard buffer. Usually you want to use this in your program before reading keys to avoid previously buffered keys to be returned by calls to...
clear_scene
Initializes a scene. The bitmap is the bitmap you will eventually render on.
clear_to_color
Clears the bitmap to the specified color.
clear_zbuffer
Writes z into the given Z-buffer (0 means far away). This function should be used to initialize the Z-buffer before each frame. Actually, low-level routines...
clip3d
Fixed point version of clip3d_f(). This function should be used with caution, due to the limited precision of fixed point arithmetic and high chance of rounding...
clip3d_f
Clips the polygon given in `vtx'. The number of vertices is `vc', the result goes in `vout', and `vtmp' and `out' are needed for internal purposes. The pointers...
close_fli
Closes an FLI file when you have finished reading from it. Remember to do this to avoid having memory leaks in your program.
color_map
Global pointer to the color mapping table.
COLOR_MAP
Stores a color map to accelerate drawing. Allegro game programming library.
COMPILED_SPRITE
Stores the contents of a compiled sprite. Allegro game programming library.
config_is_hooked
Returns TRUE if the specified config section has been hooked.
cpu_capabilities
Contains CPU flags indicating what features are available on the current CPU.
cpu_family
Contains the Intel type, where applicable.
cpu_model
Contains the CPU submodel, where applicable.
cpu_vendor
On Intel PCs, contains the CPU vendor name if known. On Mac OSX systems this contains the PPC subtype name. On other platforms, this may be an empty string. You...
create_bitmap
Creates a memory bitmap sized width by height. The bitmap will have clipping turned on, and the clipping rectangle set to the full size of the bitmap. The image...
create_bitmap_ex
Creates a bitmap in a specific color depth (8, 15, 16, 24 or 32 bits per pixel).
create_blender_table
Fills the specified color mapping table with lookup data for doing a paletted equivalent of whatever truecolor blender mode is currently selected. After calling...
create_color_table
Fills the specified color mapping table with lookup data for doing customised effects with the specified palette, calling the blend function to determine the...
create_datafile_index
Creates an index for a datafile, to speed up loading single objects out of it. This is mostly useful for big datafiles, which you don't want to load as a whole...
create_light_table
Fills the specified color mapping table with lookup data for doing lighting effects with the specified palette. When combining the colors c1 and c2 with this...
create_lzss_pack_data
Creates an LZSS_PACK_DATA structure, which can be used for LZSS compression with PACKFILEs.
create_lzss_unpack_data
Creates an LZSS_UNPACK_DATA structure, which can be used for LZSS decompression reading PACKFILEs.
create_rgb_table
Fills the specified RGB mapping table with lookup data for the specified palette. If the callback function is not NULL, it will be called 256 times during the...
create_sample
Constructs a new sample structure of the specified type. Read chapter "Structures and types defined by Allegro" for an internal description of the SAMPLE...
create_scene
Allocates memory for a scene, `nedge' and `npoly' are your estimates of how many edges and how many polygons you will render (you cannot get over the limit...
create_sub_bitmap
Creates a sub-bitmap, ie. a bitmap sharing drawing memory with a pre-existing bitmap, but possibly with a different size and clipping settings. When creating a...
create_sub_zbuffer
Creates a sub-z-buffer, ie. a z-buffer sharing drawing memory with a pre-existing z-buffer, but possibly with a different size. The same rules as for...
create_system_bitmap
Allocates a system memory bitmap of the specified size. Read the introduction of this chapter for a comparison with other types of bitmaps and other specific...
create_trans_table
Fills the specified color mapping table with lookup data for doing translucency effects with the specified palette. When combining the colors c1 and c2 with...
create_video_bitmap
Allocates a video memory bitmap of the specified size. This can be used to allocate offscreen video memory for storing source graphics ready for a hardware...
create_zbuffer
Creates a Z-buffer using the size of the BITMAP you are planning to draw on. Several Z-buffers can be defined but only one can be used at the same time, so you...
cross_product
Calculates the cross product (x1, y1, z1) x (x2, y2, z2), storing the result in (*xout, *yout, *zout). The cross product is perpendicular to both of the input...
DATAFILE
Stores an Allegro datafile in memory.
DAT_ID
Every object or property in a datafile is identified by a 4 letter ID, which can be created with this macro.
d_bitmap_proc
This draws a bitmap onto the screen, which should be pointed to by the dp field.
d_box_proc
These draw boxes onto the screen, with or without a shadow.
d_button_proc
A button object (the dp field points to the text string). This object can be selected by clicking on it with the mouse or by pressing its keyboard shortcut. If...
d_check_proc
This is an example of how you can derive objects from other objects. Most of the functionality comes from d_button_proc(), but it displays itself as a check...
d_clear_proc
This just clears the screen when it is drawn. Useful as the first object in a dialog.
deallocate_voice
Frees a sound card voice, stopping it from playing and releasing whatever resources it is using.
d_edit_proc
An editable text object (the dp field points to the string). When it has the input focus (obtained by clicking on it with the mouse), text can be typed into...
default_palette
The default IBM BIOS palette. This will be automatically selected whenever you set a new graphics mode. The palette contains 16 basic colors plus many gradients...
delete_file
Removes a file from the disk. You can't delete directories, though.
desktop_color_depth
Finds out the currently selected desktop color depth. You can use this information to make your program use the same color depth as the desktop, which will...
desktop_palette
The palette used by the Atari ST low resolution desktop. I'm not quite sure why this is still here, except that the grabber and test programs use it. It is...
destroy_bitmap
Destroys a memory bitmap, sub-bitmap, video memory bitmap, or system bitmap when you are finished with it. If you pass a NULL pointer this function won't do...
destroy_compiled_sprite
Destroys a compiled sprite structure previously returned by get_compiled_sprite(). If you pass a NULL pointer this function won't do anything. Use this once you...
destroy_datafile_index
This function frees the memory used by a datafile index created with create_datafile_index earlier.
destroy_font
Frees the memory being used by a font structure. Don't use this on the default global Allegro font or any text routines using it could crash. You should use...
destroy_gfx_mode_list
Removes the mode list created by get_gfx_mode_list() from memory. Use this once you are done with the generated mode list to avoid memory leaks in your program.
destroy_midi
Destroys a MIDI structure when you are done with it. It is safe to call this even when the MIDI file might be playing, because it checks and will kill it off if...
destroy_rle_sprite
Destroys an RLE sprite structure previously returned by get_rle_sprite(). If you pass a NULL pointer this function won't do anything. Use this once you are done...
destroy_sample
Destroys a sample structure when you are done with it. It is safe to call this even when the sample might be playing, because it checks and will kill it off if...
destroy_scene
Deallocate memory previously allocated by create_scene. Use this to avoid memory leaks in your program.
destroy_zbuffer
Destroys the Z-buffer when you are finished with it. Use this to avoid memory leaks in your program.
detect_digi_driver
Detects whether the specified digital sound device is available. This function must be called _before_ install_sound().
detect_midi_driver
Detects whether the specified MIDI sound device is available. This function must be called _before_ install_sound().
DIALOG
Stores a GUI description. Allegro game programming library.
dialog_message
Sends a message to all the objects in an array. If any of the dialog procedures return values other than D_O_K, it returns the value and sets obj to the index...
DIALOG_PLAYER
A structure which holds GUI data used internally by Allegro. Read the documentation of init_dialog() for a description on how to obtain/use this structure.
d_icon_proc
A bitmap button. The fg color is used for the dotted line showing focus, and the bg color for the shadow used to fill in the top and left sides of the button...
digi_recorder
If set, this function is called by the input driver whenever a new sample buffer becomes available, at which point you can use read_sound_input() to copy the...
disable_hardware_cursor
After calling this function, Allegro will be responsible for drawing the mouse cursor rather than the operating system. On some platforms calling...
d_keyboard_proc
This is an invisible object for implementing keyboard shortcuts. You can put an ASCII code in the key field of the dialog object (a character such as 'a' to...
d_list_proc
A list box object. This will allow the user to scroll through a list of items and to select one by clicking or with the arrow keys. If the D_EXIT flag is set...
d_menu_proc
This object is a menu bar which will drop down child menus when it is clicked or if an alt+key corresponding to one of the shortcuts in the menu is pressed. It...
do_arc
Calculates all the points in a circular arc around point (x, y) with radius r, calling the supplied function for each one. This will be passed a copy of the bmp...
do_circle
Calculates all the points in a circle around point (x, y) with radius r, calling the supplied function for each one. This will be passed a copy of the bmp...
do_dialog
The basic dialog manager function. This displays a dialog (an array of dialog objects, terminated by one with a NULL dialog procedure), and sets the input focus...
do_ellipse
Calculates all the points in an ellipse around point (x, y) with radius rx and ry, calling the supplied function for each one. This will be passed a copy of the...
do_line
Calculates all the points along a line from point (x1, y1) to (x2, y2), calling the supplied function for each one. This will be passed a copy of the bmp...
do_menu
Displays and animates a popup menu at the specified screen coordinates (these will be adjusted if the menu does not entirely fit on the screen). Returns the...
dot_product
Calculates the dot product (x1, y1, z1) . (x2, y2, z2), returning the result.
do_uconvert
Converts the specified string `s' from `type' to `newtype', storing at most `size' bytes into the output `buf'. The type parameters can use the value U_CURRENT...
d_radio_proc
A radio button object. A dialog can contain any number of radio button groups: selecting a radio button causes other buttons within the same group to be...
draw_character_ex
Draws a copy of the sprite bitmap onto the destination bitmap at the specified position, drawing transparent pixels in the background color (or skipping them if...
draw_compiled_sprite
Draws a compiled sprite onto a bitmap at the specified position. The sprite must have been compiled for the correct type of bitmap (linear or planar). This...
draw_gouraud_sprite
More sophisticated version of draw_lit_sprite(): the 'color' parameter is not constant across the sprite image anymore but interpolated between the four...
drawing_mode
Sets the graphics drawing mode. This only affects the geometric routines like putpixel, lines, rectangles, circles, polygons, floodfill, etc, not the text...
draw_lit_rle_sprite
Tinted version of draw_rle_sprite(). See the description of draw_lit_sprite(). This must only be used after you have set up the color mapping table (for...
draw_lit_sprite
In 256-color modes, uses the global color_map table to tint the sprite image to the specified color or to light it to the level specified by 'color', depending...
draw_rle_sprite
Draws an RLE sprite onto a bitmap at the specified position.
draw_sprite
Draws a copy of the sprite bitmap onto the destination bitmap at the specified position. This is almost the same as blit(sprite, bmp, 0, 0, x, y, sprite->w...
draw_sprite_ex
Draws the sprite image onto the destination bitmap using the specified mode argument, optionally flipping the sprite in the orientation specified by flip...
draw_sprite_v_flip
These are like draw_sprite(), but they additionally flip the image vertically, horizontally, or both, respectively. Flipping vertically means that the y-axis is...
draw_trans_rle_sprite
Translucent version of draw_rle_sprite(). See the description of draw_trans_sprite(). This must only be used after you have set up the color mapping table (for...
draw_trans_sprite
Uses the global color_map table or truecolor blender functions to overlay the sprite on top of the existing image. This must only be used after you have set up...
d_slider_proc
A slider control object. This object holds a value in d2, in the range from 0 to d1. It will display as a vertical slider if h is greater than or equal to w...
d_textbox_proc
A text box object. The dp field points to the text which is to be displayed in the box. If the text is long, there will be a vertical scrollbar on the right...
d_text_list_proc
Like d_list_proc, but allows the user to type in the first few characters of a listbox entry in order to select it. Uses dp3 internally, so you mustn't store...
d_text_proc
These draw text onto the screen. The dp field should point to the string to display. d_ctext_proc() centers the string horizontally, and d_rtext_proc() right...
d_yield_proc
An invisible helper object that yields time slices for the scheduler (if the system supports it) when the GUI has nothing to do but waiting for user actions...
ellipse
Draws an ellipse with the specified centre and radius.
ellipsefill
Draws a filled ellipse with the specified centre and radius.
empty_string
You can't just rely on "" to be a valid empty string in any encoding format. This global buffer contains a number of consecutive zeros, so it will be a valid...
enable_hardware_cursor
After calling this function, Allegro will let the operating system draw the mouse cursor instead of doing it itself. This is not possible with all graphics...
enable_triple_buffer
If the GFX_CAN_TRIPLE_BUFFER bit of the gfx_capabilities field is not set, you can attempt to enable it by calling this function. In particular if you are...
END_OF_FUNCTION
Due to interrupts, you are required to lock all the code used by your timer routines. See the description of install_int_ex() for a more detailed explanation...
END_OF_MAIN
In order to maintain cross-platform compatibility, you have to put this macro at the very end of your main function. This macro uses some `magic' to mangle your...
ex12bit
This program sets up a 12-bit mode on any 8-bit card, by setting up a 256-colour palette that will fool the eye into grouping two 8-bit pixels into one 12-bit...
ex3buf
This program demonstrates the use of triple buffering. Several triangles are displayed rotating and bouncing on the screen until you press a key. Note that on...
ex3d
This program demonstrates how to use the 3d matrix functions. It isn't a very elegant or efficient piece of code, but it does show the stuff in action. It is...
exaccel
This program demonstrates how to use an offscreen part of the video memory to store source graphics for a hardware accelerated graphics driver. The example...
exalpha
This program demonstrates how to use the 32 bit RGBA translucency functions to store an alpha channel along with a bitmap graphic. Two images are loaded from...
exbitmap
This program demonstrates how to load and display a bitmap file. You have to use this example from the command line to specify as first parameter a graphic file...
exblend
This program demonstrates how to use the translucency functions in truecolor video modes. Two image files are loaded from disk and displayed moving slowly...
excamera
This program demonstrates how to use the get_camera_matrix() function to view a 3d world from any position and angle. The example draws a checkered floor...
excolmap
This program demonstrates how to create custom graphic effects with the create_color_table function. Allegro drawing routines are affected by any color table...
exconfig
This is a very simple program showing how to use the Allegro configuration (ini file) routines. A first look at the example shows nothing more than a static...
excustom
A follow up of the exgui.c example showing how to customise the default Allegro framework. In this case a dialog procedure animates a graphical clock without...
exdata
This program demonstrates how to access the contents of an Allegro datafile (created by the grabber utility). The example loads the file `example.dat', then...
exdbuf
This program demonstrates the use of double buffering. It moves a circle across the screen, first just erasing and redrawing directly to the screen, then with a...
exexedat
This program demonstrates how to access the contents of an Allegro datafile (created by the grabber utility) linked to the executable by the exedat tool. It is...
exfixed
This program demonstrates how to use fixed point numbers, which are signed 32-bit integers storing the integer part in the upper 16 bits and the decimal part in...
exflame
This program demonstrates how to write directly to video memory. It implements a simple fire effect, first by calling getpixel() and putpixel(), then by...
exflip
This program moves a circle across the screen, first with a double buffer and then using page flips.
exfont
This is a very simple program showing how to load and manipulate fonts.
exgui
This program demonstrates how to use the GUI routines. From the simple dialog controls that display a text or a bitmap to more complex multiple choice selection...
exhello
This is a very simple program showing how to get into graphics mode and draw text onto the screen.
exists
Shortcut version of file_exists(), which checks for normal files, which may have the archive or read-only bits set, but are not hidden, directories, system...
exjoy
This program uses the Allegro library to detect and read the value of a joystick. The output of the program is a small target sight on the screen which you can...
exkeys
This program demonstrates how to access the keyboard. The first part shows the basic use of readkey(). The second part shows how to extract the ASCII value...
exlights
This program shows one way to implement colored lighting effects in a hicolor video mode. Warning: it is not for the faint of heart! This is by no means the...
exmem
This program demonstrates the use of memory bitmaps. It creates a small temporary bitmap in memory, draws some circles onto it, and then blits lots of copies of...
exmidi
This program demonstrates how to play MIDI files.
exmouse
This program demonstrates how to get mouse input. The first part of the test retrieves the raw mouse input data and displays it on the screen without using any...
expackf
This program demonstrates the use of the packfile functions, with some simple tests. The first test uses the standard packfile functions to transfer a bitmap...
expal
This program demonstrates how to manipulate the palette. It draws a set of concentric circles onto the screen and animates them by cycling the palette.
expat
This program demonstrates the use of patterned drawing and sub-bitmaps.
exquat
Euler angles are convenient for storing and creating 3D orientations. However, this program demonstrates that they are not good when interpolating between two...
exrgbhsv
This program shows how to convert colors between the different color-space representations. The central area of the screen will display the current color. On...
exrotscl
This example demonstrates rotate_scaled_sprite functions.
exsample
This program demonstrates how to play samples. You have to use this example from the command line to specify as first parameter a WAV or VOC sound file to play...
exscale
This example demonstrates how to use PCX files, palettes and stretch blits. It loads a PCX file, sets its palette and does some random stretch_blits. Don't...
exscn3d
This program demonstrates how to use scanline sorting algorithm in Allegro (create_scene, clear_scene, ... functions). It also provides an example of how to use...
exscroll
This program demonstrates how to use hardware scrolling. The scrolling should work on anything that supports virtual screens larger than the physical screen.
exshade
This program demonstrates how to draw Gouraud shaded (lit) sprites. In an apparently black screen, a planet like sprite is drawn close to the middle of the...
exspline
This program demonstrates the use of spline curves to create smooth paths connecting a number of node points. This can be useful for constructing realistic...
exsprite
This example demonstrates how to use datafiles, various sprite drawing routines and flicker-free animation. Why is the animate() routine coded in that way? As...
exstars
This program draws a 3D star field (depth-cued) and a polygon starship (controllable with the keyboard cursor keys), using the Allegro math functions.
exstream
This program shows how to use the audio stream functions to transfer large blocks of sample data to the sound card. In this case, the sample data is generated...
exswitch
This program shows how to control the console switching mode, and let your program run in the background. These functions don't apply to every platform and...
exsyscur
This program demonstrates the use of hardware accelerated mouse cursors.
extimer
This program demonstrates how to use the timer routines. These can be a bit of a pain, because you have to be sure you lock all the memory that is used inside...
extract_font_range
This function extracts a character range from a font and returns a new font that contains only the range of characters selected by this function. You can pass...
extrans
This program demonstrates how to use the lighting and translucency functions. The first part of the example will show a dark screen illuminated by a spotlight...
extrans2
This program demonstrates how to draw trans and lit sprites and flip them at the same time, using draw_sprite_ex() function. It displays several images moving...
extruec
This program shows how to specify colors in the various different truecolor pixel formats. The example shows the same screen (a few text lines and three...
exunicod
This program demonstrates the use of the 16-bit Unicode text encoding format with Allegro. The example displays a message translated to different languages...
exupdate
This program demonstrates how to support double buffering, page flipping, and triple buffering as options within a single program, and how to make things run at...
exxfade
This program demonstrates how to load and display bitmap files in truecolor video modes, and how to crossfade between them. You have to use this example from...
exzbuf
This program demonstrates how to use Z-buffered polygons and floating point 3D math routines. It also provides a simple way to compute fps (frames per second)...
fade_from
Fades gradually from the source palette to the dest palette. The speed is from 1 (the slowest) up to 64 (instantaneous). Note that this function will block your...
fade_from_range
Gradually fades a part of the palette from the source palette to the dest palette. The speed is from 1 (the slowest) up to 64 (instantaneous). This routine only...
fade_in
Fades gradually from a black screen to the specified palette. The speed is from 1 (the slowest) up to 64 (instantaneous). Note that this function will block...
fade_in_range
Gradually fades a part of the palette from a black screen to the specified palette. The speed is from 1 (the slowest) up to 64 (instantaneous). This routine...
fade_interpolate
Calculates a temporary palette part way between source and dest, returning it in the output parameter. The position between the two extremes is specified by the...
fade_out
Fades gradually from the current palette to a black screen. The speed is from 1 (the slowest) up to 64 (instantaneous). Note that this function will block your...
fade_out_range
Gradually fades a part of the palette from the current palette to a black screen. The speed is from 1 (the slowest) up to 64 (instantaneous). This routine only...
fastline
Faster version of the previous function. Note that pixel correctness is not guaranteed for this function.
file_exists
Checks whether a file matching the given name and attributes (see beginning of this chapter) exists. If `aret' is not NULL, it will be set to the attributes of...
file_select_ex
Displays the Allegro file selector, with the message as caption. The path parameter contains the initial filename to display (this can be used to set the...
file_size_ex
Returns the size of a file, in bytes. If the file does not exist or an error occurs, it will return zero and store the system error code in errno.
file_time
Returns the modification time (number of seconds since 00:00:00 GMT 1/1/1970) of a file. If the file does not exist or an error occurs, it will return zero and...
find_allegro_resource
Searches for a support file, eg. `allegro.cfg' or `language.dat'. Passed a resource string describing what you are looking for, along with extra optional...
find_datafile_object
Searches an already loaded datafile for an object with the specified name. In the name you can use `/' and `#' separators for nested datafile paths.
find_dialog_focus
Searches the dialog for the object which has the input focus, returning an index or -1 if the focus is not set. This is useful if you are calling do_dialog()...
fixacos
This function finds the inverse cosine of a value using a lookup table. The input value must be a fixed point radian. The inverse cosine is defined only in the...
fixadd
Although fixed point numbers can be added with the normal '+' integer operator, that doesn't provide any protection against overflow. If overflow is a problem...
fixasin
This function finds the inverse sine of a value using a lookup table. The input value must be a fixed point value. The inverse sine is defined only in the...
fixatan
This function finds the inverse tangent of a value using a lookup table. The input value must be a fixed point radian. The inverse tangent is the value whose...
fixatan2
This is a fixed point version of the libc atan2() routine. It computes the arc tangent of `y / x', but the signs of both arguments are used to determine the...
fixceil
Returns the smallest integer not less than x. That is, it rounds towards positive infinity.
fixcos
This function finds the cosine of a value using a lookup table. The input value must be a fixed point binary angle.
fixdiv
A fixed point value can be divided by an integer with the normal `/' operator. To divide two fixed point values, though, you must use this function. If a...
fixed
This is a fixed point integer which can replace float with similar results and is faster than float on low end machines. Read chapter "Fixed point math...
fix_filename_case
Converts the filename stored in `path' to a standardised case. On DOS platforms, they will be entirely uppercase. On other platforms this function doesn't do...
fix_filename_slashes
Converts all the directory separators in the filename stored in `path' to a standard character. On DOS and Windows platforms, this is a backslash. On most other...
fixfloor
Returns the greatest integer not greater than x. That is, it rounds towards negative infinity.
fixhypot
Fixed point hypotenuse (returns the square root of `x*x + y*y'). This should be better than calculating the formula yourself manually, since the error is much...
fixmul
A fixed point value can be multiplied or divided by an integer with the normal `*' and `/' operators. To multiply two fixed point values, though, you must use...
fixsin
This function finds the sine of a value using a lookup table. The input value must be a fixed point binary angle.
fixsqrt
This finds out the non negative square root of `x'. If `x' is negative, `errno' is set to EDOM and the function returns zero.
fixsub
Although fixed point numbers can be subtracted with the normal '-' integer operator, that doesn't provide any protection against overflow. If overflow is a...
fixtan
This function finds the tangent of a value using a lookup table. The input value must be a fixed point binary angle.
fixtof
Converts fixed point to floating point.
fixtoi
Converts fixed point to integer, rounding as required to the nearest integer.
fixtorad_r
This constant gives a ratio which can be used to convert a fixed point number in binary angle format to a fixed point number in radians.
fixup_datafile
If you are using compiled datafiles (produced by the dat2s and dat2c utilities) on a platform that doesn't support constructors (currently any non GCC-based...
fli_bitmap
Contains the current frame of the FLI/FLC animation. If there is no open animation, its value will be NULL.
fli_bmp_dirty_from
These variables are set by next_fli_frame() to indicate which part of the fli_bitmap has changed since the last call to reset_fli_variables(). If...
fli_frame
Global variable containing the current frame number in the FLI file. This is useful for synchronising other events with the animation, for instance you could...
fli_pal_dirty_from
These variables are set by next_fli_frame() to indicate which part of the fli_palette has changed since the last call to reset_fli_variables(). If...
fli_palette
Contains the current FLI palette.
fli_timer
Global variable for timing FLI playback. When you open an FLI file, a timer interrupt is installed which increments this variable every time a new frame should...
floodfill
Floodfills an enclosed area, starting at point (x, y), with the specified color.
flush_config_file
Writes the current config file to disk if the contents have changed since it was loaded or since the latest call to the function.
font
A simple 8x8 fixed size font (the mode 13h BIOS default). If you want to alter the font used by the GUI routines, change this to point to one of your own fonts...
FONT
A structure holding an Allegro font, usually created beforehand with the grabber tool or Allegro's default font. Read chapter "Fonts" for a description on how...
font_has_alpha
This function goes through all pixels of all glyphs in the font and looks for alpha values.
for_each_file_ex
Finds all the files on disk which match the given wildcard specification and file attributes, and executes callback() once for each. Basically, this is a...
free_audio_stream_buffer
Call this function after get_audio_stream_buffer() returns a non-NULL address, to indicate that you have loaded a new block of samples to that location and the...
free_config_entries
Once you are done with the string arrays filled in by list_config_entries and list_config_sections, you can free them again with this function. The passed array...
free_lzss_pack_data
Frees an LZSS_PACK_DATA structure created with create_lzss_pack_data().
free_lzss_unpack_data
Frees an LZSS_UNPACK_DATA structure created with create_lzss_pack_data.
freeze_mouse_flag
If this flag is set, the mouse pointer won't be redrawn when the mouse moves. This can avoid the need to hide the pointer every time you draw to the screen, as...
ftofix
Converts a floating point value to fixed point. Unlike itofix(), this function clamps values which could overflow the type conversion, setting `errno' to ERANGE...
generate_332_palette
Constructs a fake truecolor palette, using three bits for red and green and two for the blue. The load_bitmap() function fills the palette parameter with this...
generate_optimized_palette
Generates a 256-color palette suitable for making a reduced color version of the specified truecolor image. The rsvd parameter points to a table indicating...
geta32
Given a color in a 32-bit pixel format, this function extracts the alpha component (ranging 0-255).
get_align_matrix
Rotates a matrix so that it is aligned along the specified coordinate vectors (they need not be normalized or perpendicular, but the up and front must not be...
get_align_matrix_f
Floating point version of get_align_matrix().
get_audio_stream_buffer
You must call this function at regular intervals while an audio stream is playing, to provide the next buffer of sample data (the smaller the stream buffer...
get_camera_matrix
Constructs a camera matrix for translating world-space objects into a normalised view space, ready for the perspective projection. The x, y, and z parameters...
get_camera_matrix_f
Floating point version of get_camera_matrix().
get_clip_rect
Returns the clipping rectangle for the specified bitmap.
get_clip_state
Returns non-zero if clipping is turned on for the specified bitmap and zero otherwise.
get_color
Retrieves the specified palette entry.
get_color_conversion
Returns the current color conversion mode.
get_color_depth
Returns the current pixel format. This can be very useful to know in order to write generic functions which select a different code path internally depending on...
get_compiled_sprite
Creates a compiled sprite based on the specified bitmap (which must be a memory bitmap). Compiled sprites are device-dependent, so you have to specify whether...
get_config_argv
Reads a token list (words separated by spaces) from the current config file. The token list is stored in a temporary buffer that will be clobbered by the next...
get_config_float
Reads a floating point variable from the current config file. See the comments about get_config_string().
get_config_hex
Reads an integer variable from the current config file, in hexadecimal format. See the comments about get_config_string().
get_config_id
Reads a 4-letter driver ID variable from the current config file. See the comments about get_config_string().
get_config_int
Reads an integer variable from the current config file. See the comments about get_config_string().
get_config_string
Retrieves a string variable from the current config file. The section name may be set to NULL to read variables from the root of the file, or used to control...
get_config_text
This function is primarily intended for use by internal library code, but it may perhaps be helpful to application programmers as well. It uses the...
get_datafile_property
Finds the property type of a DATAFILE object. The type parameter must be a value created with the DAT_ID() macro.
get_desktop_resolution
Finds out the currently selected desktop resolution. You can use this information to avoid creating windows bigger than the current resolution. This is...
get_display_switch_mode
Returns the current display switching mode, in the same format passed to set_display_switch_mode().
get_executable_name
Fills `buf' with the full path to the current executable, writing at most `size' bytes. This generally comes from `argv[0]' but on Unix systems it tries to get...
get_extension
Finds out the extension of the filename (with or without path information).
get_filename
Finds out the filename portion of a completely specified file path. Both `\' and `/' are recognized as directory separators under DOS and Windows. However, only...
get_filename_encoding
Returns the encoding currently assumed for filenames.
get_font_range_begin
This function allows you to find out the start of a specific character range for a font. You can pass -1 for the `range' parameter if you want to know the start...
get_font_range_end
This function allows you to find out the index to the last character of a character range for a font. You can pass -1 for the range parameter if you want to...
get_font_ranges
Use this function to find out the number of character ranges in a font. You should query each of these ranges with get_font_range_begin() and...
get_gfx_mode
This function will let you determine which graphics driver is currently set by allegro. If no graphics driver is set, it will return GFX_NONE.
get_gfx_mode_list
Obtains a list of available video modes. Allegro game programming library.
get_gfx_mode_type
This function lets you determine the types of operating modes that a specific graphics card driver operates in. It will tell you whether it is a windowed...
get_hardware_volume
Retrieves the hardware sound output volume, both for digital samples and MIDI playback, as integers from 0 to 255, or -1 if the information is not available...
get_midi_length
This function will simulate playing the given MIDI, from start to end, to determine how long it takes to play. After calling this function, midi_pos will...
get_mixer_bits
Returns the mixer bit depth (8 or 16).
get_mixer_buffer_length
Returns the number of samples per channel in the mixer buffer.
get_mixer_channels
Returns the number of output channels. 2 for stereo, 1 for mono, 0 if the mixer isn't active.
get_mixer_frequency
Returns the mixer frequency, in Hz.
get_mixer_quality
Returns the current mixing quality, as specified by the `quality' config variable, or a previous call to set_mixer_quality().
get_mixer_voices
Returns the number of voices allocated to the mixer.
get_mouse_mickeys
Measures how far the mouse has moved since the last call to this function. The values of mickeyx and mickeyy will become negative if the mouse is moved left or...
get_palette
Retrieves the entire palette of 256 colors. You should provide an array of 256 RGB structures to store it in.
get_palette_range
Retrieves the palette entries between from and to (inclusive: pass 0 and 255 to get the entire palette).
getpixel
Reads a pixel from point (x, y) in the bitmap.
_getpixel
Faster inline versions of getpixel() for specific color depths. These won't work in mode-X, and don't do any clipping, so you must make sure the point lies...
getr
Given a color in the format being used by the current video mode, these functions extract one of the red, green, blue, or alpha components (ranging 0-255)...
getr8
Given a color in a display dependent format, these functions extract one of the red, green, or blue components (ranging 0-255).
getr_depth
Given a color in the format being used by the specified color depth, these functions extract one of the red, green, blue, or alpha components (ranging 0-255)...
get_refresh_rate
Returns the current refresh rate, if known (not all drivers are able to report this information). Returns zero if the actual rate is unknown.
get_rle_sprite
Creates an RLE sprite based on the specified bitmap (which must be a memory bitmap). Remember to free this RLE sprite later to avoid memory leaks.
get_rotation_matrix
Constructs a transformation matrix which will rotate points around all three axes by the specified amounts (given in binary, 256 degrees to a circle format)...
get_rotation_quat
Constructs a quaternion that will rotate points around all three axes by the specified amounts (given in binary, 256 degrees to a circle format).
get_scaling_matrix
Constructs a scaling matrix, storing it in m. When applied to the point (px, py, pz), this matrix will produce the point (px*x, py*y, pz*z). In other words, it...
get_sound_input_cap_bits
Checks which audio input sample formats are supported. Allegro game programming library.
get_sound_input_cap_parm
Checks whether the specified recording frequency, number of bits, and mono/stereo mode are supported (and how) by the current audio driver.
get_sound_input_cap_rate
Returns the maximum possible sample frequency for recording in the specified format, or zero if these settings are not supported. The bits parameter is the...
get_sound_input_cap_stereo
Checks whether the current audio input driver is capable of stereo recording.
get_transformation_matrix
Constructs a transformation matrix which will rotate points around all three axes by the specified amounts (given in binary, 256 degrees to a circle format)...
get_transformation_matrix_f
Floating point version of get_transformation_matrix().
get_translation_matrix
Constructs a translation matrix, storing it in m. When applied to the point (px, py, pz), this matrix will produce the point (px+x, py+y, pz+z). In other words...
get_uformat
Finds out what text encoding format is currently selected. This function is probably useful only if you are writing an Allegro addon dealing with text strings...
get_vector_rotation_matrix
Constructs a transformation matrix which will rotate points around the specified x,y,z vector by the specified angle (given in binary, 256 degrees to a circle...
get_vector_rotation_quat
Constructs a quaternion that will rotate points around the specified x,y,z vector by the specified angle (given in binary, 256 degrees to a circle format).
get_volume
Retrieves the global sound output volume, both for digital samples and MIDI playback, as integers from 0 to 255. Parameters digi_volume and midi_volume must be...
get_x_rotate_matrix
Construct X axis rotation matrices, storing them in m. When applied to a point, these matrices will rotate it about the X axis by the specified angle (given in...
get_x_rotate_quat
Construct axis rotation quaternions, storing them in q. When applied to a point, these quaternions will rotate it about the relevant axis by the specified angle...
get_y_rotate_matrix
Construct Y axis rotation matrices, storing them in m. When applied to a point, these matrices will rotate it about the Y axis by the specified angle (given in...
get_z_rotate_matrix
Construct Z axis rotation matrices, storing them in m. When applied to a point, these matrices will rotate it about the Z axis by the specified angle (given in...
gfx_capabilities
Bitfield describing the capabilities of the current graphics driver and video hardware. This may contain combination any of the flags: GFX_CAN_SCROLL: Indicates...
GFX_MODE
Stores video mode information. Allegro game programming library.
GFX_MODE_LIST
Stores an array of GFX_MODE structures. Allegro game programming library.
gfx_mode_select
Displays the Allegro graphics mode selection dialog, which allows the user to select a screen mode and graphics card. The initial values at the addresses...
gfx_mode_select_ex
Extended version of the graphics mode selection dialog, which also allows the user to select the color depth. As with gfx_mode_select, the values stored at the...
gfx_mode_select_filter
Even more extended version of the graphics mode selection dialog, which allows the programmer to customize the contents of the dialog and the user to select the...
grab_font_from_bitmap
This function is the work-horse of load_bitmap_font, and can be used to grab a font from a bitmap in memory. You can use this if you want to generate or modify...
gui_fg_color
The foreground and background colors for the standard dialogs (alerts, menus, and the file selector). They default to 255 and 0.
gui_font_baseline
If set to a non-zero value, adjusts the keyboard shortcut underscores to account for the height of the descenders in your font.
gui_get_screen
This function returns the current bitmap surface the GUI routines will use for drawing. Note that this function will return screen if you have called...
gui_menu_draw_menu
If set, these functions will be called whenever a menu needs to be drawn, so you can change how menus look. gui_menu_draw_menu() is passed the position and size...
gui_mg_color
The color used for displaying greyed-out dialog objects (with the D_DISABLED flag set). Defaults to 8.
gui_mouse_focus
If set, the input focus follows the mouse pointer around the dialog, otherwise a click is required to move it.
gui_mouse_x
Hook functions, used by the GUI routines whenever they need to access the mouse state. By default these just return copies of the mouse_x, mouse_y, mouse_z, and...
gui_set_screen
This function can be used to change the bitmap surface the GUI routines draw to. This can be useful if you are using a double buffering or page flipping system...
gui_shadow_box_proc
If set, these functions will be used by the standard Allegro dialogs. This allows you to customise the look and feel, much like gui_fg_color and gui_bg_color...
gui_strlen
Helper function for use by the GUI routines. Returns the length of a string in pixels, ignoring '&' characters.
gui_textout_ex
Helper function for use by the GUI routines. Draws a text string onto the screen, interpreting the '&' character as an underbar for displaying keyboard...
hline
Draws a horizontal line onto the bitmap, from point (x1, y) to (x2, y). Note: hline() is implemented as an alias to another function. See...
hook_config_section
Takes control of the specified config file section, so that your hook functions will be used to manipulate it instead of the normal disk file access. If both...
hsv_to_rgb
Convert color values between the HSV and RGB color spaces. The RGB values range from 0 to 255, hue is from 0 to 360, and saturation and value are from 0 to 1.
identity_matrix
Global variables containing the 'do nothing' identity matrix. Multiplying by the identity matrix has no effect.
identity_quat
Global variable containing the 'do nothing' identity quaternion. Multiplying by the identity quaternion has no effect.
init_dialog
This function provides lower level access to the same functionality as do_dialog(), but allows you to combine a dialog box with your own program control...
initialise_joystick
Deprecated. Use install_joystick() instead.
init_menu
This function provides lower level access to the same functionality as do_menu(), but allows you to combine a popup menu with your own program control...
install_allegro
Initialises the Allegro library. You must call either this or allegro_init() before doing anything other than using the Unicode routines. If you want to use a...
install_int
Installs a user timer handler, with the speed given as the number of milliseconds between ticks. This is the same thing as install_int_ex(proc...
install_int_ex
Adds a function to the list of user timer handlers or, if it is already installed, retroactively adjusts its speed (i.e makes as though the speed change...
install_joystick
Installs Allegro's joystick handler, and calibrates the centre position values. The type parameter should usually be JOY_TYPE_AUTODETECT, or see the platform...
install_keyboard
Installs the Allegro keyboard interrupt handler. You must call this before using any of the keyboard input routines. Once you have set up the Allegro handler...
install_keyboard_hooks
You should only use this function if you *aren't* using the rest of the keyboard handler. It should be called in the place of install_keyboard(), and lets you...
install_mouse
Installs the Allegro mouse handler. You must do this before using any other mouse functions.
install_param_int
Like install_int(), but the callback routine will be passed a copy of the specified void pointer parameter. To disable the handler, use remove_param_int()...
install_param_int_ex
Like install_int_ex(), but the callback routine will be passed a copy of the specified void pointer parameter. To disable the handler, use remove_param_int()...
install_sound
Initialises the sound module. You should normally pass DIGI_AUTODETECT and MIDI_AUTODETECT as the driver parameters to this function, in which case Allegro will...
install_sound_input
Initialises the sound recorder module. You must install the normal sound playback system before calling this routine. The two card parameters should use the...
install_timer
Installs the Allegro timer interrupt handler. You must do this before installing any user timer routines, and also before displaying a mouse pointer, playing...
is_color_font
This function checks if the given font is a color font, as opposed to a monochrome font.
is_compatible_font
This function compares the two fonts, which you can use to find out if Allegro is capable of merging them.
is_inside_bitmap
Returns non-zero if point (x, y) lies inside the bitmap. If `clip' is non-zero, the function compares the coordinates with the clipping rectangle, that is it...
is_linear_bitmap
Returns TRUE if bmp is a linear bitmap, i.e. a bitmap that can be accessed linearly within each scanline (for example a memory bitmap, the DOS VGA or SVGA...
is_memory_bitmap
Returns TRUE if bmp is a memory bitmap, ie. it was created by calling create_bitmap() or loaded from a grabber datafile or image file. Memory bitmaps can be...
is_mono_font
This function checks if the given font is a mono font, as opposed to a color font.
is_planar_bitmap
Returns TRUE if bmp is a planar (mode-X or Xtended mode) screen bitmap.
is_relative_filename
Returns TRUE if the filename is relative or FALSE if it is absolute. Note that an absolute filename under DOS (with a device separator) will be considered as...
is_same_bitmap
Returns TRUE if the two bitmaps describe the same drawing surface, ie. the pointers are equal, one is a sub-bitmap of the other, or they are both sub-bitmaps of...
is_screen_bitmap
Returns TRUE if bmp is the screen bitmap, or a sub-bitmap of the screen.
is_sub_bitmap
Returns TRUE if bmp is a sub-bitmap.
is_system_bitmap
Returns TRUE if bmp is a system bitmap object, or a sub-bitmap of one.
is_trans_font
This function checks if the given font is a color font using draw_trans_sprite to render glyphs.
is_video_bitmap
Returns TRUE if bmp is the screen bitmap, a video memory bitmap, or a sub-bitmap of either.
is_windowed_mode
This function can be used to detect whether or not set_gfx_mode() selected a windowed mode.
itofix
Converts an integer to fixed point. This is the same thing as x<<16. Remember that overflows (trying to convert an integer greater than 32767) and underflows...
joy
Global array of joystick state information, which is updated by the poll_joystick() function. Only the first num_joysticks elements will contain meaningful...
JOYSTICK_AXIS_INFO
Stores joystick axis information. Allegro game programming library.
JOYSTICK_BUTTON_INFO
Stores joystick button information. Allegro game programming library.
JOYSTICK_INFO
Stores information about joysticks. Allegro game programming library.
JOYSTICK_STICK_INFO
Stores joystick stick information. Allegro game programming library.
key
Array of flags indicating the state of each key, ordered by scancode. Wherever possible these values will be updated asynchronously, but if...
keyboard_callback
If set, this function is called by the keyboard handler in response to every keypress. It is passed a copy of the value that is about to be added into the input...
keyboard_lowlevel_callback
If set, this function is called by the keyboard handler in response to every keyboard event, both presses (including keyboard repeat rate) and releases. It will...
keyboard_needs_poll
Returns TRUE if the current keyboard driver is operating in polling mode.
keyboard_ucallback
Unicode-aware version of keyboard_callback(). If set, this function is called by the keyboard handler in response to every keypress. It is passed the character...
key_led_flag
By default, the capslock, numlock, and scroll-lock keys toggle the keyboard LED indicators when they are pressed. If you are using these keys for input in your...
keypressed
Returns TRUE if there are keypresses waiting in the input buffer. You can use this to see if the next call to readkey() is going to block or to simply wait for...
key_shifts
Bitmask containing the current state of shift/ctrl/alt, the special Windows keys, and the accent escape characters. Wherever possible this value will be updated...
line
Draws a line onto the bitmap, from point (x1, y1) to (x2, y2).
list_config_entries
This function can be used to get a list of all entries in the given config section. The names parameter is a pointer to an array of strings. If it points to a...
list_config_sections
The names parameter is a pointer to an array of strings. If it points to a NULL pointer, the list will be allocated, else it will be re-allocated. After the...
load_bios_font
Loads a 8x8 or 8x16 BIOS format font. You shouldn't normally call this routine directly.
load_bitmap
Loads a bitmap from a file. The palette data will be stored in the second parameter, which should be an array of 256 RGB structures. At present this function...
load_bitmap_font
Tries to grab a font from a bitmap. The bitmap can be in any format that load_bitmap understands. The size of each character is determined by the layout of the...
load_bmp
Loads an 8-bit, 16-bit, 24-bit or 32-bit Windows or OS/2 BMP file.
load_bmp_pf
A version of load_bmp() which reads from a packfile.
load_datafile
Loads a datafile into memory in one go. If the datafile has been encrypted, you must first call packfile_password() to set the appropriate key. If the datafile...
load_datafile_callback
Loads a datafile into memory, calling the specified hook function once for each object in the file, passing it a pointer to the object just read.
load_datafile_object
Loads a specific object from a datafile. This won't work if you strip the object names from the file, and it will be very slow if you save the file with global...
load_datafile_object_indexed
This loads a single object, using the index created previously with create_datafile_index. See create_datafile_index for an example.
load_dat_font
Loads a FONT from an Allegro datafile. You can set param parameter to point to an array that holds two strings that identify the font and the palette in the...
load_font
Loads a font from a file. At present, this supports loading fonts from a GRX format .fnt file, a 8x8 or 8x16 BIOS format .fnt file, a datafile or any bitmap...
load_grx_font
Loads a GRX format font. You shouldn't normally call this routine directly.
load_grx_or_bios_font
Loads either a BIOS or GRX format font. You shouldn't normally call this routine directly.
load_ibk
Reads in a .IBK patch definition file for use by the Adlib driver. If drums is set, it will load it as a percussion patch set, otherwise it will use it as a...
load_joystick_data
Restores calibration data previously stored by save_joystick_data() or the setup utility. This sets up all aspects of the joystick code: you don't even need to...
load_lbm
Loads a 256-color IFF ILBM/PBM file.
load_midi
Loads a MIDI file (handles both format 0 and format 1).
load_midi_patches
Forces the MIDI driver to load the entire set of patches ready for use. You will not normally need to call this, because Allegro automatically loads whatever...
load_pcx
Loads a 256-color or 24-bit truecolor PCX file.
load_pcx_pf
A version of load_pcx() which reads from a packfile.
load_sample
Loads a sample from a file, supporting both mono and stereo WAV and mono VOC files, in 8 or 16-bit formats, as well as formats handled by functions registered...
load_tga
Loads a 256-color, 15-bit hicolor, 24-bit truecolor, or 32-bit truecolor+alpha TGA file.
load_tga_pf
A version of load_tga() which reads from a packfile.
load_txt_font
This function can be used to load scripted fonts. The script file contains a number of lines in the format "filename start end", which specify the source file...
load_voc
Loads a sample from a Creative Labs VOC file.
load_voc_pf
A version of load_voc() which reads from a packfile.
load_wav
Loads a sample from a RIFF WAV file.
load_wav_pf
A version of load_wav() which reads from a packfile.
lock_bitmap
Under DOS, locks all the memory used by a bitmap. You don't normally need to call this function unless you are doing very weird things in your program.
LOCK_FUNCTION
Due to interrupts, you are required to lock all the memory used by your timer routines. See the description of install_int_ex() for a more detailed explanation...
lock_midi
Under DOS, locks all the memory used by a MIDI file. You don't normally need to call this function because load_midi() does it for you.
lock_sample
Under DOS, locks all the memory used by a sample. You don't normally need to call this function because load_sample() and create_sample() do it for you.
LOCK_VARIABLE
Due to interrupts, you are required to lock all the memory used by your timer routines. See the description of install_int_ex() for a more detailed explanation...
LZSS_PACK_DATA
Opaque structure for handling LZSS compression. Read chapter "File and compression routines for a description on how to obtain/use this structure.
lzss_read
Unpacks from `dat' into `buf', until either EOF is reached or `s' bytes have been extracted from `file'.
LZSS_UNPACK_DATA
Opaque structure for handling LZSS decompression. Read chapter "File and compression routines for a description on how to obtain/use this structure.
lzss_write
Packs `size' bytes from `buf', using the pack information contained in `dat'. The compressed bytes will be stored in `file'.
make_absolute_filename
Makes an absolute filename from an absolute path and a relative filename, storing at most `size' bytes into the `dest' buffer. This is like calling...
makeacol
Convert RGBA colors into display dependent pixel formats. In anything less than a 32-bit mode, these are the same as calling makecol() or makecol_depth(), but...
makeacol32
Converts an RGBA color into a 32-bit display pixel format, which includes an alpha (transparency) value. There are no versions of this routine for other color...
makecol
Converts colors from a hardware independent format (red, green, and blue values ranging 0-255) to the pixel format required by the current video mode, calling...
makecol15_dither
Given both a color value and a pixel coordinate, calculate a dithered 15 or 16-bit RGB value. This can produce better results when reducing images from...
makecol8
These functions convert colors from a hardware independent form (red, green, and blue values ranging 0-255) into various display dependent pixel formats...
makecol_depth
Converts colors from a hardware independent format (red, green, and blue values ranging 0-255) to the pixel format required by the specified color depth.
make_relative_filename
Attempts to make a relative filename from an absolute path and an absolute filename, storing at most `size' bytes into the `dest' buffer. This function won't...
make_trans_font
This function converts a font to use transparency for drawing. That is, each glyph in the font will be drawn with draw_trans_sprite, so you can use the same...
MAKE_VERSION
This macro can be used to check if some Allegro version is (binary) compatible with the current version. It is safe to use > and < to check if one version is...
MASK_COLOR_8
Constants representing the colors used to mask transparent sprite pixels for each color depth. In 256-color resolutions this is zero, and in truecolor modes it...
masked_blit
Like blit(), but skips transparent pixels, which are marked by a zero in 256-color modes or bright pink for truecolor data (maximum red and blue, zero green)...
masked_stretch_blit
Like masked_blit(), except it can scale images (so the source and destination rectangles don't need to be the same size). This routine doesn't do as much safety...
MATRIX
Fixed point matrix structure. Allegro game programming library.
MATRIX_f
Floating point matrix structure. Allegro game programming library.
matrix_mul
Multiplies two matrices, storing the result in out (this may be a duplicate of one of the input matrices, but it is faster when the inputs and output are all...
matrix_to_quat
Constructs a quaternion from a rotation matrix. Translation is discarded during the conversion. Use get_align_matrix_f() if the matrix is not orthonormalized...
MENU
Stores the entries of a menu. Allegro game programming library.
MENU_PLAYER
A structure which holds GUI data used internally by Allegro. Read the documentation of init_menu() for a description on how to obtain/use this structure.
merge_fonts
This function merges the character ranges from two fonts and returns a new font containing all characters in the old fonts. In general, you cannot merge fonts...
MIDI
A structure holding MIDI data. Read chapter "Music routines (MIDI)" for a description on how to obtain/use this structure.
midi_loop_start
The loop start and end points, set by the play_looped_midi() function. These may safely be altered while the music is playing, but you should be sure they are...
midi_msg_callback
Hook functions allowing you to intercept MIDI player events. If set to anything other than NULL, these routines will be called for each MIDI message...
midi_out
Streams a block of MIDI commands into the player in real-time, allowing you to trigger notes, jingles, etc, over the top of whatever MIDI file is currently...
midi_pause
Pauses the MIDI player. Allegro game programming library.
midi_pos
Stores the current position (beat number) in the MIDI file, or contains a negative number if no music is currently playing. Useful for synchronising animations...
midi_recorder
If set, this function is called by the MIDI input driver whenever a new byte of MIDI data becomes available. It runs in an interrupt context, so it must execute...
midi_resume
Resumes playback of a paused MIDI file.
midi_seek
Seeks to the given midi_pos in the current MIDI file. If the target is earlier in the file than the current midi_pos it seeks from the beginning; otherwise it...
midi_time
Contains the position in seconds in the currently playing midi. This is useful if you want to display the current song position in seconds, not as beat number.
mouse_callback
Called by the interrupt handler whenever the mouse moves or one of the buttons changes state. This function must be in locked memory, and must execute _very_...
mouse_needs_poll
Returns TRUE if the current mouse driver is operating in polling mode.
mouse_on_screen
This function can be useful to prevent having two mouse pointers on the screen at the same time when running your program in windowed mode and drawing the mouse...
mouse_sprite
Global variables containing the current mouse sprite and the focus point. These are read-only, and only to be modified using the set_mouse_sprite() and...
mouse_x
Global variables containing the current mouse position and button state. Wherever possible these values will be updated asynchronously, but if...
need_uconvert
Given a pointer to a string (`s'), a description of the type of the string (`type'), and the type that you would like this string to be converted into...
next_fli_frame
Reads the next frame of the current animation file. If `loop' is not zero, the player will cycle when it reaches the end of the file, otherwise it will return...
normalize_vector
Converts the vector (*x, *y, *z) to a unit vector. This points in the same direction as the original vector, but has a length of one.
num_joysticks
Global variable containing the number of active joystick devices. The current drivers support a maximum of eight controllers.
object_message
Sends a message to an object and returns the answer it has generated. Remember that the first parameter is the dialog object (not a whole array) that you wish...
offer_focus
Offers the input focus to a particular object. Normally the function sends the MSG_WANTFOCUS message to query whether the object is willing to accept the focus...
open_fli
Open FLI files ready for playing, reading the data from disk or memory respectively. Information about the current FLI is held in the global variables...
os_multitasking
Set by allegro_init() to either TRUE or FALSE depending on whether your Operating System is multitasking or not.
os_type
Stores the detected type of the OS. Allegro game programming library.
os_version
The major and minor version of the Operating System currently running. Set by allegro_init(). If Allegro for some reason was not able to retrieve the version of...
override_config_data
Version of override_config_file() which uses a block of data that has already been read into memory. The length of the block has to be specified in bytes.
override_config_file
Specifies a file containing config overrides. These settings will be used in addition to the parameters in the main config file, and where a variable is present...
pack_fclose
Closes the stream `f' previously opened with pack_fopen() or pack_fopen_vtable(). After you have closed the stream, performing operations on it will yield...
pack_fclose_chunk
Closes a sub-chunk of a file, previously obtained by calling pack_fopen_chunk().
pack_feof
Finds out if you have reached the end of the file. It does not wait for you to attempt to read beyond the end of the file, contrary to the ISO C feof()...
pack_ferror
Since EOF is used to report errors by some functions, it's often better to use the pack_feof() function to check explicitly for end of file and pack_ferror() to...
pack_fgets
Reads a line from the stream `f', storing it at location pointed to by `p'. Stops when a linefeed is encountered, or `max' bytes have been read. The end of line...
PACKFILE
A packfile structure, similar to the libc FILE structure. Read chapter "File and compression routines" for a description on how to obtain/use this structure...
packfile_password
Sets the encryption password to be used for all read/write operations on files opened in future using Allegro's packfile functions (whether they are compressed...
PACKFILE_VTABLE
Packfile vtable structure, for custom packfiles. Allegro game programming library.
pack_fopen
Opens a file according to mode, which may contain any of the flags: `r' - open file for reading. `w' - open file for writing, overwriting any existing data. `p'...
pack_fopen_chunk
Opens a sub-chunk of a file. Chunks are primarily intended for use by the datafile code, but they may also be useful for your own file routines. A chunk...
pack_fopen_vtable
Creates a new packfile structure that uses the functions specified in the vtable instead of the standard functions. The data pointer by `vtable' and `userdata'...
pack_fputs
Writes a string to the stream `f'. The input string is converted from the current text encoding format to UTF-8 before writing. Newline characters are written...
pack_fread
Reads `n' bytes from the stream `f', storing them at the memory location pointed to by `p'.
pack_fseek
Moves the position indicator of the stream `f'. Unlike the standard fseek() function, this only supports forward movements relative to the current position and...
pack_fwrite
Writes `n' bytes to the stream `f' from memory location pointed to by `p'.
pack_getc
Returns the next character from the stream `f', or EOF if the end of the file has been reached.
pack_igetl
Like pack_getc, but reads a 32-bit long from a file, using Intel byte ordering (least significant byte first, a.k.a. little-endian).
pack_igetw
Like pack_getc, but reads a 16-bit word from a file, using Intel byte ordering (least significant byte first, a.k.a. little-endian).
pack_iputl
Like pack_putc, but writes a 32-bit long to a file, using Intel byte ordering (least significant byte first, a.k.a. little-endian).
pack_iputw
Like pack_putc, but writes a 16-bit word to a file, using Intel byte ordering (least significant byte first, a.k.a. little-endian).
pack_mgetl
Like pack_getc, but reads a 32-bit long from a file, using Motorola byte ordering (most significant byte first, a.k.a. big-endian).
pack_mgetw
Like pack_getc, but reads a 16-bit word from a file, using Motorola byte ordering (most significant byte first, a.k.a. big-endian).
pack_mputl
Like pack_putc, but writes a 32-bit long to a file, using Motorola byte ordering (most significant byte first, a.k.a. big-endian).
pack_mputw
Like pack_putc, but writes a 16-bit word to a file, using Motorola byte ordering (most significant byte first, a.k.a. big-endian).
pack_putc
Puts a character in the stream f.
pack_ungetc
Puts a character back to the file's input buffer. Like with ungetc from libc, only a single push back is guaranteed. Note: pack_fgets internally uses...
PALETTE
Allegro palettes are arrays of PAL_SIZE RGB entries.
palette_color
Table mapping palette index colors (0-255) into whatever pixel format is being used by the current display mode. In a 256-color mode this just maps onto the...
PAL_SIZE
Preprocessor constant equal to 256.
persp_project
Projects the 3d point (x, y, z) into 2d screen space, storing the result in (*xout, *yout) and using the scaling parameters previously set by calling...
pivot_scaled_sprite
Like rotate_scaled_sprite(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this point.
pivot_scaled_sprite_lit
Like rotate_scaled_sprite_lit(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this point.
pivot_scaled_sprite_trans
Like rotate_scaled_sprite_trans(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this point.
pivot_scaled_sprite_v_flip
Like rotate_scaled_sprite_v_flip(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this point.
pivot_scaled_sprite_v_flip_lit
Like rotate_scaled_sprite_v_flip_lit(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this point.
pivot_scaled_sprite_v_flip_trans
Like rotate_scaled_sprite_v_flip_trans(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates and scales around this...
pivot_sprite
Like rotate_sprite(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
pivot_sprite_lit
Like rotate_sprite_lit(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
pivot_sprite_trans
Like rotate_sprite_trans(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
pivot_sprite_v_flip
Like rotate_sprite_v_flip(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
pivot_sprite_v_flip_lit
Like rotate_sprite_v_flip_lit(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
pivot_sprite_v_flip_trans
Like rotate_sprite_v_flip_trans(), but aligns the point in the sprite given by (cx, cy) to (x, y) in the bitmap, then rotates around this point.
play_audio_stream
This function creates a new audio stream and starts playing it. The length is the size of each transfer buffer in sample frames (not bytes), where a sample...
play_fli
Plays an Autodesk Animator FLI or FLC animation file on the specified BITMAP, reading the data from disk as it is required. If `loop' is not zero, the player...
play_looped_midi
Starts playing a MIDI file with a user-defined loop position. When the player reaches the loop end position or the end of the file (loop_end may be -1 to only...
play_memory_fli
Plays an Autodesk Animator FLI or FLC animation on the specified BITMAP, reading the data from a copy of the file which is held in memory. You can obtain the...
play_midi
Starts playing the specified MIDI file, first stopping whatever music was previously playing. If the loop flag is set to non-zero, the data will be repeated...
play_sample
Triggers a sample at the specified volume, pan position, and frequency. The parameters `vol' and `pan' range from 0 (min/left) to 255 (max/right). Frequency is...
poll_joystick
The joystick handler is not interrupt driven, so you need to call this function every now and again to update the global position values.
poll_keyboard
Wherever possible, Allegro will read the keyboard input asynchronously (ie. from inside an interrupt handler), but on some platforms that may not be possible...
poll_mouse
Wherever possible, Allegro will read the mouse input asynchronously (ie. from inside an interrupt handler), but on some platforms that may not be possible, in...
poll_scroll
This function is used for triple buffering. It checks the status of a hardware scroll previously initiated by the request_scroll() routine.
polygon
Draws a filled polygon with an arbitrary number of corners. Pass the number of vertices and an array containing a series of x, y points (a total of vertices*2...
polygon3d
Draw 3d polygons onto the specified bitmap, using the specified rendering mode. Unlike the regular polygon() function, these routines don't support concave or...
polygon_z_normal
Finds the Z component of the normal vector to the specified three vertices (which must be part of a convex polygon). This is used mainly in back-face culling...
POLYTYPE_ATEX
An affine texture mapped polygon. This stretches the texture across the polygon with a simple 2d linear interpolation, which is fast but not mathematically...
POLYTYPE_ATEX_LIT
Like POLYTYPE_ATEX and POLYTYPE_PTEX, but the global color_map table (for 256-color modes) or blender function (for non-MMX truecolor modes) is used to blend...
POLYTYPE_ATEX_MASK
Like POLYTYPE_ATEX and POLYTYPE_PTEX, but zero texture map pixels are skipped, allowing parts of the texture map to be transparent.
POLYTYPE_ATEX_MASK_LIT
Like POLYTYPE_ATEX_LIT and POLYTYPE_PTEX_LIT, but zero texture map pixels are skipped, allowing parts of the texture map to be transparent.
POLYTYPE_ATEX_MASK_TRANS
Like POLYTYPE_ATEX_TRANS and POLYTYPE_PTEX_TRANS, but zero texture map pixels are skipped.
POLYTYPE_ATEX_TRANS
Render translucent textures. All the general rules for drawing translucent things apply. However, these modes have a major limitation: they only work with...
POLYTYPE_FLAT
A simple flat shaded polygon, taking the color from the `c' value of the first vertex. This polygon type is affected by the drawing_mode() function, so it can...
POLYTYPE_GCOL
A single-color gouraud shaded polygon. The colors for each vertex are taken from the `c' value, and interpolated across the polygon. This is very fast, but will...
POLYTYPE_GRGB
A gouraud shaded polygon which interpolates RGB triplets rather than a single color. In 256-color modes this uses the global rgb_map table to convert the result...
POLYTYPE_PTEX
A perspective-correct texture mapped polygon. This uses the `z' value from the vertex structure as well as the u/v coordinates, so textures are displayed...
pop_config_state
Pops a configuration state previously stored by push_config_state(), replacing the current config source with it.
popup_dialog
Like do_dialog(), but it stores the data on the screen before drawing the dialog and restores it when the dialog is closed. The screen area to be stored is...
position_dialog
Moves an array of dialog objects to the specified screen position (specified as the top left corner of the dialog).
position_mouse
Moves the mouse to the specified screen position. It is safe to call even when a mouse pointer is being displayed.
position_mouse_w
Sets the horizontal mouse wheel position to the specified value.
position_mouse_z
Sets the mouse wheel position variable to the specified value.
push_config_state
Pushes the current configuration state (filename, variable values, etc). onto an internal stack, allowing you to select some other config source and later...
put_backslash
If the last character of the filename is not a `\', `/', `#' or a device separator (ie. `:' under DOS), this routine will concatenate either a `\' or `/' on to...
putpixel
Writes a pixel to the specified position in the bitmap, using the current drawing mode and the bitmap's clipping rectangle.
_putpixel
Like the regular putpixel(), but much faster because they are implemented as an inline assembler functions for specific color depths. These won't work in mode-X...
qnx_get_window
Retrieves a handle to the window used by Allegro. Note that Allegro uses an underlying window even though you don't set any graphics mode, unless you have...
qscale_matrix
Optimised routine for scaling an already generated matrix: this simply adds in the scale factor, so there is no need to build two temporary matrices and then...
qtranslate_matrix
Optimised routine for translating an already generated matrix: this simply adds in the translation offset, so there is no need to build two temporary matrices...
quad3d
Draw 3d quads, using either fixed or floating point vertex structures. These are equivalent to calling polygon3d(bmp, type, tex, 4, v[]) or polygon3d_f(bmp...
QUAT
Stores quaternion information. Allegro game programming library.
quat_interpolate
Constructs a quaternion that represents a rotation between from and to. The argument t can be anything between 0 and 1 and represents where between from and to...
quat_mul
Multiplies two quaternions, storing the result in out. The resulting quaternion will have the same effect as the combination of p and q, ie. when applied to a...
quat_slerp
The same as quat_interpolate(), but allows more control over how the rotation is done.
quat_to_matrix
Constructs a rotation matrix from a quaternion.
radtofix_r
This constant gives a ratio which can be used to convert a fixed point number in radians to a fixed point number in binary angle format.
readkey
Returns the next character from the keyboard buffer, in ASCII format. If the buffer is empty, it waits until a key is pressed. You can see if there are queued...
read_sound_input
Retrieves the most recently recorded audio buffer into the specified location. The buffer size can be obtained by checking the return value from...
reallocate_voice
Switches an already-allocated voice to use a different sample.
rect
Draws an outline rectangle with the two points as its opposite corners.
rectfill
Draws a solid, filled rectangle with the two points as its opposite corners.
register_assert_handler
Supplies a custom handler function for dealing with assert failures. Your callback will be passed a formatted error message in ASCII, and should return non-zero...
register_bitmap_file_type
Informs the load_bitmap() and save_bitmap() functions of a new file type, providing routines to read and write images in this format (either function may be...
register_datafile_object
Used to add custom object types, specifying functions to load and destroy objects of this type.
register_font_file_type
Informs the load_font() functions of a new file type, providing a routine to read fonts in this format.
register_sample_file_type
Informs the load_sample() function of a new sample file type, providing routines to read and write samples in this format (either function may be NULL).
register_trace_handler
Supplies a custom handler function for dealing with trace output. Your callback will be passed a formatted error message in ASCII, and should return non-zero if...
register_uformat
Installs a set of custom handler functions for a new text encoding format. The `type' is the ID code for your new format, which should be a 4-character string...
release_bitmap
Releases a bitmap that was previously locked by calling acquire_bitmap(). If the bitmap was locked multiple times, you must release it the same number of times...
release_screen
Shortcut version of release_bitmap(screen);
release_voice
Releases a sound card voice, indicating that you are no longer interested in manipulating it. The sound will continue to play, and any resources that it is...
reload_config_texts
Reloads the translated strings returned by get_config_text(). This is useful to switch to another language in your program at runtime. If you want to modify the...
remove_display_switch_callback
Removes a notification callback that was previously installed by calling set_display_switch_callback(). All the callbacks will automatically be removed when you...
remove_int
Removes a function from the list of user interrupt routines. At program termination, allegro_exit() does this automatically.
remove_joystick
Removes the joystick handler. You don't normally need to bother calling this, because allegro_exit() will do it for you.
remove_keyboard
Removes the keyboard handler, returning control to the operating system. You don't normally need to bother calling this, because allegro_exit() will do it for...
remove_mouse
Removes the mouse handler. You don't normally need to bother calling this, because allegro_exit() will do it for you.
remove_param_int
Like remove_int(), but for use with timer callbacks that have parameter values. If there is more than one copy of the same callback active at a time, it...
remove_sound
Cleans up after you are finished with the sound routines. You don't normally need to call this, because allegro_exit() will do it for you.
remove_sound_input
Cleans up after you are finished with the sound input routines. You don't normally need to call this, because remove_sound() and/or allegro_exit() will do it...
remove_timer
Removes the Allegro timer handler (and, under DOS, passes control of the clock back to the operating system). You don't normally need to bother calling this...
render_scene
Renders all the specified scene_polygon3d()'s on the bitmap passed to clear_scene(). Rendering is done one scanline at a time, with no pixel being processed...
replace_extension
Replaces the specified filename+extension with a new extension tail, storing at most `size' bytes into the `dest' buffer. If the filename doesn't have any...
replace_filename
Replaces the specified path+filename with a new filename tail, storing at most `size' bytes into the `dest' buffer. You can use the same buffer both as input...
request_refresh_rate
Requests that the next call to set_gfx_mode() try to use the specified refresh rate, if possible. Not all drivers are able to control this at all, and even when...
request_scroll
This function is used for triple buffering. It requests a hardware scroll to the specified position, but returns immediately rather than waiting for a retrace...
request_video_bitmap
This function is used for triple buffering. It requests a page flip to display the specified video bitmap object, but returns immediately rather than waiting...
reserve_voices
Call this function to specify the number of voices that are to be used by the digital and MIDI sound drivers respectively. This must be done _before_ calling...
reset_fli_variables
Once you have done whatever you are going to do with the fli_bitmap and fli_palette, call this function to reset the fli_bmp_dirty_* and fli_pal_dirty_*...
rest
This function waits for the specified number of milliseconds. Passing 0 as parameter will not wait, but just yield. This can be useful in order to "play nice"...
rest_callback
Like rest(), but for non-zero values continually calls the specified function while it is waiting for the required time to elapse. If the provided `callback'...
retrace_count
If the retrace simulator is installed, this count is incremented on each vertical retrace; otherwise, if the refresh rate is known, the count is incremented at...
RGB
Single palette entry. Allegro game programming library.
rgb_map
To speed up reducing RGB values to 8-bit paletted colors, Allegro uses a 32k lookup table (5 bits for each color component). You must set up this table before...
RGB_MAP
Stores an rgb map to accelerate conversions. Allegro game programming library.
RLE_SPRITE
Stores the contents of an RLE sprite. Allegro game programming library.
rotate_scaled_sprite
Like rotate_sprite(), but stretches or shrinks the image at the same time as rotating it.
rotate_scaled_sprite_lit
Like rotate_sprite_lit(), but stretches or shrinks the image at the same time as rotating it.
rotate_scaled_sprite_trans
Like rotate_sprite_trans(), but stretches or shrinks the image at the same time as rotating it.
rotate_scaled_sprite_v_flip
Draws the sprite, similar to rotate_scaled_sprite() except that it flips the sprite vertically first.
rotate_scaled_sprite_v_flip_lit
Draws the sprite, similar to rotate_scaled_sprite_lit() except that it flips the sprite vertically first.
rotate_scaled_sprite_v_flip_trans
Draws the sprite, similar to rotate_scaled_sprite_trans() except that it flips the sprite vertically first.
rotate_sprite
Draws the sprite image onto the bitmap. It is placed with its top left corner at the specified position, then rotated by the specified angle around its centre...
rotate_sprite_lit
Draws the sprite image onto the bitmap. It is placed with its top left corner at the specified position, then rotated by the specified angle around its centre...
rotate_sprite_trans
Draws the sprite image onto the bitmap. It is placed with its top left corner at the specified position, then rotated by the specified angle around its centre...
rotate_sprite_v_flip
Like rotate_sprite, but flips the image vertically before rotating it. To flip horizontally, use this routine but add itofix(128) to the angle. To flip in both...
rotate_sprite_v_flip_lit
Like rotate_sprite_lit, but flips the image vertically before rotating it. To flip horizontally, use this routine but add itofix(128) to the angle. To flip in...
rotate_sprite_v_flip_trans
Like rotate_sprite_trans, but flips the image vertically before rotating it. To flip horizontally, use this routine but add itofix(128) to the angle. To flip in...
SAMPLE
Stores sound data. Allegro game programming library.
save_bitmap
Writes a bitmap into a file, using the specified palette, which should be an array of 256 RGB structures. The output format is determined from the filename...
save_bmp
Writes a bitmap into a 256-color or 24-bit truecolor BMP file.
save_bmp_pf
A version of save_bmp which writes to a packfile.
save_joystick_data
After all the headache of calibrating the joystick, you may not want to make your poor users repeat the process every time they run your program. Call this...
save_pcx
Writes a bitmap into a 256-color or 24-bit truecolor PCX file.
save_pcx_pf
A version of save_pcx which writes to a packfile.
save_sample
Writes a sample into a file. The output format is determined from the filename extension. At present Allegro does not natively support the writing of any sample...
save_tga
Writes a bitmap into a 256-color, 15-bit hicolor, 24-bit truecolor, or 32-bit truecolor+alpha TGA file.
save_tga_pf
A version of save_tga which writes to a packfile.
scancode_to_ascii
Converts the given scancode to an ASCII character for that key (mangling Unicode values), returning the unshifted uncapslocked result of pressing the key, or...
scancode_to_name
This function returns a string pointer containing the name of they key with the given scancode. This is useful if you e.g. let the user choose a key for some...
scare_mouse
Helper for hiding the mouse pointer prior to a drawing operation. This will temporarily get rid of the pointer, but only if that is really required (ie. the...
scare_mouse_area
Like scare_mouse(), but will only hide the cursor if it is inside the specified rectangle. Otherwise the cursor will simply be frozen in place until you call...
scene_gap
This number (default value = 100.0) controls the behaviour of the z-sorting algorithm. When an edge is very close to another's polygon plane, there is an...
scene_polygon3d
Puts a polygon in the rendering list. Nothing is really rendered at this moment. Should be called between clear_scene() and render_scene(). Arguments are the...
screen
Global pointer to a bitmap, sized VIRTUAL_W x VIRTUAL_H. This is created by set_gfx_mode(), and represents the hardware video memory. Only a part of this bitmap...
SCREEN_W
Global defines that return the width and height of the screen, or zero if the screen has not been initialised yet.
scroll_screen
Attempts to scroll the hardware screen to display a different part of the virtual screen (initially it will be positioned at 0, 0, which is the top left...
select_mouse_cursor
This function allows you to use the operating system's native mouse cursors rather than some custom cursor. You will need to enable this functionality by...
select_palette
Ugly hack for use in various dodgy situations where you need to convert between paletted and truecolor image formats. Sets the internal palette table in the...
set_add_blender
Enables an additive blender mode for combining translucent or lit truecolor pixels.
set_allegro_resource_path
Sometimes Allegro doesn't look in enough places to find a resource. For those special cases, you can call this function before loading your resource with...
set_alpha_blender
Enables the special alpha-channel blending mode, which is used for drawing 32-bit RGBA sprites. After calling this function, you can use draw_trans_sprite() or...
set_blender_mode
Specifies a custom set of truecolor blender routines, which can be used to implement whatever special interpolation modes you need. This function shares a...
set_blender_mode_ex
Like set_blender_mode(), but allows you to specify a more complete set of blender routines. The b15, b16, b24, and b32 routines are used when drawing pixels...
set_burn_blender
Enables a burn blender mode for combining translucent or lit truecolor pixels. Here the lightness values of the colours of the source image reduce the lightness...
set_clip_rect
Each bitmap has an associated clipping rectangle, which is the area of the image that it is OK to draw onto. Nothing will be drawn to positions outside this...
set_clip_state
Turns on (if state is non-zero) or off (if state is zero) clipping for the specified bitmap. Turning clipping off may slightly speed up some drawing operations...
set_close_button_callback
On platforms that have a close button, this routine installs a callback function to handle the close event. In other words, when the user clicks the close...
_set_color
This is an inline version of set_color(), intended for use in the vertical retrace simulator callback function (retrace_proc, which is now deprecated). If you...
set_color
Sets the specified palette entry to the specified RGB triplet. Unlike the other palette functions this doesn't do any retrace synchronisation, so you should...
set_color_blender
Enables a color blender mode for combining translucent or lit truecolor pixels. Applies only the hue and saturation of the source image to the destination...
set_color_conversion
Specifies how to convert images between the various color depths when reading graphics from external bitmap files or datafiles. The mode is a bitmask specifying...
set_color_depth
Sets the pixel format to be used by subsequent calls to set_gfx_mode() and create_bitmap(). Valid depths are 8 (the default), 15, 16, 24, and 32 bits.
set_config_data
Specifies a block of data to be used by all subsequent config functions, which you have already loaded from disk (eg. as part of some more complicated format of...
set_config_file
Sets the configuration file to be used by all subsequent config functions. (Allegro will not search for this file in other locations as it does with allegro.cfg...
set_config_float
Writes a floating point variable to the current config file. See the comments about set_config_string().
set_config_hex
Writes an integer variable to the current config file, in hexadecimal format. See the comments about set_config_string().
set_config_id
Writes a 4-letter driver ID variable to the current config file. See the comments about set_config_string().
set_config_int
Writes an integer variable to the current config file. See the comments about set_config_string().
set_config_string
Writes a string variable to the current config file, replacing any existing value it may have, or removes the variable if `val' is NULL. The section name may be...
set_dialog_color
Sets the foreground and background colors of an array of dialog objects.
set_difference_blender
Enables a difference blender mode for combining translucent or lit truecolor pixels. This makes an image which has colours calculated by the difference between...
set_display_switch_callback
Installs a notification callback for the switching mode that was previously selected by calling set_display_switch_mode(). The direction parameter can either be...
set_display_switch_mode
Sets how the program should handle being switched into the background, if the user tabs away from it. Not all of the possible modes will be supported by every...
set_dissolve_blender
Enables a dissolve blender mode for combining translucent or lit truecolor pixels. Randomly replaces the colours of some pixels in the destination image with...
set_dodge_blender
Enables a dodge blender mode for combining translucent or lit truecolor pixels. The lightness of colours in the source lighten the colours of the destination...
set_filename_encoding
Sets the encoding to use for filenames. By default, UTF-8 is assumed.
set_gfx_mode
Switches into graphics mode. The card parameter should usually be one of the Allegro magic drivers (read introduction of chapter "Graphics modes") or see the...
set_hardware_volume
Alters the hardware sound output volume. Specify volumes for both digital samples and MIDI playback, as integers from 0 to 255, or pass a negative value to...
set_hue_blender
Enables a hue blender mode for combining translucent or lit truecolor pixels. This applies the hue of the source to the destination.
set_invert_blender
Enables an invert blender mode for combining translucent or lit truecolor pixels. Blends the inverse (or negative) colour of the source with the destination.
set_keyboard_rate
Sets the keyboard repeat rate. Times are given in milliseconds. Passing zero times will disable the key repeat.
set_leds
Overrides the state of the keyboard LED indicators. The parameter is a bitmask containing any of the values KB_SCROLOCK_FLAG, KB_NUMLOCK_FLAG, and...
set_luminance_blender
Enables a luminance blender mode for combining translucent or lit truecolor pixels. Applies the luminance of the source to the destination. The colour of the...
set_mixer_quality
Sets the resampling quality of the mixer. Valid values are the same as the `quality' config variable. Please read chapter "Standard config variables" for...
set_mouse_cursor_bitmap
This function changes the cursor image Allegro uses if select_mouse_cursor() is called but no native operating system cursor can be used, e.g. because you did...
set_mouse_range
Sets the area of the screen within which the mouse can move. Pass the top left corner and the bottom right corner (inclusive). If you don't call this function...
set_mouse_speed
Sets the mouse speed. Larger values of xspeed and yspeed represent slower mouse movement: the default for both is 2.
set_mouse_sprite
You don't like Allegro's mouse pointer? No problem. Use this function to supply an alternative of your own. If you change the pointer and then want to get...
set_mouse_sprite_focus
The mouse focus is the bit of the pointer that represents the actual mouse position, ie. the (mouse_x, mouse_y) position. By default this is the top left corner...
set_multiply_blender
Enables a multiply blender mode for combining translucent or lit truecolor pixels. Combines the source and destination images, multiplying the colours to...
set_palette
Sets the entire palette of 256 colors. You should provide an array of 256 RGB structures. Unlike set_color(), there is no need to call vsync() before this...
set_palette_range
Sets the palette entries between from and to (inclusive: pass 0 and 255 to set the entire palette). If vsync is set it waits for the vertical retrace, otherwise...
set_projection_viewport
Sets the viewport used to scale the output of the persp_project() function. Pass the dimensions of the screen area you want to draw onto, which will typically...
set_saturation_blender
Enables a saturation blender mode for combining translucent or lit truecolor pixels. Applies the saturation of the source to the destination image.
set_screen_blender
Enables a screen blender mode for combining translucent or lit truecolor pixels. This blender mode lightens the colour of the destination image by multiplying...
set_sound_input_source
Selects the audio input source.
set_trans_blender
Enables a linear interpolator blender mode for combining translucent or lit truecolor pixels.
set_ucodepage
When you select the U_ASCII_CP encoding mode, a set of tables are used to convert between 8-bit characters and their Unicode equivalents. You can use this...
set_uformat
Sets the current text encoding format. This will affect all parts of Allegro, wherever you see a function that returns a char *, or takes a char * as a...
set_volume
Alters the global sound output volume. Specify volumes for both digital samples and MIDI playback, as integers from 0 to 255, or pass a negative value to leave...
set_volume_per_voice
By default, Allegro will play a centered sample at half volume on both the left and right channel. A sample panned to the far right or left will be played at...
set_window_title
On platforms that are capable of it, this routine alters the window title for your Allegro program. Note that Allegro cannot set the window title when running...
set_write_alpha_blender
Enables the special alpha-channel editing mode, which is used for drawing alpha channels over the top of an existing 32-bit RGB sprite, to turn it into an RGBA...
set_zbuffer
Makes the given Z-buffer be the active one. This should have been previously created with create_zbuffer().
show_mouse
Tells Allegro to display a mouse pointer on the screen. This will only work if the timer module has been installed. The mouse pointer will be drawn onto the...
show_os_cursor
In case you do not need Allegro's mouse cursor API, which automatically emulates a cursor in software if no other cursor is available, you can use this low...
show_video_bitmap
Attempts to page flip the hardware screen to display the specified video bitmap object, which must be the same size as the physical screen, and should have been...
shutdown_dialog
Destroys a dialog player object returned by init_dialog(), returning the object that caused it to exit (this is the same as the return value from do_dialog()).
shutdown_menu
Destroys a menu player object returned by init_menu(), returning the index of the menu item that was selected, or -1 if the menu was cancelled (this is the same...
simulate_keypress
Stuffs a key into the keyboard buffer, just as if the user had pressed it. The parameter is in the same format returned by readkey().
simulate_ukeypress
Stuffs a key into the keyboard buffer, just as if the user had pressed it. The parameter is in the same format returned by ureadkey().
solid_mode
This is a shortcut for selecting solid drawing mode. It is equivalent to calling drawing_mode(DRAW_MODE_SOLID, NULL, 0, 0).
spline
Draws a Bezier spline using the four control points specified in the points array. Read the description of calc_spline() for information on how to build the...
start_sound_input
Starts recording in the specified format, suspending audio playback as necessary if the card is not full duplex.
stop_audio_stream
Destroys an audio stream when it is no longer required.
stop_midi
Stops whatever music is currently playing. This is the same thing as calling play_midi(NULL, FALSE).
stop_sample
Stop a sample from playing, which is required if you have set a sample going in looped mode. If there are several copies of the sample playing, it will stop...
stop_sound_input
Stops audio recording, switching the card back into the normal playback mode.
stretch_blit
Like blit(), except it can scale images (so the source and destination rectangles don't need to be the same size) and requires the source and destination...
stretch_sprite
Like draw_sprite(), except it can stretch the sprite image to the specified width and height and requires the sprite image and destination bitmap to be of the...
text_height
Returns the height (in pixels) of the specified font.
text_length
Returns the length (in pixels) of a string in the specified font.
textout_centre_ex
Like textout_ex(), but interprets the x coordinate as the centre rather than the left edge of the string.
textout_ex
Writes the string `s' onto the bitmap at position x, y, using the specified font, foreground color and background color. If the background color is -1, then the...
textout_justify_ex
Draws justified text within the region x1-x2. If the amount of spare space is greater than the diff value, it will give up and draw regular left justified text...
textout_right_ex
Like textout_ex(), but interprets the x coordinate as the right rather than the left edge of the string.
textprintf_centre_ex
Like textprintf_ex(), but interprets the x coordinate as the centre rather than the left edge of the string. This function shares the text length limitation of...
textprintf_ex
Formatted text output, using a printf() style format string. Due to an internal limitation, this function can't be used for extremely long texts. If you happen...
textprintf_justify_ex
Like textout_justify_ex(), but using a printf() style format string. This function shares the text length limitation of textprintf_ex().
textprintf_right_ex
Like textprintf_ex(), but interprets the x coordinate as the right rather than the left edge of the string. This function shares the text length limitation of...
three_finger_flag
The DJGPP keyboard handler provides an 'emergency exit' sequence which you can use to kill off your program. If you are running under DOS this is the three...
TRACE
Debugging helper macro. Normally compiles away to nothing, but if you defined the preprocessor symbol DEBUGMODE before including Allegro headers, it passes the...
transpose_font
This function transposes all characters in a font, effectively remapping the font.
triangle
Draws a filled triangle between the three points.
triangle3d
Draw 3d triangles, using either fixed or floating point vertex structures. Unlike quad3d[_f](), triangle3d[_f]() functions are not wrappers of polygon3d[_f]()...
uatof
Convert as much of the string as possible to an equivalent double precision real number. This function is almost like `ustrtod(s, NULL)'.
uconvert
Higher level function running on top of do_uconvert(). This function converts the specified string `s' from `type' to `newtype', storing at most `size' bytes...
uconvert_ascii
Helper macro for converting strings from ASCII into the current encoding format. Expands to uconvert(s, U_ASCII, buf, U_CURRENT, sizeof(buf)).
uconvert_size
Finds out how many bytes are required to store the specified string `s' after a conversion from `type' to `newtype', including the mandatory zero terminator of...
uconvert_toascii
Helper macro for converting strings from the current encoding format into ASCII. Expands to uconvert(s, U_CURRENT, buf, U_ASCII, sizeof(buf)).
ucwidth
Low level helper function for testing Unicode text data.
ugetat
Finds out the character value at the specified `index' in the string. A zero `index' parameter will return the first character of the string. If `index' is...
ugetc
Low level helper function for reading Unicode text data.
ugetx
Low level helper function for reading Unicode text data. ugetxc is provided for working with pointer-to-pointer-to-const char data.
uinsert
Inserts the character `c' at the specified `index' in the string, sliding the rest of the data along to make room. If `index' is negative, it counts backward...
uisdigit
Returns nonzero if `c' is a digit.
uisok
Low level helper function for testing Unicode text data. Finds out if the character value `c' can be encoded correctly in the current format, which can be...
uisspace
Returns nonzero if `c' is whitespace, that is, carriage return, newline, form feed, tab, vertical tab, or space.
unload_datafile
Frees all the objects in a datafile. Use this to avoid memory leaks in your program.
unload_datafile_object
Frees an object previously loaded by load_datafile_object(). Use this to avoid memory leaks in your program.
unscare_mouse
Undoes the effect of a previous call to scare_mouse() or scare_mouse_area(), restoring the original pointer state.
unselect_palette
Restores the palette tables that were in use before the last call to select_palette().
uoffset
Finds out the offset (in bytes from the start of the string) of the character at the specified `index' in the string `s'. A zero `index' parameter will return...
update_dialog
Updates the status of a dialog object returned by init_dialog(). Returns TRUE if the dialog is still active, or FALSE if it has terminated. Upon a return value...
update_menu
Updates the status of a menu object returned by init_menu(). Returns TRUE if the menu is still active, or FALSE if it has terminated. Upon a return value of...
ureadkey
Returns the next character from the keyboard buffer, in Unicode format. If the buffer is empty, it waits until a key is pressed. You can see if there are queued...
uremove
Removes the character at the specified `index' within the string, sliding the rest of the data back to fill the gap. If `index' is negative, it counts backward...
usetat
Replaces the character at the specified index in the string with value `c', handling any adjustments for variable width data (ie. if `c' encodes to a different...
usetc
Low level helper function for writing Unicode text data. Writes the character `c' to the address pointed to by `s'.
usprintf
This function writes formatted data into the output buffer. A NULL character is written to mark the end of the string. You should try to avoid this function...
ustrcat
This function concatenates `src' to the end of `dest`'. You should try to avoid this function because it is very easy to overflow the destination buffer, use...
ustrchr
Finds the first occurrence of the character `c' in the string `s'.
ustrcmp
This function compares `s1' and `s2'.
ustrcpy
This function copies `src' (including the terminating null character into `dest'. You should try to avoid this function because it is very easy to overflow the...
ustrdup
This functions copies the null-terminated string `src' into a newly allocated area of memory, effectively duplicating it.
_ustrdup
Does the same as ustrdup(), but allows the user to specify a custom memory allocator function.
ustrerror
This function returns a string that describes the error code `err', which normally comes from the variable `errno'.
ustricmp
This function compares `s1' and `s2', ignoring case.
ustrlen
This function returns the number of characters in `s'. Note that this doesn't have to equal the string's size in bytes.
ustrlwr
This function replaces all upper case letters in `s' with lower case letters.
ustrncat
This function is like ustrcat() except that no more than `n' characters from `src' are appended to the end of `dest'. If the terminating null character in `src'...
ustrncmp
This function compares up to `n' characters of `s1' and `s2'.
ustrncpy
This function is like ustrcpy() except that no more than `n' characters from `src' are copied into `dest'. If `src' is shorter than `n' characters, null...
ustrnicmp
This function compares up to `n' characters of `s1' and `s2', ignoring case.
ustrpbrk
This function finds the first character in `s' that matches any character in `set'.
ustrrchr
Finds the last occurrence of the character `c' in the string `s'.
ustrsize
Returns the size of the specified string in bytes, not including the trailing null character.
ustrsizez
Returns the size of the specified string in bytes, including the trailing null character.
ustrstr
This function finds the first occurrence of string `s2' in string `s1'.
ustrtod
This function converts as many characters of `s' that look like a floating point number into one, and sets `*endp' to point to the first unused character, if...
ustrtok
This function retrieves tokens from `s' which are delimited by characters from `set'. To initiate the search, pass the string to be searched as `s'. For the...
ustrtok_r
Reentrant version of ustrtok. The `last' parameter is used to keep track of where the parsing is up to and must be a pointer to a char * variable allocated by...
ustrtol
This function converts the initial part of `s' to a signed integer, setting `*endp' to point to the first unused character, if `endp' is not a NULL pointer. The...
ustrupr
This function replaces all lower case letters in `s' with upper case letters.
ustrzcat
This function concatenates `src' to the end of `dest', whose length in bytes is specified by `size' and which is guaranteed to be null-terminated even when...
ustrzcpy
This function copies `src' (including the terminating null character) into `dest', whose length in bytes is specified by `size' and which is guaranteed to be...
ustrzncat
This function is like ustrzcat() except that no more than `n' characters from `src' are appended to the end of `dest'. If the terminating null character in...
ustrzncpy
This function is like ustrzcpy() except that no more than `n' characters from `src' are copied into `dest' whose length in bytes is specified by `size' and...
uszprintf
This function writes formatted data into the output buffer, whose length in bytes is specified by `size' and which is guaranteed to be NULL terminated.
utolower
This function returns `c', converting it to lower case if it is upper case.
utoupper
This function returns `c', converting it to upper case if it is lower case.
uvsprintf
This is like usprintf(), but you pass the variable argument list directly, instead of the arguments themselves. You can use this function to implement printf...
uvszprintf
This is like uszprintf(), but you pass the variable argument list directly, instead of the arguments themselves.
uwidth
Low level helper function for testing Unicode text data.
uwidth_max
Low level helper function for working with Unicode text data. Returns the largest number of bytes that one character can occupy in the given encoding format...
V3D
Fixed point vertex structure used by 3d functions. Allegro game programming library.
V3D_f
Floating point vertex structure used by 3d functions. Allegro game programming library.
vector_length
Calculates the length of the vector (x, y, z), using that good 'ole Pythagoras theorem.
VIRTUAL_W
Global defines that return the width and height of the virtual screen, or zero if the screen has not been initialised yet.
vline
Draws a vertical line onto the bitmap, from point (x, y1) to (x, y2). Note: vline() is implemented as an alias to another function. See ALLEGRO_NO_VHLINE_ALIAS...
voice_check
Checks whether a voice is currently allocated.
voice_get_frequency
Returns the current pitch of the voice, in Hz.
voice_get_pan
Returns the current pan position, from 0 (left) to 255 (right).
voice_get_position
Returns the current position of a voice, in sample units, or -1 if it has finished playing.
voice_get_volume
Returns the current volume of the voice, range 0-255. Otherwise it returns -1 if that cannot be determined (because it has finished or been preempted by a...
voice_ramp_volume
Starts a volume ramp (crescendo or diminuendo) from the current volume to the specified ending volume, lasting for time milliseconds. The volume is a value in...
voice_set_echo
Sets the echo parameters for a voice (not currently implemented).
voice_set_frequency
Sets the pitch of the voice, in Hz.
voice_set_pan
Sets the pan position, ranging from 0 (left) to 255 (right).
voice_set_playmode
Adjusts the loop status of the specified voice. This can be done while the voice is playing, so you can start a sample in looped mode (having set the loop start...
voice_set_position
Sets the position of a voice, in sample units.
voice_set_priority
Sets the priority of a voice (range 0-255). This is used to decide which voices should be chopped off, if you attempt to play more than the sound card driver...
voice_set_tremolo
Sets the tremolo parameters for a voice (not currently implemented).
voice_set_vibrato
Sets the vibrato parameters for a voice (not currently implemented).
voice_set_volume
Sets the volume of the voice, range 0-255.
voice_start
Activates a voice, using whatever parameters have been set for it.
voice_stop
Stops a voice, storing the current position and state so that it may later be resumed by calling voice_start().
voice_stop_frequency_sweep
Interrupts a frequency sweep operation.
voice_stop_pan_sweep
Interrupts a pan sweep operation.
voice_stop_volumeramp
Interrupts a volume ramp operation.
voice_sweep_frequency
Starts a frequency sweep (glissando) from the current pitch to the specified ending pitch, lasting for time milliseconds.
voice_sweep_pan
Starts a pan sweep (left <-> right movement) from the current position to the specified ending position, lasting for time milliseconds.
vsync
Waits for a vertical retrace to begin. The retrace happens when the electron beam in your monitor has reached the bottom of the screen and is moving back to the...
xor_mode
This is a shortcut for toggling xor drawing mode on and off. Calling xor_mode(TRUE) is equivalent to drawing_mode(DRAW_MODE_XOR, NULL, 0, 0). Calling...
xwin_set_window_name
This function is only available under X. It lets you to specify the window name and group (or class). They are important because they allow the window manager...
ZBUFFER
Structure used by Allegro's 3d zbuffered rendering functions. You are not supposed to mix ZBUFFER with BITMAP even though it is currently possible to do so...