[nostalgia/studio] Start on ImGui version of Studio

This commit is contained in:
2021-07-26 01:39:56 -05:00
parent 6160335af3
commit ddd63bc45f
46 changed files with 1005 additions and 2269 deletions
+3 -4
View File
@@ -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));