ColourMapping in Drawfiles

Introduction and Overview

This document is intentionally brief; refer to Sprite colour mapping for information pertaining to the changes in the sprite system for colour mapping.

Technical Details

DrawFile rendering flags

Bit(s)Meaning
3If set, a colour mapping function has been supplied. If clear, no colour mapping should be performed.

SWI Calls

DrawFile_RenderSWI &45540
Render a Draw file (changes for colour mapping)
R0=Flags (bit 3 indicates that a colour mapping descriptor is supplied in R6)
R1=Pointer to draw file to render
R2=Size of draw file
R3=Pointer to transform, or 0 for identity
R4=Pointer to clipping box, or 0 for none
R5=Flatness
R6=Pointer to colour mapping descriptor
R0 - R6preserved
Interrupts are undefined
Fast interrupts are undefined
Processor is in undefined mode
Not defined

The flags are updated, and R6 is used if the colour mapping flag is set.

Service Calls

Service_DrawObjectRenderService Call &45540
Draw object render (changes for colour mapping)
R0=Object type
R1=&45540 (service number)
R2=Pointer to render state:
OffsetContents
12Flags
32Pointer to colour mapping descriptor
None

Two values are added to the render state, and the flags are updated.