Sprite Attribute 4 Register: Difference between revisions
From SpecNext Wiki
Core 2.00.22 changes, and forum knowledge from Jim Bagley distilled. |
core 2.00.23 changes |
||
| Line 11: | Line 11: | ||
| 7 || If 1, the pattern will be treated as 4-bit colour one (128 bytes), 0 is for 8-bit colour patterns (256 bytes) | | 7 || If 1, the pattern will be treated as 4-bit colour one (128 bytes), 0 is for 8-bit colour patterns (256 bytes) | ||
|- | |- | ||
| 6 || Chooses top/bottom part of pattern slot | | 6 || (if bit 7 = 1): Chooses top/bottom part of pattern slot when 4-bit colour pattern | ||
0 will target bytes 0..127 of pattern "Name" (byte 4), 1 will target bytes 128..255 of pattern "Name". | 0 will target bytes 0..127 of pattern "Name" (byte 4), 1 will target bytes 128..255 of pattern "Name". | ||
(if bit 7 = 0): make this sprite "relative" one: 1 = relative, 0 = normal (anchor) type | |||
|- | |- | ||
| 5 || | | 5 || (if bit 7-6 = %01) for "relative" sprite, this bit chooses top/bottom part of pattern slot for 4-bit colour mode (4 or 8 bit mode is set by anchor sprite, relative sprite can't switch the colour mode). See Bit 6 description above, if anchor sprite is in 4-bit mode. If anchor sprite is in 8-bit mode, use always 0 | ||
(else) For normal (anchor) sprites this is reserved, use always 0 | |||
|- | |- | ||
| 4-3 || x-axis scale factor: %00 = 1x (16 pixels), %01 = 2x, %10 = 4x, %11 = 8x (128 pixels) | | 4-3 || x-axis scale factor: %00 = 1x (16 pixels), %01 = 2x, %10 = 4x, %11 = 8x (128 pixels) | ||
| Line 23: | Line 26: | ||
|} | |} | ||
See {{PortNo|$xx57}} for extra notes about coordinates and clipping. | See {{PortNo|$xx57}} for extra notes about anchor/relative sprites, coordinates and clipping. | ||
Revision as of 20:33, 28 December 2018
| Number | TBRegisterNumber::$39 |
|---|---|
| Readable | TBRegisterReadable::No |
| Writable | TBRegisterWritable::Yes |
| Short Description | [[ShortDesc::Nextreg port-mirror to write directly into "byte 5" of {{#ask:
PortNumber::$xx57 }} ($xx57{{#ask: PortNumber::$xx57 |mainlabel=- |headers=hide |intro= / |?NumberDec#- }}).]] |
Byte 5 is bitmapped:
| Bit | Description |
|---|---|
| 7 | If 1, the pattern will be treated as 4-bit colour one (128 bytes), 0 is for 8-bit colour patterns (256 bytes) |
| 6 | (if bit 7 = 1): Chooses top/bottom part of pattern slot when 4-bit colour pattern
0 will target bytes 0..127 of pattern "Name" (byte 4), 1 will target bytes 128..255 of pattern "Name". (if bit 7 = 0): make this sprite "relative" one: 1 = relative, 0 = normal (anchor) type |
| 5 | (if bit 7-6 = %01) for "relative" sprite, this bit chooses top/bottom part of pattern slot for 4-bit colour mode (4 or 8 bit mode is set by anchor sprite, relative sprite can't switch the colour mode). See Bit 6 description above, if anchor sprite is in 4-bit mode. If anchor sprite is in 8-bit mode, use always 0
(else) For normal (anchor) sprites this is reserved, use always 0 |
| 4-3 | x-axis scale factor: %00 = 1x (16 pixels), %01 = 2x, %10 = 4x, %11 = 8x (128 pixels) |
| 2-1 | y-axis scale factor: %00 = 1x (16 pixels), %01 = 2x, %10 = 4x, %11 = 8x (128 pixels) |
| 0 | MSB of Y coordinate |
See {{#ask: PortNumber::$xx57 }} ($xx57{{#ask: PortNumber::$xx57 |mainlabel=- |headers=hide |intro= / |?NumberDec#- }}) for extra notes about anchor/relative sprites, coordinates and clipping.