[nostalgia/studio] Start on ImGui version of Studio
This commit is contained in:
@@ -28,7 +28,6 @@ constexpr uint16_t DispStat_irq_vcount = 1 << 5;
|
||||
|
||||
struct GbaPaletteTarget {
|
||||
static constexpr auto TypeName = NostalgiaPalette::TypeName;
|
||||
static constexpr auto Fields = NostalgiaPalette::Fields;
|
||||
static constexpr auto TypeVersion = NostalgiaPalette::TypeVersion;
|
||||
volatile uint16_t *palette = nullptr;
|
||||
};
|
||||
@@ -44,7 +43,7 @@ struct GbaTileMapTarget {
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
ox::Error modelRead(T *io, GbaPaletteTarget *t) noexcept {
|
||||
constexpr ox::Error modelRead(T *io, GbaPaletteTarget *t) noexcept {
|
||||
io->template setTypeInfo<GbaPaletteTarget>();
|
||||
const auto colorHandler = [t](std::size_t i, Color16 *c) {
|
||||
t->palette[i] = *c;
|
||||
@@ -54,8 +53,8 @@ ox::Error modelRead(T *io, GbaPaletteTarget *t) noexcept {
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
ox::Error modelRead(T *io, GbaTileMapTarget *t) noexcept {
|
||||
io->template setTypeInfo<GbaTileMapTarget>();
|
||||
constexpr ox::Error modelRead(T *io, GbaTileMapTarget *t) noexcept {
|
||||
io->template setTypeInfo<GbaTileMapTarget>(GbaTileMapTarget::TypeName, GbaTileMapTarget::Fields);
|
||||
uint8_t bpp;
|
||||
int dummy;
|
||||
oxReturnError(io->field("bpp", &bpp));
|
||||
|
||||
Reference in New Issue
Block a user