RetroArch
Classes | Macros | Typedefs | Enumerations | Functions | Variables
zarch.c File Reference
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <stdio.h>
#include <string.h>
#include <limits.h>
#include <file/file_path.h>
#include <lists/dir_list.h>
#include <compat/posix_string.h>
#include <gfx/math/matrix_4x4.h>
#include <string/stdstring.h>
#include <formats/image.h>
#include <compat/strl.h>
#include "menu_generic.h"
#include "../../config.def.h"
#include "../../list_special.h"
#include "../../file_path_special.h"
#include "../menu_driver.h"
#include "../menu_animation.h"
#include "../widgets/menu_entry.h"
#include "../../retroarch.h"
#include "../../gfx/font_driver.h"
#include "../../core_info.h"
#include "../../configuration.h"
#include "../../verbosity.h"
#include "../../tasks/tasks_internal.h"
Include dependency graph for zarch.c:

Classes

struct  zarch_handle
 
struct  zui_tabbed
 

Macros

#define ZUI_FG_NORMAL   (~0)
 
#define ZUI_ITEM_SIZE_PX   54
 

Typedefs

typedef struct zarch_handle zui_t
 

Enumerations

enum  zarch_zui_input_state {
  MENU_ZARCH_MOUSE_X = 0, MENU_ZARCH_MOUSE_Y, MENU_POINTER_ZARCH_X, MENU_POINTER_ZARCH_Y,
  MENU_ZARCH_PRESSED
}
 
enum  zarch_layout_type { LAY_HOME = 0, LAY_PICK_CORE, LAY_SETTINGS }
 

Functions

static float zarch_zui_strwidth (void *fb_buf, const char *text, float scale)
 
static int16_t zarch_zui_input_state (zui_t *zui, enum zarch_zui_input_state state)
 
static bool zarch_zui_check_button_down (zui_t *zui, unsigned id, int x1, int y1, int x2, int y2)
 
static bool zarch_zui_check_button_up (zui_t *zui, unsigned id, int x1, int y1, int x2, int y2)
 
static unsigned zarch_zui_hash (zui_t *zui, const char *s)
 
static void zarch_zui_draw_text (zui_t *zui, uint32_t color, int x, int y, const char *text)
 
static bool zarch_zui_button_full (zui_t *zui, int x1, int y1, int x2, int y2, const char *label)
 
static bool zarch_zui_button (zui_t *zui, int x1, int y1, const char *label)
 
static bool zarch_zui_list_item (video_frame_info_t *video_info, zui_t *zui, struct zui_tabbed *tab, int x1, int y1, const char *label, unsigned item_id, const char *entry, bool selected)
 
static void zarch_zui_tabbed_begin (zui_t *zui, struct zui_tabbed *tab, int x, int y)
 
static bool zarch_zui_tab (zui_t *zui, struct zui_tabbed *tab, const char *label, unsigned tab_id)
 
static void zarch_zui_render_lay_settings (zui_t *zui)
 
static bool zarch_zui_gamepad_input (zui_t *zui, int *gamepad_index, int *list_first, unsigned skip)
 
static int zarch_zui_render_lay_root_recent (video_frame_info_t *video_info, zui_t *zui, struct zui_tabbed *tabbed)
 
static void zarch_zui_render_lay_root_load_free (zui_t *zui)
 
static void zarch_zui_render_lay_root_load_set_new_path (zui_t *zui, const char *newpath)
 
static int zarch_zui_render_lay_root_load (video_frame_info_t *video_info, zui_t *zui, struct zui_tabbed *tabbed)
 
static int zarch_zui_render_lay_root_collections (zui_t *zui, struct zui_tabbed *tabbed)
 
static int zarch_zui_render_lay_root_downloads (zui_t *zui, struct zui_tabbed *tabbed)
 
static int zarch_zui_render_lay_root (video_frame_info_t *video_info, zui_t *zui)
 
