mirror of
https://github.com/TomHarte/CLK.git
synced 2025-01-24 02:30:54 +00:00
Corrects colour mapping and improves documentation for self.
This commit is contained in:
parent
1f5908dc51
commit
5698aa6499
@ -21,7 +21,11 @@ constexpr int FinalPixelLine = 192;
|
||||
constexpr auto FinalColumn = CyclesPerLine / CyclesPerTick;
|
||||
|
||||
// Converts from Apple's RGB ordering to this emulator's.
|
||||
#define PaletteConvulve(x) ((x&0xf00) >> 8) | ((x&0x00f) << 8) | (x&0x0f0)
|
||||
#if TARGET_RT_BIG_ENDIAN
|
||||
#define PaletteConvulve(x) x
|
||||
#else
|
||||
#define PaletteConvulve(x) ((x&0xf00) >> 8) | ((x&0x0ff) << 8)
|
||||
#endif
|
||||
|
||||
// The 12-bit values used by the Apple IIgs to approximate Apple II colours,
|
||||
// as implied by tech note #63's use of them as border colours.
|
||||
|
@ -88,7 +88,8 @@ enum class InputDataType {
|
||||
|
||||
Red1Green1Blue1, // 1 byte/pixel; bit 0 is blue on or off, bit 1 is green, bit 2 is red.
|
||||
Red2Green2Blue2, // 1 byte/pixel; bits 0 and 1 are blue, bits 2 and 3 are green, bits 4 and 5 are blue.
|
||||
Red4Green4Blue4, // 2 bytes/pixel; first nibble is red, second is green, third is blue.
|
||||
Red4Green4Blue4, // 2 bytes/pixel; low nibble in first byte is red, high nibble in second is green, low is blue.
|
||||
// i.e. if it were a little endian word, 0xgb0r; or 0x0rgb big endian.
|
||||
Red8Green8Blue8, // 4 bytes/pixel; first is red, second is green, third is blue, fourth is vacant.
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user