Showing changes from revision #3 to #4:
Added | Removed | Changed
Entry | |
---|---|
R0 | Sprite Reason Code |
R1 | Unused |
R2 | Pointer to sprite name |
… | Specific to each reason code |
Exit | |
---|---|
R1-R10 | Results of OS_SpriteOp call |
The purpose of this call is to perform a sprite related operation within the Wimp.
This call is actually mapped onto the more generic OS_SpriteOp call. However, &100 is automatically added to the value in R0, and R1 is set to the Wimp sprite area pointer.
Note that operations which attempt to modify sprites or the sprite area are generally not allowed and will produce an error. Consult the table atOS_SpriteOp for details on which operations are and aren’t supported.
Additionally, using reason code 24 to read the address of a sprite is discouraged. The address may change across Wimp_Poll calls due to other sprites being merged into the area, and using the pointer to directly modify the sprite is forbidden as it may be held in ROM or a supposedly read-only filesystem such as ResourceFS. From a performance standpoint there is also little reason to use a direct pointer to a Wimp sprite, as the Wimp internally caches pointers to its sprites.