static int zarch_zui_render_sidebar (zui_t *zui)
 
static int zarch_zui_load_content (zui_t *zui, unsigned i)
 
static void zarch_zui_draw_cursor (float x, float y)
 
static int zarch_zui_render_pick_core (video_frame_info_t *video_info, zui_t *zui)
 
static void zarch_frame (void *data, video_frame_info_t *video_info)
 
static voidzarch_init (void **userdata, bool video_is_threaded)
 
static void zarch_free (void *data)
 
static void zarch_context_bg_destroy (void *data)
 
static void zarch_context_destroy (void *data)
 
static bool zarch_load_image (void *userdata, void *data, enum menu_image_type type)
 
static void zarch_context_reset (void *data, bool is_threaded)
 
static int zarch_iterate (void *data, void *userdata, enum menu_action action)
 
static bool zarch_menu_init_list (void *data)
 

Variables

static const float zui_bg_panel []
 
static const float zui_bg_screen []
 
static const float zui_bg_hilite []
 
static const float zui_bg_pad_hilite []
 
static enum zarch_layout_type zarch_layout = LAY_HOME
 
menu_ctx_driver_t menu_ctx_zarch
 

Macro Definition Documentation

◆ ZUI_FG_NORMAL

#define ZUI_FG_NORMAL   (~0)

◆ ZUI_ITEM_SIZE_PX

#define ZUI_ITEM_SIZE_PX   54

Typedef Documentation

◆ zui_t

typedef struct zarch_handle zui_t

Enumeration Type Documentation

◆ zarch_layout_type

Enumerator
LAY_HOME 
LAY_PICK_CORE 
LAY_SETTINGS 

◆ zarch_zui_input_state

Enumerator
MENU_ZARCH_MOUSE_X 
MENU_ZARCH_MOUSE_Y 
MENU_POINTER_ZARCH_X 
MENU_POINTER_ZARCH_Y 
MENU_ZARCH_PRESSED 

Function Documentation

◆ zarch_context_bg_destroy()

static void zarch_context_bg_destroy ( void data)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_context_destroy()

static void zarch_context_destroy ( void data)
static
Here is the call graph for this function:

◆ zarch_context_reset()

static void zarch_context_reset ( void data,
bool  is_threaded 
)
static
Here is the call graph for this function:

◆ zarch_frame()

static void zarch_frame ( void data,
video_frame_info_t video_info 
)
static
Here is the call graph for this function:

◆ zarch_free()

static void zarch_free ( void data)
static
Here is the call graph for this function:

◆ zarch_init()

static void* zarch_init ( void **  userdata,
bool  video_is_threaded 
)
static
Here is the call graph for this function:

◆ zarch_iterate()

static int zarch_iterate ( void data,
void userdata,
enum menu_action  action 
)
static
Here is the call graph for this function:

◆ zarch_load_image()

static bool zarch_load_image ( void userdata,
void data,
enum menu_image_type  type 
)
static
Here is the call graph for this function:

◆ zarch_menu_init_list()

static bool zarch_menu_init_list ( void data)
static
Here is the call graph for this function:

◆ zarch_zui_button()

