diff --git a/src/editor/iprof.jai b/src/editor/iprof.jai index 057eea6..d5ab804 100644 --- a/src/editor/iprof.jai +++ b/src/editor/iprof.jai @@ -37,6 +37,15 @@ draw_rectangle_prof :: (x0: float, y0: float, x1: float, y1: float, color: Vecto draw_rectangle(r, color); } +graph_begin :: (x: float, y: float, width: float, height: float) { + return; +} + +graph_end :: (x: float, y: float, width: float, height: float) { + return; +} + + iprof_cycle_active_report_mode :: () { iprof_active_report_mode := __Iprof.displayed_quantity; if iprof_active_report_mode == .SELF_TIME __Iprof.set_report_mode(.HIERARCHICAL_TIME); diff --git a/src/meshgen.jai b/src/meshgen.jai index 2e0ffb5..0cb20f5 100644 --- a/src/meshgen.jai +++ b/src/meshgen.jai @@ -344,27 +344,11 @@ a_is_inside_b :: (a: Quad, b: Quad) -> bool { remove_quad :: (quad: Quad, quadSet: *Quad_Set) { parent : Quad; - qlist : [..]Quad; - - for k,v : quadSet { - array_add(*qlist, v); - } - - Sort :: #import "Sort"; - - qcomp :: (a: Quad, b: Quad) -> s64 { - if a < b then return -1; - if b < a then return 1; - return 0; - } - - Sort.bubble_sort(qlist, qcomp); - - for qlist { - if it < quad then continue; - if a_is_inside_b(quad, it) { - parent = it; - table_remove(quadSet, it); + for v, k : quadSet { + if k < quad then continue; + if a_is_inside_b(quad, k) { + parent = k; + table_remove(quadSet, k); break; } }