|
Porytiles
|
Position state for a color whose slot is determined by another color in another palette. More...
#include <color_position.hpp>
Public Attributes | |
| std::size_t | ref_pal_index |
| Rgba32 | ref_color |
| std::size_t | source_group_index |
Position state for a color whose slot is determined by another color in another palette.
IndirectPosition says "my slot is wherever @c ref_color ends up in palette @c ref_pal_index." This is the key insight from borytiles by ishax-kos (https://github.com/ishax-kos/borytiles): by referencing colors rather than absolute slots, links remain valid even when sequential fill places non-shared colors at different positions than the base palettes. Corresponds to the Indirect(Palette_index,Color_index) variant of borytiles' Position_in_palette enum.
Indirect chains are resolved after sequential fill by following ref_pal_index / ref_color until hitting an AbsolutePosition. Cycle detection caps resolution at pal::num_pals iterations.
Definition at line 49 of file color_position.hpp.
| Rgba32 porytiles::IndirectPosition::ref_color |
Definition at line 51 of file color_position.hpp.
| std::size_t porytiles::IndirectPosition::ref_pal_index |
Definition at line 50 of file color_position.hpp.
| std::size_t porytiles::IndirectPosition::source_group_index |
Definition at line 52 of file color_position.hpp.