static bool zarch_zui_button ( zui_t zui,
int  x1,
int  y1,
const char *  label 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_button_full()

static bool zarch_zui_button_full ( zui_t zui,
int  x1,
int  y1,
int  x2,
int  y2,
const char *  label 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_check_button_down()

static bool zarch_zui_check_button_down ( zui_t zui,
unsigned  id,
int  x1,
int  y1,
int  x2,
int  y2 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_check_button_up()

static bool zarch_zui_check_button_up ( zui_t zui,
unsigned  id,
int  x1,
int  y1,
int  x2,
int  y2 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_draw_cursor()

static void zarch_zui_draw_cursor ( float  x,
float  y 
)
static
Here is the caller graph for this function:

◆ zarch_zui_draw_text()

static void zarch_zui_draw_text ( zui_t zui,
uint32_t  color,
int  x,
int  y,
const char *  text 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_gamepad_input()

static bool zarch_zui_gamepad_input ( zui_t zui,
int *  gamepad_index,
int *  list_first,
unsigned  skip 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_hash()

static unsigned zarch_zui_hash ( zui_t zui,
const char *  s 
)
static
Here is the caller graph for this function:

◆ zarch_zui_input_state()

static int16_t zarch_zui_input_state ( zui_t zui,
enum zarch_zui_input_state  state 
)
static

◆ zarch_zui_list_item()

static bool zarch_zui_list_item ( video_frame_info_t video_info,
zui_t zui,
struct zui_tabbed tab,
int  x1,
int  y1,
const char *  label,
unsigned  item_id,
const char *  entry,
bool  selected 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_load_content()

static int zarch_zui_load_content ( zui_t zui,
unsigned  i 
)
static
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root()

static int zarch_zui_render_lay_root ( video_frame_info_t video_info,
zui_t zui 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_collections()

static int zarch_zui_render_lay_root_collections ( zui_t zui,
struct zui_tabbed tabbed 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_downloads()

static int zarch_zui_render_lay_root_downloads ( zui_t zui,
struct zui_tabbed tabbed 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_load()

static int zarch_zui_render_lay_root_load ( video_frame_info_t video_info,
zui_t zui,
struct zui_tabbed tabbed 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_load_free()

static void zarch_zui_render_lay_root_load_free ( zui_t zui)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_load_set_new_path()

static void zarch_zui_render_lay_root_load_set_new_path ( zui_t zui,
const char *  newpath 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_root_recent()

static int zarch_zui_render_lay_root_recent ( video_frame_info_t video_info,
zui_t zui,
struct zui_tabbed tabbed 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_lay_settings()

static void zarch_zui_render_lay_settings ( zui_t zui)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_pick_core()

static int zarch_zui_render_pick_core ( video_frame_info_t video_info,
zui_t zui 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_render_sidebar()

static int zarch_zui_render_sidebar ( zui_t zui)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_strwidth()

static float zarch_zui_strwidth ( void fb_buf,
const char *  text,
float  scale 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_tab()

static bool zarch_zui_tab ( zui_t zui,
struct zui_tabbed tab,
const char *  label,
unsigned  tab_id 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ zarch_zui_tabbed_begin()

static void zarch_zui_tabbed_begin ( zui_t zui,
struct zui_tabbed tab,
int  x,
int  y 
)
static
Here is the caller graph for this function:

Variable Documentation

◆ menu_ctx_zarch

menu_ctx_driver_t menu_ctx_zarch

◆ zarch_layout

enum zarch_layout_type zarch_layout = LAY_HOME
static

◆ zui_bg_hilite

const float zui_bg_hilite[]
static
Initial value:
= {
0.22, 0.60, 0.74, 1,
0.22, 0.60, 0.74, 1,
0.22, 0.60, 0.74, 1,
0.22, 0.60, 0.74, 1,
}

◆ zui_bg_pad_hilite

const float zui_bg_pad_hilite[]
static
Initial value:
= {
0.30, 0.76, 0.93, 1,
0.30, 0.76, 0.93, 1,
0.30, 0.76, 0.93, 1,
0.30, 0.76, 0.93, 1,
}

◆ zui_bg_panel

const float zui_bg_panel[]
static
Initial value:
= {
0, 0, 0, 0.25,
0, 0, 0, 0.25,
0, 0, 0, 0.25,
0, 0, 0, 0.25,
}

◆ zui_bg_screen

const float zui_bg_screen[]
static
Initial value:
= {
0.07, 0.19, 0.26, 0.75,
0.07, 0.19, 0.26, 0.75,
0.15, 0.31, 0.47, 0.75,
0.15, 0.31, 0.47, 0.75,
}