GDInitGDLObj

Syntax

#include <revolution/gd.h>

void GDInitGDLObj(
    GDLObj* dl,
    void*   start,
    u32     length );

Arguments

dl Pointer to a graphics display list object.
start Pointer to a memory buffer that will contain the actual display list commands. Must have 32-byte alignment.
length Length of the memory buffer in bytes. Must be a multiple of 32.

Return Values

None.

Description

This function initializes a GDLObj--an object that manages display lists. Nearly all GD library functions operate in a manner based on GDLObj (usually "current" GDLObj). The argument dl specifies a pointer to the GDLObj to be initialized. First, a memory buffer must be allocated for use by GDLObj (in order to store the actual display list). This memory buffer must be 32-byte aligned. The arguments start and length are used to define this buffer. This function does not affect the buffer itself.

The top field of the GDLObj is initialized to (start + length). The ptr field of the GDLObj is initialized to (start).

See Also

GDGetGDLObjStart, GDGetGDLObjLength, GDSetCurrent

Revision History

2006/03/01 Initial version.


CONFIDENTIAL