static void rmenu_render(void) { size_t begin, end, i, j; struct font_params font_parms; char title[256], title_buf[256]; char title_msg[64]; const char *dir = NULL; const char *label = NULL; const char *core_name = NULL; const char *core_version = NULL; unsigned menu_type = 0; menu_handle_t *menu = menu_driver_get_ptr(); global_t *global = global_get_ptr(); runloop_t *runloop = rarch_main_get_ptr(); if (!menu) return; if (!render_normal) { render_normal = true; return; } if (menu->need_refresh && runloop->is_menu && !menu->msg_force) return; runloop->frames.video.current.menu.animation.is_active = false; runloop->frames.video.current.menu.label.is_updated = false; runloop->frames.video.current.menu.framebuf.dirty = false; if (!menu->menu_list->selection_buf) return; begin = (menu->navigation.selection_ptr >= (ENTRIES_HEIGHT / 2)) ? (menu->navigation.selection_ptr - (ENTRIES_HEIGHT / 2)) : 0; end = ((menu->navigation.selection_ptr + ENTRIES_HEIGHT) <= menu_list_get_size(menu->menu_list)) ? menu->navigation.selection_ptr + ENTRIES_HEIGHT : menu_list_get_size(menu->menu_list); if (menu_list_get_size(menu->menu_list) <= ENTRIES_HEIGHT) begin = 0; if (end - begin > ENTRIES_HEIGHT) end = begin + ENTRIES_HEIGHT; rmenu_render_background(); menu_list_get_last_stack(menu->menu_list, &dir, &label, &menu_type); get_title(label, dir, menu_type, title, sizeof(title)); menu_animation_ticker_line(title_buf, RMENU_TERM_WIDTH, runloop->frames.video.count / 15, title, true); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; video_driver_set_osd_msg(title_buf, &font_parms, NULL); core_name = global->menu.info.library_name; if (!core_name) core_name = global->system.info.library_name; if (!core_name) core_name = "No Core"; core_version = global->menu.info.library_version; if (!core_version) core_version = global->system.info.library_version; if (!core_version) core_version = ""; font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MAX - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; snprintf(title_msg, sizeof(title_msg), "%s - %s %s", PACKAGE_VERSION, core_name, core_version); video_driver_set_osd_msg(title_msg, &font_parms, NULL); j = 0; for (i = begin; i < end; i++, j++) { char message[PATH_MAX_LENGTH], type_str[PATH_MAX_LENGTH], entry_title_buf[PATH_MAX_LENGTH], type_str_buf[PATH_MAX_LENGTH], path_buf[PATH_MAX_LENGTH]; const char *path = NULL, *entry_label = NULL; unsigned type = 0, w = 0; bool selected = false; menu_file_list_cbs_t *cbs = NULL; menu_list_get_at_offset(menu->menu_list->selection_buf, i, &path, &entry_label, &type); cbs = (menu_file_list_cbs_t*) menu_list_get_actiondata_at_offset(menu->menu_list->selection_buf, i); if (cbs && cbs->action_get_representation) cbs->action_get_representation(menu->menu_list->selection_buf, &w, type, i, label, type_str, sizeof(type_str), entry_label, path, path_buf, sizeof(path_buf)); selected = (i == menu->navigation.selection_ptr); menu_animation_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (w + 1 + 2), runloop->frames.video.count / 15, path, selected); menu_animation_ticker_line(type_str_buf, w, runloop->frames.video.count / 15, type_str, selected); snprintf(message, sizeof(message), "%c %s", selected ? '>' : ' ', entry_title_buf); #if 0 blit_line(x, y, message, selected); #endif font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET + (POSITION_OFFSET * j); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; video_driver_set_osd_msg(message, &font_parms, NULL); font_parms.x = POSITION_EDGE_CENTER + POSITION_OFFSET; video_driver_set_osd_msg(type_str_buf, &font_parms, NULL); } }
static void rmenu_render(void) { size_t begin, end, i, j; struct font_params font_parms = {0}; char title[256] = {0}; char title_buf[256] = {0}; char title_msg[64] = {0}; menu_handle_t *menu = menu_driver_get_ptr(); menu_display_t *disp = menu_display_get_ptr(); menu_animation_t *anim = menu_animation_get_ptr(); menu_list_t *menu_list = menu_list_get_ptr(); menu_navigation_t *nav = menu_navigation_get_ptr(); global_t *global = global_get_ptr(); uint64_t frame_count = video_driver_get_frame_count(); size_t entries_end = menu_entries_get_end(); if (!menu) return; if (!render_normal) { render_normal = true; return; } if (menu_entries_needs_refresh() && menu_driver_alive() && !disp->msg_force) return; menu_display_fb_unset_dirty(); anim->is_active = false; anim->label.is_updated = false; if (!menu_list->selection_buf) return; begin = (nav->selection_ptr >= (ENTRIES_HEIGHT / 2)) ? (nav->selection_ptr - (ENTRIES_HEIGHT / 2)) : 0; end = ((nav->selection_ptr + ENTRIES_HEIGHT) <= entries_end) ? nav->selection_ptr + ENTRIES_HEIGHT : entries_end; if (entries_end <= ENTRIES_HEIGHT) begin = 0; if (end - begin > ENTRIES_HEIGHT) end = begin + ENTRIES_HEIGHT; rmenu_render_background(); menu_entries_get_title(title, sizeof(title)); menu_animation_ticker_line(title_buf, RMENU_TERM_WIDTH, frame_count / 15, title, true); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; video_driver_set_osd_msg(title_buf, &font_parms, NULL); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MAX - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; menu_entries_get_core_title(title_msg, sizeof(title_msg)); video_driver_set_osd_msg(title_msg, &font_parms, NULL); j = 0; for (i = begin; i < end; i++, j++) { char entry_path[PATH_MAX_LENGTH] = {0}; char entry_value[PATH_MAX_LENGTH] = {0}; char message[PATH_MAX_LENGTH] = {0}; char entry_title_buf[PATH_MAX_LENGTH] = {0}; char type_str_buf[PATH_MAX_LENGTH] = {0}; unsigned entry_spacing = menu_entry_get_spacing(i); bool entry_selected = menu_entry_is_currently_selected(i); menu_entry_get_value(i, entry_value, sizeof(entry_value)); menu_entry_get_path(i, entry_path, sizeof(entry_path)); menu_animation_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (entry_spacing + 1 + 2), frame_count / 15, entry_path, entry_selected); menu_animation_ticker_line(type_str_buf, entry_spacing, frame_count / 15, entry_value, entry_selected); snprintf(message, sizeof(message), "%c %s", entry_selected ? '>' : ' ', entry_title_buf); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET + (POSITION_OFFSET * j); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; video_driver_set_osd_msg(message, &font_parms, NULL); font_parms.x = POSITION_EDGE_CENTER + POSITION_OFFSET; video_driver_set_osd_msg(type_str_buf, &font_parms, NULL); } }
static void rmenu_render(void *data) { if (!render_normal) { render_normal = true; return; } rgui_handle_t *rgui = (rgui_handle_t*)data; font_params_t font_parms; if (rgui->need_refresh && (g_extern.lifecycle_state & (1ULL << MODE_MENU)) && !rgui->msg_force) return; size_t begin = rgui->selection_ptr >= (ENTRIES_HEIGHT / 2) ? (rgui->selection_ptr - (ENTRIES_HEIGHT / 2)) : 0; size_t end = (rgui->selection_ptr + ENTRIES_HEIGHT) <= rgui->selection_buf->size ? rgui->selection_ptr + ENTRIES_HEIGHT : rgui->selection_buf->size; if (rgui->selection_buf->size <= ENTRIES_HEIGHT) begin = 0; if (end - begin > ENTRIES_HEIGHT) end = begin + ENTRIES_HEIGHT; rmenu_render_background(rgui); char title[256]; const char *dir = NULL; unsigned menu_type = 0; unsigned menu_type_is = 0; file_list_get_last(rgui->menu_stack, &dir, &menu_type); if (driver.menu_ctx && driver.menu_ctx->backend && driver.menu_ctx->backend->type_is) menu_type_is = driver.menu_ctx->backend->type_is(menu_type); if (menu_type == RGUI_SETTINGS_CORE) snprintf(title, sizeof(title), "CORE SELECTION %s", dir); else if (menu_type == RGUI_SETTINGS_DEFERRED_CORE) snprintf(title, sizeof(title), "DETECTED CORES %s", dir); else if (menu_type == RGUI_SETTINGS_CONFIG) snprintf(title, sizeof(title), "CONFIG %s", dir); else if (menu_type == RGUI_SETTINGS_DISK_APPEND) snprintf(title, sizeof(title), "DISK APPEND %s", dir); else if (menu_type == RGUI_SETTINGS_VIDEO_OPTIONS) strlcpy(title, "VIDEO OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_DRIVERS) strlcpy(title, "DRIVER OPTIONS", sizeof(title)); #ifdef HAVE_SHADER_MANAGER else if (menu_type == RGUI_SETTINGS_SHADER_OPTIONS) strlcpy(title, "SHADER OPTIONS", sizeof(title)); #endif else if (menu_type == RGUI_SETTINGS_AUDIO_OPTIONS) strlcpy(title, "AUDIO OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_OVERLAY_OPTIONS) strlcpy(title, "OVERLAY OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_NETPLAY_OPTIONS) strlcpy(title, "NETPLAY OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_FONT_OPTIONS) strlcpy(title, "FONT OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_GENERAL_OPTIONS) strlcpy(title, "GENERAL OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_PATH_OPTIONS) strlcpy(title, "PATH OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_OPTIONS) strlcpy(title, "SETTINGS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_INPUT_OPTIONS) strlcpy(title, "INPUT OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_DISK_OPTIONS) strlcpy(title, "DISK OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_CORE_OPTIONS) strlcpy(title, "CORE OPTIONS", sizeof(title)); else if (menu_type == RGUI_SETTINGS_CORE_INFO) strlcpy(title, "CORE INFO", sizeof(title)); else if (menu_type == RGUI_SETTINGS_PRIVACY_OPTIONS) strlcpy(title, "PRIVACY OPTIONS", sizeof(title)); #ifdef HAVE_SHADER_MANAGER else if (menu_type_is == RGUI_SETTINGS_SHADER_OPTIONS) snprintf(title, sizeof(title), "SHADER %s", dir); #endif else if ((menu_type == RGUI_SETTINGS_INPUT_OPTIONS) || (menu_type == RGUI_SETTINGS_PATH_OPTIONS) || (menu_type == RGUI_SETTINGS_OPTIONS) || (menu_type == RGUI_SETTINGS_CUSTOM_VIEWPORT || menu_type == RGUI_SETTINGS_CUSTOM_VIEWPORT_2) || menu_type == RGUI_SETTINGS_CUSTOM_BIND || menu_type == RGUI_START_SCREEN || menu_type == RGUI_SETTINGS) snprintf(title, sizeof(title), "MENU %s", dir); else if (menu_type == RGUI_SETTINGS_OPEN_HISTORY) strlcpy(title, "LOAD HISTORY", sizeof(title)); #ifdef HAVE_OVERLAY else if (menu_type == RGUI_SETTINGS_OVERLAY_PRESET) snprintf(title, sizeof(title), "OVERLAY %s", dir); #endif else if (menu_type == RGUI_SETTINGS_VIDEO_SOFTFILTER) snprintf(title, sizeof(title), "FILTER %s", dir); else if (menu_type == RGUI_SETTINGS_AUDIO_DSP_FILTER) snprintf(title, sizeof(title), "DSP FILTER %s", dir); else if (menu_type == RGUI_BROWSER_DIR_PATH) snprintf(title, sizeof(title), "BROWSER DIR %s", dir); else if (menu_type == RGUI_CONTENT_DIR_PATH) snprintf(title, sizeof(title), "CONTENT DIR %s", dir); #ifdef HAVE_SCREENSHOTS else if (menu_type == RGUI_SCREENSHOT_DIR_PATH) snprintf(title, sizeof(title), "SCREENSHOT DIR %s", dir); #endif else if (menu_type == RGUI_AUTOCONFIG_DIR_PATH) snprintf(title, sizeof(title), "AUTOCONFIG DIR %s", dir); else if (menu_type == RGUI_SHADER_DIR_PATH) snprintf(title, sizeof(title), "SHADER DIR %s", dir); else if (menu_type == RGUI_FILTER_DIR_PATH) snprintf(title, sizeof(title), "FILTER DIR %s", dir); else if (menu_type == RGUI_DSP_FILTER_DIR_PATH) snprintf(title, sizeof(title), "DSP FILTER DIR %s", dir); else if (menu_type == RGUI_SAVESTATE_DIR_PATH) snprintf(title, sizeof(title), "SAVESTATE DIR %s", dir); #ifdef HAVE_DYNAMIC else if (menu_type == RGUI_LIBRETRO_DIR_PATH) snprintf(title, sizeof(title), "LIBRETRO DIR %s", dir); #endif else if (menu_type == RGUI_CONFIG_DIR_PATH) snprintf(title, sizeof(title), "CONFIG DIR %s", dir); else if (menu_type == RGUI_SAVEFILE_DIR_PATH) snprintf(title, sizeof(title), "SAVEFILE DIR %s", dir); #ifdef HAVE_OVERLAY else if (menu_type == RGUI_OVERLAY_DIR_PATH) snprintf(title, sizeof(title), "OVERLAY DIR %s", dir); #endif else if (menu_type == RGUI_SYSTEM_DIR_PATH) snprintf(title, sizeof(title), "SYSTEM DIR %s", dir); else if (menu_type == RGUI_ASSETS_DIR_PATH) snprintf(title, sizeof(title), "ASSETS DIR %s", dir); else { if (rgui->defer_core) snprintf(title, sizeof(title), "CONTENT %s", dir); else { const char *core_name = rgui->info.library_name; if (!core_name) core_name = g_extern.system.info.library_name; if (!core_name) core_name = "No Core"; snprintf(title, sizeof(title), "CONTENT (%s) %s", core_name, dir); } } char title_buf[256]; menu_ticker_line(title_buf, RMENU_TERM_WIDTH, g_extern.frame_count / 15, title, true); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, title_buf, &font_parms); char title_msg[64]; const char *core_name = rgui->info.library_name; if (!core_name) core_name = g_extern.system.info.library_name; if (!core_name) core_name = "No Core"; const char *core_version = rgui->info.library_version; if (!core_version) core_version = g_extern.system.info.library_version; if (!core_version) core_version = ""; font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MAX - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; snprintf(title_msg, sizeof(title_msg), "%s - %s %s", PACKAGE_VERSION, core_name, core_version); if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, title_msg, &font_parms); size_t i, j; j = 0; for (i = begin; i < end; i++, j++) { const char *path = 0; unsigned type = 0; file_list_get_at_offset(rgui->selection_buf, i, &path, &type); char message[256]; char type_str[256]; unsigned w = 19; if (menu_type == RGUI_SETTINGS_INPUT_OPTIONS || menu_type == RGUI_SETTINGS_CUSTOM_BIND) w = 21; else if (menu_type == RGUI_SETTINGS_PATH_OPTIONS) w = 24; #ifdef HAVE_SHADER_MANAGER if (type >= RGUI_SETTINGS_SHADER_FILTER && type <= RGUI_SETTINGS_SHADER_LAST) { // HACK. Work around that we're using the menu_type as dir type to propagate state correctly. if ((menu_type_is == RGUI_SETTINGS_SHADER_OPTIONS) && (menu_type_is == RGUI_SETTINGS_SHADER_OPTIONS)) { type = RGUI_FILE_DIRECTORY; strlcpy(type_str, "(DIR)", sizeof(type_str)); w = 5; } else if (type == RGUI_SETTINGS_SHADER_OPTIONS || type == RGUI_SETTINGS_SHADER_PRESET) strlcpy(type_str, "...", sizeof(type_str)); else if (type == RGUI_SETTINGS_SHADER_FILTER) snprintf(type_str, sizeof(type_str), "%s", g_settings.video.smooth ? "Linear" : "Nearest"); else if (driver.menu_ctx && driver.menu_ctx->backend && driver.menu_ctx->backend->shader_manager_get_str) driver.menu_ctx->backend->shader_manager_get_str(&rgui->shader, type_str, sizeof(type_str), type); } else #endif // Pretty-print libretro cores from menu. if (menu_type == RGUI_SETTINGS_CORE || menu_type == RGUI_SETTINGS_DEFERRED_CORE) { if (type == RGUI_FILE_PLAIN) { strlcpy(type_str, "(CORE)", sizeof(type_str)); file_list_get_alt_at_offset(rgui->selection_buf, i, &path); w = 6; } else { strlcpy(type_str, "(DIR)", sizeof(type_str)); type = RGUI_FILE_DIRECTORY; w = 5; } } else if (menu_type == RGUI_SETTINGS_CONFIG || #ifdef HAVE_OVERLAY menu_type == RGUI_SETTINGS_OVERLAY_PRESET || #endif menu_type == RGUI_SETTINGS_VIDEO_SOFTFILTER || menu_type == RGUI_SETTINGS_AUDIO_DSP_FILTER || menu_type == RGUI_SETTINGS_DISK_APPEND || menu_type_is == RGUI_FILE_DIRECTORY) { if (type == RGUI_FILE_PLAIN) { strlcpy(type_str, "(FILE)", sizeof(type_str)); w = 6; } else if (type == RGUI_FILE_USE_DIRECTORY) { *type_str = '\0'; w = 0; } else { strlcpy(type_str, "(DIR)", sizeof(type_str)); type = RGUI_FILE_DIRECTORY; w = 5; } } else if (menu_type == RGUI_SETTINGS_OPEN_HISTORY) { *type_str = '\0'; w = 0; } else if (type >= RGUI_SETTINGS_CORE_OPTION_START) strlcpy(type_str, core_option_get_val(g_extern.system.core_options, type - RGUI_SETTINGS_CORE_OPTION_START), sizeof(type_str)); else if (driver.menu_ctx && driver.menu_ctx->backend && driver.menu_ctx->backend->setting_set_label) driver.menu_ctx->backend->setting_set_label(type_str, sizeof(type_str), &w, type); char entry_title_buf[256]; char type_str_buf[64]; bool selected = i == rgui->selection_ptr; strlcpy(entry_title_buf, path, sizeof(entry_title_buf)); strlcpy(type_str_buf, type_str, sizeof(type_str_buf)); if ((type == RGUI_FILE_PLAIN || type == RGUI_FILE_DIRECTORY)) menu_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (w + 1 + 2), g_extern.frame_count / 15, path, selected); else menu_ticker_line(type_str_buf, w, g_extern.frame_count / 15, type_str, selected); snprintf(message, sizeof(message), "%c %s", selected ? '>' : ' ', entry_title_buf); //blit_line(rgui, x, y, message, selected); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET + (POSITION_OFFSET * j); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, message, &font_parms); font_parms.x = POSITION_EDGE_CENTER + POSITION_OFFSET; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, type_str_buf, &font_parms); } }
static void rmenu_render(void) { size_t begin, end; struct font_params font_parms; menu_handle_t *menu = (menu_handle_t*)driver.menu; if (!menu) return; if (!render_normal) { render_normal = true; return; } if (menu->need_refresh && g_extern.is_menu && !menu->msg_force) return; if (!driver.menu->menu_list->selection_buf) return; begin = (menu->selection_ptr >= (ENTRIES_HEIGHT / 2)) ? (menu->selection_ptr - (ENTRIES_HEIGHT / 2)) : 0; end = ((menu->selection_ptr + ENTRIES_HEIGHT) <= menu_list_get_size(driver.menu->menu_list)) ? menu->selection_ptr + ENTRIES_HEIGHT : menu_list_get_size(driver.menu->menu_list); if (menu_list_get_size(driver.menu->menu_list) <= ENTRIES_HEIGHT) begin = 0; if (end - begin > ENTRIES_HEIGHT) end = begin + ENTRIES_HEIGHT; rmenu_render_background(); char title[256]; const char *dir = NULL; const char *label = NULL; unsigned menu_type = 0; menu_list_get_last_stack(driver.menu->menu_list, &dir, &label, &menu_type); get_title(label, dir, menu_type, title, sizeof(title)); char title_buf[256]; menu_ticker_line(title_buf, RMENU_TERM_WIDTH, g_extern.frame_count / 15, title, true); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, title_buf, &font_parms); char title_msg[64]; const char *core_name = g_extern.menu.info.library_name; if (!core_name) core_name = g_extern.system.info.library_name; if (!core_name) core_name = "No Core"; const char *core_version = g_extern.menu.info.library_version; if (!core_version) core_version = g_extern.system.info.library_version; if (!core_version) core_version = ""; font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MAX - (POSITION_OFFSET*2); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; snprintf(title_msg, sizeof(title_msg), "%s - %s %s", PACKAGE_VERSION, core_name, core_version); if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, title_msg, &font_parms); size_t i, j; j = 0; for (i = begin; i < end; i++, j++) { char message[PATH_MAX], type_str[PATH_MAX], entry_title_buf[PATH_MAX], type_str_buf[PATH_MAX], path_buf[PATH_MAX]; const char *path = NULL, *entry_label = NULL; unsigned type = 0, w = 0; bool selected = false; menu_list_get_at_offset(menu->menu_list->selection_buf, i, &path, &entry_label, &type); disp_set_label(menu->menu_list->selection_buf, &w, type, i, label, type_str, sizeof(type_str), entry_label, path, path_buf, sizeof(path_buf)); selected = (i == driver.menu->selection_ptr); menu_ticker_line(entry_title_buf, RMENU_TERM_WIDTH - (w + 1 + 2), g_extern.frame_count / 15, path, selected); menu_ticker_line(type_str_buf, w, g_extern.frame_count / 15, type_str, selected); snprintf(message, sizeof(message), "%c %s", selected ? '>' : ' ', entry_title_buf); //blit_line(menu, x, y, message, selected); font_parms.x = POSITION_EDGE_MIN + POSITION_OFFSET; font_parms.y = POSITION_EDGE_MIN + POSITION_RENDER_OFFSET + (POSITION_OFFSET * j); font_parms.scale = FONT_SIZE_NORMAL; font_parms.color = WHITE; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, message, &font_parms); font_parms.x = POSITION_EDGE_CENTER + POSITION_OFFSET; if (driver.video_data && driver.video_poke && driver.video_poke->set_osd_msg) driver.video_poke->set_osd_msg(driver.video_data, type_str_buf, &font_parms); } }