move to new renderstate, new render method

This commit is contained in:
Mitchell Hashimoto
2022-10-23 21:04:52 -07:00
parent b347ff458b
commit aeb592bae9
3 changed files with 21 additions and 93 deletions

View File

@@ -27,7 +27,7 @@ window: ?*Window = null,
/// Update the state associated with the dev mode. This should generally
/// only be called paired with a render since it otherwise wastes CPU
/// cycles.
pub fn update(self: *DevMode) !void {
pub fn update(self: *const DevMode) !void {
imgui.ImplOpenGL3.newFrame();
imgui.ImplGlfw.newFrame();
imgui.newFrame();
@@ -82,7 +82,7 @@ fn helpMarker(desc: [:0]const u8) void {
}
}
fn atlasInfo(self: *DevMode, atlas: *Atlas, tex: ?usize) !void {
fn atlasInfo(self: *const DevMode, atlas: *Atlas, tex: ?usize) !void {
_ = self;
imgui.text("Dimensions: %d x %d", atlas.size, atlas.size);