mac support
This commit is contained in:
parent
a4f0666ef0
commit
9b1f5894e8
@ -237,12 +237,10 @@ draw_trile :: () {
|
||||
size = size_of(type_of(trixels)),
|
||||
}));
|
||||
|
||||
sg_begin_pass(*(sg_pass.{ action = state.pass_action_clear, swapchain = cast,force(sg_swapchain) sglue_swapchain() }));
|
||||
sg_apply_pipeline(gPipelines.trixel.pipeline);
|
||||
sg_apply_bindings(*gPipelines.trixel.bind);
|
||||
sg_apply_uniforms(UB_vs_params, *(sg_range.{ ptr = *vs_params, size = size_of(type_of(vs_params)) }));
|
||||
sg_draw(0, 36, trixel_count);
|
||||
sg_end_pass();
|
||||
}
|
||||
|
||||
trile_editor_shortcuts :: () {
|
||||
|
||||
11
src/main.jai
11
src/main.jai
@ -35,6 +35,7 @@ Window_Info :: struct {
|
||||
};
|
||||
|
||||
get_window_info :: () -> Window_Info {
|
||||
|
||||
return Window_Info.{
|
||||
1920,
|
||||
1080,
|
||||
@ -103,17 +104,21 @@ frame :: () {
|
||||
for event: Input.events_this_frame {
|
||||
GR.getrect_handle_event(event);
|
||||
}
|
||||
|
||||
|
||||
sgl_defaults();
|
||||
sgl_matrix_mode_projection();
|
||||
sgl_ortho(0.0, sapp_widthf(), sapp_heightf(), 0.0, -1.0, +1.0);
|
||||
|
||||
draw_trile();
|
||||
|
||||
sg_begin_pass(*(sg_pass.{ action = state.pass_action_clear, swapchain = cast,force(sg_swapchain) sglue_swapchain() }));
|
||||
tick_ui();
|
||||
ui_pass();
|
||||
|
||||
draw_trile();
|
||||
sg_end_pass();
|
||||
sg_commit();
|
||||
|
||||
input_per_frame_event_and_flag_update();
|
||||
|
||||
reset_temporary_storage();
|
||||
}
|
||||
|
||||
|
||||
@ -325,8 +325,5 @@ render_ui :: () {
|
||||
|
||||
ui_pass :: () {
|
||||
render_ui(); // Generates commands that are handled in arb_tri_flush
|
||||
sg_begin_pass(*(sg_pass.{ action = state.pass_action, swapchain = cast,force(sg_swapchain) sglue_swapchain() }));
|
||||
arb_tri_flush();
|
||||
sg_end_pass();
|
||||
sg_commit();
|
||||
arb_tri_flush();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user