The open source OpenXR runtime
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

xrt: Misc tidy of u_var_timing

+22 -18
+1 -1
src/external/imgui_monado/cimgui_monado.h
··· 17 17 int values_count, int values_offset, 18 18 const char *overlay_text, float scale_min, float scale_max, 19 19 ImVec2 frame_size, float reference_timing, 20 - bool center_reference_timing, float range, char *unit, 20 + bool center_reference_timing, float range, const char *unit, 21 21 bool dynamic_rescale); 22 22 23 23 #ifdef __cplusplus
+4 -4
src/external/imgui_monado/imgui_monado.cpp
··· 20 20 using namespace ImGui; 21 21 22 22 static void _draw_line(ImGuiWindow *window, int values_count, float scale_min, 23 - float scale_max, float val, char *unit, 23 + float scale_max, float val, const char *unit, 24 24 const ImRect inner_bb, ImVec2 frame_size, ImU32 color) { 25 25 const float inv_scale = 26 26 (scale_min == scale_max) ? 0.0f : (1.0f / (scale_max - scale_min)); ··· 42 42 ImGui::PopStyleColor(1); 43 43 } 44 44 static void _draw_grid(ImGuiWindow *window, int values_count, float scale_min, 45 - float scale_max, float reference_timing, char *unit, 45 + float scale_max, float reference_timing, const char *unit, 46 46 const ImRect inner_bb, ImVec2 frame_size) { 47 47 48 48 ImVec4 target_color = ImVec4(1.0f, 1.0f, 0.0f, .75f); ··· 64 64 int values_count, int values_offset, 65 65 const char *overlay_text, ImVec2 frame_size, 66 66 float reference_timing, bool center_reference_timing, 67 - float range, char *unit, bool dynamic_rescale) { 67 + float range, const char *unit, bool dynamic_rescale) { 68 68 ImGuiWindow *window = GetCurrentWindow(); 69 69 if (window->SkipItems) 70 70 return; ··· 228 228 int values_count, int values_offset, 229 229 const char *overlay_text, float scale_min, float scale_max, 230 230 ImVec2 frame_size, float reference_timing, 231 - bool center_reference_timing, float range, char *unit, 231 + bool center_reference_timing, float range, const char *unit, 232 232 bool dynamic_rescale) { 233 233 PlotTimings(label, values_getter, data, values_count, values_offset, 234 234 overlay_text, frame_size, reference_timing,
+17 -13
src/xrt/auxiliary/util/u_var.h
··· 15 15 extern "C" { 16 16 #endif 17 17 18 + 19 + struct xrt_frame_sink; 20 + 21 + /*! 22 + * @ingroup aux_util 23 + * @{ 24 + */ 25 + 18 26 struct u_var_f32_arr 19 27 { 20 28 void *data; ··· 24 32 25 33 struct u_var_timing 26 34 { 35 + //! Values to be plotted. 27 36 struct u_var_f32_arr values; 37 + 38 + //! A reference line drawn on the plot. 28 39 float reference_timing; 29 40 30 - // if false, reference_timing will be the bottom of the graph 41 + //! If false, reference_timing will be the bottom of the graph. 31 42 bool center_reference_timing; 32 43 33 - // how many units the graph expands by default 44 + //! How many units the graph expands by default. 34 45 float range; 35 46 36 - // a string describing the unit used 37 - char *unit; 38 - 39 - // rescale graph's value range when value exceeds range 47 + //! Rescale graph's value range when value exceeds range. 40 48 bool dynamic_rescale; 49 + 50 + //! A string describing the unit used, not freed. 51 + const char *unit; 41 52 }; 42 - 43 - struct xrt_frame_sink; 44 - 45 - /*! 46 - * @ingroup aux_util 47 - * @{ 48 - */ 49 53 50 54 /*! 51 55 * What kind of variable is this tracking.