int ok = WriteAnimFrame(APTR stream, struct SaveAnimCtrl *ctrl);
struct SaveAnimCtrl. This structure looks like this:
struct SaveAnimCtrl
{
APTR Data; // [in]
ULONG *Palette; // [in]
int Modulo; // [in]
int Colors; // [in]
ULONG TransIndex; // [in]
int Delay; // [in]
ULONG Flags; // [in]
ULONG FormatID; // [in] -- V5.3
};
|
Hollywood passes the following information to your WriteAnimFrame() function:
Data:Format member.
Modulo:
Colors:Palette
member. This member is only used if HWSAVEANMFMT_CLUT has been passed to BeginAnimStream().
Palette:Colors
member. Note that Palette is only used if HWSAVEANMFMT_CLUT has been passed to
BeginAnimStream().
TransIndex:HWSAVEANMFMT_CLUT this member specifies the index of
the color that should appear transparent in the animation. The value specified here is only
valid if the HWSAVEANMFLAGS_TRANSINDEX flag has been set (see below).
Delay:
Flags:
HWSAVEANMFLAGS_ALPHA:
HWSAVEANMFLAGS_TRANSINDEX:TransIndex member contains the index of a palette entry that should be
made transparent in the output animation.
FormatID:
This function has to return True if the frame has been successfully saved or False
in case of an error.
struct SaveAnimCtrl containing the frame to be savedTrue or False indicating success or failure