Lines Matching refs:pane

310                           xoffset + (gr->pane->max_num_vertices - gr->index - 1) * 2 - 1,  in hud_draw_graph_line_strip()
325 const struct hud_pane *pane) in hud_pane_accumulate_vertices() argument
331 const unsigned last_line = pane->last_line; in hud_pane_accumulate_vertices()
335 pane->x1, pane->y1, in hud_pane_accumulate_vertices()
336 pane->x2, pane->y2); in hud_pane_accumulate_vertices()
340 unsigned x = pane->x2 + 2; in hud_pane_accumulate_vertices()
341 unsigned y = pane->inner_y1 + in hud_pane_accumulate_vertices()
342 pane->inner_height * (last_line - i) / last_line - in hud_pane_accumulate_vertices()
345 number_to_human_readable(pane->max_value * i / last_line, in hud_pane_accumulate_vertices()
346 pane->type, str); in hud_pane_accumulate_vertices()
352 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_pane_accumulate_vertices()
353 unsigned x = pane->x1 + 2; in hud_pane_accumulate_vertices()
354 unsigned y = pane->y2 + 2 + i*hud->font.glyph_height; in hud_pane_accumulate_vertices()
356 number_to_human_readable(gr->current_value, pane->type, str); in hud_pane_accumulate_vertices()
363 line_verts[num++] = (float) pane->x1; in hud_pane_accumulate_vertices()
364 line_verts[num++] = (float) pane->y1; in hud_pane_accumulate_vertices()
365 line_verts[num++] = (float) pane->x2; in hud_pane_accumulate_vertices()
366 line_verts[num++] = (float) pane->y1; in hud_pane_accumulate_vertices()
368 line_verts[num++] = (float) pane->x2; in hud_pane_accumulate_vertices()
369 line_verts[num++] = (float) pane->y1; in hud_pane_accumulate_vertices()
370 line_verts[num++] = (float) pane->x2; in hud_pane_accumulate_vertices()
371 line_verts[num++] = (float) pane->y2; in hud_pane_accumulate_vertices()
373 line_verts[num++] = (float) pane->x1; in hud_pane_accumulate_vertices()
374 line_verts[num++] = (float) pane->y2; in hud_pane_accumulate_vertices()
375 line_verts[num++] = (float) pane->x2; in hud_pane_accumulate_vertices()
376 line_verts[num++] = (float) pane->y2; in hud_pane_accumulate_vertices()
378 line_verts[num++] = (float) pane->x1; in hud_pane_accumulate_vertices()
379 line_verts[num++] = (float) pane->y1; in hud_pane_accumulate_vertices()
380 line_verts[num++] = (float) pane->x1; in hud_pane_accumulate_vertices()
381 line_verts[num++] = (float) pane->y2; in hud_pane_accumulate_vertices()
385 float y = round((pane->max_value * i / (double)last_line) * in hud_pane_accumulate_vertices()
386 pane->yscale + pane->inner_y2); in hud_pane_accumulate_vertices()
389 line_verts[num++] = pane->x1; in hud_pane_accumulate_vertices()
391 line_verts[num++] = pane->x2; in hud_pane_accumulate_vertices()
400 const struct hud_pane *pane) in hud_pane_accumulate_vertices_simple() argument
408 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_pane_accumulate_vertices_simple()
409 unsigned x = pane->x1; in hud_pane_accumulate_vertices_simple()
410 unsigned y = pane->y_simple + i*hud->font.glyph_height; in hud_pane_accumulate_vertices_simple()
412 number_to_human_readable(gr->current_value, pane->type, str); in hud_pane_accumulate_vertices_simple()
420 const struct hud_pane *pane) in hud_pane_draw_colored_objects() argument
427 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_pane_draw_colored_objects()
428 unsigned x = pane->x1 + 2; in hud_pane_draw_colored_objects()
429 unsigned y = pane->y2 + 2 + i*hud->font.glyph_height; in hud_pane_draw_colored_objects()
437 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_pane_draw_colored_objects()
438 hud_draw_graph_line_strip(hud, gr, pane->inner_x1, pane->inner_y2, pane->yscale); in hud_pane_draw_colored_objects()
466 struct hud_pane *pane; in hud_draw_results() local
606 LIST_FOR_EACH_ENTRY(pane, &hud->pane_list, head) { in hud_draw_results()
607 if (pane) in hud_draw_results()
608 hud_pane_draw_colored_objects(hud, pane); in hud_draw_results()
620 struct hud_pane *pane; in hud_start_queries() local
626 LIST_FOR_EACH_ENTRY(pane, &hud->pane_list, head) { in hud_start_queries()
627 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_start_queries()
638 struct hud_pane *pane; in hud_stop_queries() local
674 LIST_FOR_EACH_ENTRY(pane, &hud->pane_list, head) { in hud_stop_queries()
675 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_stop_queries()
679 if (pane->sort_items) { in hud_stop_queries()
680 LIST_FOR_EACH_ENTRY_SAFE(gr, next, &pane->graph_list, head) { in hud_stop_queries()
682 if (&gr->head == pane->graph_list.prev) in hud_stop_queries()
697 hud_pane_accumulate_vertices_simple(hud, pane); in hud_stop_queries()
699 hud_pane_accumulate_vertices(hud, pane); in hud_stop_queries()
760 hud_pane_set_max_value(struct hud_pane *pane, uint64_t value) in hud_pane_set_max_value() argument
778 fixup_bytes(pane->type, i + 1, &exp10); in hud_pane_set_max_value()
787 fixup_bytes(pane->type, i + 1, &exp10); in hud_pane_set_max_value()
792 pane->last_line = 5; /* lines in +1/5 increments */ in hud_pane_set_max_value()
795 pane->last_line = 8; /* lines in +1/4 increments. */ in hud_pane_set_max_value()
799 pane->last_line = leftmost_digit * 2; /* lines in +1/2 increments */ in hud_pane_set_max_value()
805 pane->last_line = leftmost_digit; /* lines in +1 increments */ in hud_pane_set_max_value()
815 pane->last_line = leftmost_digit * 2; /* lines in +1/2 increments. */ in hud_pane_set_max_value()
824 pane->last_line = 5 + i; /* lines in +1/5 increments. */ in hud_pane_set_max_value()
830 pane->max_value = leftmost_digit * exp10; in hud_pane_set_max_value()
831 pane->yscale = -(int)pane->inner_height / (float)pane->max_value; in hud_pane_set_max_value()
835 hud_pane_update_dyn_ceiling(struct hud_graph *gr, struct hud_pane *pane) in hud_pane_update_dyn_ceiling() argument
840 if (pane->dyn_ceil_last_ran != gr->index) { in hud_pane_update_dyn_ceiling()
841 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_pane_update_dyn_ceiling()
849 tmp = tmp > pane->initial_max_value ? tmp : pane->initial_max_value; in hud_pane_update_dyn_ceiling()
850 hud_pane_set_max_value(pane, tmp); in hud_pane_update_dyn_ceiling()
857 pane->dyn_ceil_last_ran = gr->index; in hud_pane_update_dyn_ceiling()
867 struct hud_pane *pane = CALLOC_STRUCT(hud_pane); in hud_pane_create() local
869 if (!pane) in hud_pane_create()
872 pane->hud = hud; in hud_pane_create()
873 pane->x1 = x1; in hud_pane_create()
874 pane->y1 = y1; in hud_pane_create()
875 pane->x2 = x2; in hud_pane_create()
876 pane->y2 = y2; in hud_pane_create()
877 pane->y_simple = y_simple; in hud_pane_create()
878 pane->inner_x1 = x1 + 1; in hud_pane_create()
879 pane->inner_x2 = x2 - 1; in hud_pane_create()
880 pane->inner_y1 = y1 + 1; in hud_pane_create()
881 pane->inner_y2 = y2 - 1; in hud_pane_create()
882 pane->inner_width = pane->inner_x2 - pane->inner_x1; in hud_pane_create()
883 pane->inner_height = pane->inner_y2 - pane->inner_y1; in hud_pane_create()
884 pane->period = period; in hud_pane_create()
885 pane->max_num_vertices = (x2 - x1 + 2) / 2; in hud_pane_create()
886 pane->ceiling = ceiling; in hud_pane_create()
887 pane->dyn_ceiling = dyn_ceiling; in hud_pane_create()
888 pane->dyn_ceil_last_ran = 0; in hud_pane_create()
889 pane->sort_items = sort_items; in hud_pane_create()
890 pane->initial_max_value = max_value; in hud_pane_create()
891 hud_pane_set_max_value(pane, max_value); in hud_pane_create()
892 list_inithead(&pane->graph_list); in hud_pane_create()
893 return pane; in hud_pane_create()
912 hud_pane_add_graph(struct hud_pane *pane, struct hud_graph *gr) in hud_pane_add_graph() argument
931 unsigned color = pane->next_color % ARRAY_SIZE(colors); in hud_pane_add_graph()
935 gr->vertices = MALLOC(pane->max_num_vertices * sizeof(float) * 2); in hud_pane_add_graph()
939 gr->pane = pane; in hud_pane_add_graph()
940 list_addtail(&gr->head, &pane->graph_list); in hud_pane_add_graph()
941 pane->num_graphs++; in hud_pane_add_graph()
942 pane->next_color++; in hud_pane_add_graph()
949 value = value > gr->pane->ceiling ? gr->pane->ceiling : value; in hud_graph_add_value()
960 if (gr->index == gr->pane->max_num_vertices) { in hud_graph_add_value()
969 if (gr->num_vertices < gr->pane->max_num_vertices) { in hud_graph_add_value()
973 if (gr->pane->dyn_ceiling == true) { in hud_graph_add_value()
974 hud_pane_update_dyn_ceiling(gr, gr->pane); in hud_graph_add_value()
976 if (value > gr->pane->max_value) { in hud_graph_add_value()
977 hud_pane_set_max_value(gr->pane, value); in hud_graph_add_value()
1178 struct hud_pane *pane = NULL; in hud_parse_env_var() local
1223 if (!pane) { in hud_parse_env_var()
1224 pane = hud_pane_create(hud, x, y, x + width, y + height, y_simple, in hud_parse_env_var()
1226 if (!pane) in hud_parse_env_var()
1231 pane->next_color = 0; in hud_parse_env_var()
1241 hud_fps_graph_install(pane); in hud_parse_env_var()
1244 hud_frametime_graph_install(pane); in hud_parse_env_var()
1247 hud_cpu_graph_install(pane, ALL_CPUS); in hud_parse_env_var()
1250 hud_cpu_graph_install(pane, i); in hud_parse_env_var()
1253 hud_thread_busy_install(pane, name, false); in hud_parse_env_var()
1256 hud_thread_counter_install(pane, name, HUD_COUNTER_OFFLOADED); in hud_parse_env_var()
1259 hud_thread_counter_install(pane, name, HUD_COUNTER_DIRECT); in hud_parse_env_var()
1262 hud_thread_counter_install(pane, name, HUD_COUNTER_SYNCS); in hud_parse_env_var()
1265 hud_thread_busy_install(pane, name, true); in hud_parse_env_var()
1269 hud_nic_graph_install(pane, arg_name, NIC_DIRECTION_RX); in hud_parse_env_var()
1272 hud_nic_graph_install(pane, arg_name, NIC_DIRECTION_TX); in hud_parse_env_var()
1275 hud_nic_graph_install(pane, arg_name, NIC_RSSI_DBM); in hud_parse_env_var()
1276 pane->type = PIPE_DRIVER_QUERY_TYPE_DBM; in hud_parse_env_var()
1279 hud_diskstat_graph_install(pane, arg_name, DISKSTAT_RD); in hud_parse_env_var()
1280 pane->type = PIPE_DRIVER_QUERY_TYPE_BYTES; in hud_parse_env_var()
1283 hud_diskstat_graph_install(pane, arg_name, DISKSTAT_WR); in hud_parse_env_var()
1284 pane->type = PIPE_DRIVER_QUERY_TYPE_BYTES; in hud_parse_env_var()
1287 hud_cpufreq_graph_install(pane, i, CPUFREQ_MINIMUM); in hud_parse_env_var()
1288 pane->type = PIPE_DRIVER_QUERY_TYPE_HZ; in hud_parse_env_var()
1291 hud_cpufreq_graph_install(pane, i, CPUFREQ_CURRENT); in hud_parse_env_var()
1292 pane->type = PIPE_DRIVER_QUERY_TYPE_HZ; in hud_parse_env_var()
1295 hud_cpufreq_graph_install(pane, i, CPUFREQ_MAXIMUM); in hud_parse_env_var()
1296 pane->type = PIPE_DRIVER_QUERY_TYPE_HZ; in hud_parse_env_var()
1301 hud_sensors_temp_graph_install(pane, arg_name, in hud_parse_env_var()
1303 pane->type = PIPE_DRIVER_QUERY_TYPE_TEMPERATURE; in hud_parse_env_var()
1306 hud_sensors_temp_graph_install(pane, arg_name, in hud_parse_env_var()
1308 pane->type = PIPE_DRIVER_QUERY_TYPE_TEMPERATURE; in hud_parse_env_var()
1311 hud_sensors_temp_graph_install(pane, arg_name, in hud_parse_env_var()
1313 pane->type = PIPE_DRIVER_QUERY_TYPE_VOLTS; in hud_parse_env_var()
1316 hud_sensors_temp_graph_install(pane, arg_name, in hud_parse_env_var()
1318 pane->type = PIPE_DRIVER_QUERY_TYPE_AMPS; in hud_parse_env_var()
1321 hud_sensors_temp_graph_install(pane, arg_name, in hud_parse_env_var()
1323 pane->type = PIPE_DRIVER_QUERY_TYPE_WATTS; in hud_parse_env_var()
1328 hud_pipe_query_install(&hud->batch_query, pane, in hud_parse_env_var()
1337 hud_pipe_query_install(&hud->batch_query, pane, in hud_parse_env_var()
1367 hud_pipe_query_install(&hud->batch_query, pane, name, in hud_parse_env_var()
1378 if (!hud_driver_query_install(&hud->batch_query, pane, in hud_parse_env_var()
1390 if (!pane) { in hud_parse_env_var()
1401 hud_pane_set_max_value(pane, i); in hud_parse_env_var()
1402 pane->initial_max_value = i; in hud_parse_env_var()
1414 if (!pane) { in hud_parse_env_var()
1425 if (added && !list_is_empty(&pane->graph_list)) { in hud_parse_env_var()
1427 graph = LIST_ENTRY(struct hud_graph, pane->graph_list.prev, head); in hud_parse_env_var()
1444 if (!pane) in hud_parse_env_var()
1447 y += height + hud->font.glyph_height * (pane->num_graphs + 2); in hud_parse_env_var()
1448 y_simple += hud->font.glyph_height * (pane->num_graphs + 1); in hud_parse_env_var()
1451 if (pane && pane->num_graphs) { in hud_parse_env_var()
1452 list_addtail(&pane->head, &hud->pane_list); in hud_parse_env_var()
1453 pane = NULL; in hud_parse_env_var()
1464 if (pane && pane->num_graphs) { in hud_parse_env_var()
1465 list_addtail(&pane->head, &hud->pane_list); in hud_parse_env_var()
1466 pane = NULL; in hud_parse_env_var()
1486 if (pane) { in hud_parse_env_var()
1487 if (pane->num_graphs) { in hud_parse_env_var()
1488 list_addtail(&pane->head, &hud->pane_list); in hud_parse_env_var()
1491 FREE(pane); in hud_parse_env_var()
1495 LIST_FOR_EACH_ENTRY(pane, &hud->pane_list, head) { in hud_parse_env_var()
1498 LIST_FOR_EACH_ENTRY(gr, &pane->graph_list, head) { in hud_parse_env_var()
1738 struct hud_pane *pane, *pane_tmp; in hud_unset_record_context() local
1744 LIST_FOR_EACH_ENTRY_SAFE(pane, pane_tmp, &hud->pane_list, head) { in hud_unset_record_context()
1745 LIST_FOR_EACH_ENTRY_SAFE(graph, graph_tmp, &pane->graph_list, head) { in hud_unset_record_context()
1749 list_del(&pane->head); in hud_unset_record_context()
1750 FREE(pane); in hud_unset_record_context()