chickadee » allegro » memory

Outdated egg!

This is an egg for CHICKEN 4, the unsupported old release. You're almost certainly looking for the CHICKEN 5 version of this egg, if it exists.

If it does not exist, there may be equivalent functionality provided by another egg; have a look at the egg index. Otherwise, please consider porting this egg to the current version of CHICKEN.

allegro

This document pertains to memory related methods found in the Allegro egg.

Please see the main [allegro] wiki page for more information.

Records

memory-interface

memory-interfacerecord
make-memory-interface*procedure
make-memory-interfaceprocedure
free-memory-interface! memory-interfaceprocedure
memory-interface-malloc memory-interfaceprocedure
(memory-interface-malloc-set! memory-interface (function c-pointer (integer32 integer (const c-string) (const c-string))))setter
memory-interface-realloc memory-interfaceprocedure
(memory-interface-realloc-set! memory-interface (function void (c-pointer integer (const c-string) (const c-string))))setter
memory-interface-calloc memory-interfaceprocedure
(memory-interface-calloc-set! memory-interface (function c-pointer (c-pointer integer32 integer (const c-string) (const c-string))))setter
memory-interface-free memory-interfaceprocedure
(memory-interface-free-set! memory-interface (function c-pointer (integer32 integer32 integer (const c-string) (const c-string))))setter

Functions

Memory

memory-interface-set! memory-interfaceprocedure

Implements al_set_memory_interface.

malloc* integerprocedure

Implements al_malloc.

malloc integerprocedure

Implements al_malloc, with (free!) declared as a finalizer.

free! ptrprocedure

Implements al_free.

realloc* ptr integerprocedure

Implements al_realloc.

realloc ptr integerprocedure

Implements al_realloc, with (free!) declared as a finalizer.

calloc* integer integerprocedure

Implements al_calloc.

calloc integer integerprocedure

Implements al_calloc, with (free!) declared as a finalizer.

(malloc/context* (int size) (int line) (string file) (string function))procedure

Implements al_malloc_with_context.

(malloc/context (int size) (int line) (string file) (string function))procedure

Implements al_malloc_with_context, with (free/context!) declared as a finalizer.

(free/context! ptr (int line) (string file) (string function))procedure

Implements al_free_with_context.

(realloc/context* ptr (int size) (int line) (string file) (string function))procedure

Implements al_realloc_with_context.

(realloc/context ptr (int size) (int line) (string file) (string function))procedure

Implements al_realloc_with_context, with (free/context!) declared as a finalizer.

(calloc/context* (int count) (int size) (int line) (string file) (string function))procedure

Implements al_calloc_with_context.

(calloc/context (int count) (int size) (int line) (string file) (string function))procedure

Implements al_calloc_with_context, with (free/context!) declared as a finalizer.

Memory Files

(open-memfile* (c-pointer mem) (unsigned-integer size) (string mode))procedure

Implements al_open_memfile.

(open-memfile (c-pointer mem) (unsigned-integer size) (string mode))procedure

Implements al_open_memfile, with (free&close-file!) declared as a finalizer.

memfile-versionprocedure

Implements al_get_allegro_memfile_version.

Miscellaneous

combine-flags converter flagsprocedure

For combining enum flags together, ie:

(combine-flags display-flag->int '(windowed opengl resizable generate-expose-events))
make-id a b c dprocedure

Implements AL_ID.

(run-main argc argv (function integer (integer (c-pointer c-string))))procedure

Implements al_run_main.

init-everythingprocedure

Initializes all sub-systems.

init-symbol sprocedure

Initializes sub-systems by symbol-name. Valid symbols are: allegro, audio, font, image, joystick, keyboard, mouse, primitives, and ttf.

init-this argprocedure

Initializes sub-systems either by a single symbol or by a list of symbols. Ie:

(init-this (list 'allegro 'audio 'font 'image 'joystick 'keyboard 'mouse 'primitives 'ttf))
uninstall-everythingprocedure

Attempts to uninitialize all loaded sub-systems.

uninstall-this argprocedure

Attempts to uninitialize sub-systems by either a single symbol or by a list of symbols. Ie:

(uninstall-this (list 'system 'audio 'font 'image 'joystick 'keyboard 'mouse 'primitives 'ttf))

Contents »