mirror of
https://github.com/libretro/RetroArch
synced 2025-03-03 04:14:00 +00:00
reorder structs, alignment
This commit is contained in:
parent
eb1db52b89
commit
e399a2f78e
17
core_info.h
17
core_info.h
@ -25,6 +25,15 @@
|
||||
|
||||
RETRO_BEGIN_DECLS
|
||||
|
||||
enum core_info_list_qsort_type
|
||||
{
|
||||
CORE_INFO_LIST_SORT_PATH = 0,
|
||||
CORE_INFO_LIST_SORT_DISPLAY_NAME,
|
||||
CORE_INFO_LIST_SORT_CORE_NAME,
|
||||
CORE_INFO_LIST_SORT_SYSTEM_NAME
|
||||
};
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
char *path;
|
||||
@ -121,14 +130,6 @@ typedef struct core_info_ctx_find
|
||||
const char *path;
|
||||
} core_info_ctx_find_t;
|
||||
|
||||
enum core_info_list_qsort_type
|
||||
{
|
||||
CORE_INFO_LIST_SORT_PATH = 0,
|
||||
CORE_INFO_LIST_SORT_DISPLAY_NAME,
|
||||
CORE_INFO_LIST_SORT_CORE_NAME,
|
||||
CORE_INFO_LIST_SORT_SYSTEM_NAME
|
||||
};
|
||||
|
||||
struct core_info_state
|
||||
{
|
||||
#ifdef HAVE_COMPRESSION
|
||||
|
@ -52,9 +52,9 @@ typedef struct
|
||||
char *display_name;
|
||||
char *description;
|
||||
struct string_list *licenses_list;
|
||||
bool is_experimental;
|
||||
core_updater_list_date_t date; /* unsigned alignment */
|
||||
uint32_t crc;
|
||||
core_updater_list_date_t date;
|
||||
bool is_experimental;
|
||||
} core_updater_list_entry_t;
|
||||
|
||||
/* Prevent direct access to core_updater_list_t
|
||||
|
@ -70,8 +70,8 @@ typedef struct video_mut_coords
|
||||
float *color;
|
||||
float *tex_coord;
|
||||
float *lut_tex_coord;
|
||||
unsigned vertices;
|
||||
unsigned *index;
|
||||
unsigned vertices;
|
||||
unsigned indexes;
|
||||
} video_mut_coords_t;
|
||||
|
||||
|
@ -1371,7 +1371,7 @@ enum materialui_entry_value_type
|
||||
typedef struct
|
||||
{
|
||||
font_data_t *font;
|
||||
video_font_raster_block_t raster_block;
|
||||
video_font_raster_block_t raster_block; /* ptr alignment */
|
||||
unsigned glyph_width;
|
||||
int line_height;
|
||||
int line_ascender;
|
||||
|
37
playlist.c
37
playlist.c
@ -60,7 +60,7 @@ struct content_playlist
|
||||
|
||||
struct playlist_entry *entries;
|
||||
|
||||
playlist_config_t config;
|
||||
playlist_config_t config; /* size_t alignment */
|
||||
|
||||
enum playlist_label_display_mode label_display_mode;
|
||||
enum playlist_thumbnail_mode right_thumbnail_mode;
|
||||
@ -75,18 +75,6 @@ struct content_playlist
|
||||
|
||||
typedef struct
|
||||
{
|
||||
bool in_items;
|
||||
bool in_subsystem_roms;
|
||||
bool capacity_exceeded;
|
||||
bool out_of_memory;
|
||||
|
||||
unsigned array_depth;
|
||||
unsigned object_depth;
|
||||
|
||||
JSON_Parser parser;
|
||||
JSON_Writer writer;
|
||||
intfstream_t *file;
|
||||
playlist_t *playlist;
|
||||
struct playlist_entry *current_entry;
|
||||
char *current_meta_string;
|
||||
char *current_items_string;
|
||||
@ -98,6 +86,19 @@ typedef struct
|
||||
enum playlist_label_display_mode *current_meta_label_display_mode_val;
|
||||
enum playlist_thumbnail_mode *current_meta_thumbnail_mode_val;
|
||||
enum playlist_sort_mode *current_meta_sort_mode_val;
|
||||
intfstream_t *file;
|
||||
playlist_t *playlist;
|
||||
|
||||
unsigned array_depth;
|
||||
unsigned object_depth;
|
||||
|
||||
bool in_items;
|
||||
bool in_subsystem_roms;
|
||||
bool capacity_exceeded;
|
||||
bool out_of_memory;
|
||||
|
||||
JSON_Parser parser;
|
||||
JSON_Writer writer;
|
||||
} JSONContext;
|
||||
|
||||
/* TODO/FIXME - global state - perhaps move outside this file */
|
||||
@ -195,15 +196,15 @@ static void path_replace_base_path_and_convert_to_local_file_system(
|
||||
strlen(in_path) - in_oldrefpath_length + 1);
|
||||
|
||||
#ifdef USING_WINDOWS_FILE_SYSTEM
|
||||
/* If we are running under a win fs, '/' characters
|
||||
* are not allowed anywhere. we replace with '\' and
|
||||
* hope for the best... */
|
||||
/* If we are running under a Windows filesystem,
|
||||
* '/' characters are not allowed anywhere.
|
||||
* We replace with '\' and hope for the best... */
|
||||
string_replace_all_chars(out_path,
|
||||
POSIX_PATH_DELIMITER, WINDOWS_PATH_DELIMITER);
|
||||
#endif
|
||||
|
||||
#ifdef USING_POSIX_FILE_SYSTEM
|
||||
/* Under posix fs, we replace '\' characters with '/' */
|
||||
/* Under POSIX filesystem, we replace '\' characters with '/' */
|
||||
string_replace_all_chars(out_path,
|
||||
WINDOWS_PATH_DELIMITER, POSIX_PATH_DELIMITER);
|
||||
#endif
|
||||
@ -233,7 +234,7 @@ static bool playlist_path_equal(const char *real_path,
|
||||
entry_real_path[0] = '\0';
|
||||
|
||||
/* Sanity check */
|
||||
if (string_is_empty(real_path) ||
|
||||
if (string_is_empty(real_path) ||
|
||||
string_is_empty(entry_path) ||
|
||||
!config)
|
||||
return false;
|
||||
|
@ -37,19 +37,19 @@
|
||||
|
||||
struct audio_mixer_userdata
|
||||
{
|
||||
unsigned slot_selection_idx;
|
||||
enum audio_mixer_stream_type stream_type;
|
||||
enum audio_mixer_slot_selection_type slot_selection_type;
|
||||
unsigned slot_selection_idx;
|
||||
};
|
||||
|
||||
struct audio_mixer_handle
|
||||
{
|
||||
nbio_buf_t *buffer;
|
||||
bool copy_data_over;
|
||||
bool is_finished;
|
||||
retro_task_callback_t cb;
|
||||
enum audio_mixer_type type;
|
||||
char path[4095];
|
||||
retro_task_callback_t cb;
|
||||
bool copy_data_over;
|
||||
bool is_finished;
|
||||
};
|
||||
|
||||
static void task_audio_mixer_load_free(retro_task_t *task)
|
||||
|
@ -50,18 +50,6 @@ enum core_updater_list_status
|
||||
CORE_UPDATER_LIST_END
|
||||
};
|
||||
|
||||
typedef struct core_updater_list_handle
|
||||
{
|
||||
core_updater_list_t* core_list;
|
||||
bool refresh_menu;
|
||||
retro_task_t *http_task;
|
||||
bool http_task_finished;
|
||||
bool http_task_complete;
|
||||
bool http_task_success;
|
||||
http_transfer_data_t *http_data;
|
||||
enum core_updater_list_status status;
|
||||
} core_updater_list_handle_t;
|
||||
|
||||
/* Download core */
|
||||
enum core_updater_download_status
|
||||
{
|
||||
@ -85,11 +73,20 @@ enum update_installed_cores_status
|
||||
UPDATE_INSTALLED_CORES_END
|
||||
};
|
||||
|
||||
typedef struct core_updater_list_handle
|
||||
{
|
||||
core_updater_list_t* core_list;
|
||||
retro_task_t *http_task;
|
||||
http_transfer_data_t *http_data;
|
||||
enum core_updater_list_status status;
|
||||
bool refresh_menu;
|
||||
bool http_task_finished;
|
||||
bool http_task_complete;
|
||||
bool http_task_success;
|
||||
} core_updater_list_handle_t;
|
||||
|
||||
typedef struct core_updater_download_handle
|
||||
{
|
||||
bool auto_backup;
|
||||
size_t auto_backup_history_size;
|
||||
char *path_dir_libretro;
|
||||
char *path_dir_core_assets;
|
||||
char *remote_filename;
|
||||
@ -97,35 +94,37 @@ typedef struct core_updater_download_handle
|
||||
char *local_download_path;
|
||||
char *local_core_path;
|
||||
char *display_name;
|
||||
retro_task_t *http_task;
|
||||
retro_task_t *decompress_task;
|
||||
retro_task_t *backup_task;
|
||||
size_t auto_backup_history_size;
|
||||
uint32_t local_crc;
|
||||
uint32_t remote_crc;
|
||||
enum core_updater_download_status status;
|
||||
bool crc_match;
|
||||
retro_task_t *http_task;
|
||||
bool http_task_finished;
|
||||
bool http_task_complete;
|
||||
retro_task_t *decompress_task;
|
||||
bool auto_backup;
|
||||
bool decompress_task_finished;
|
||||
bool decompress_task_complete;
|
||||
bool backup_enabled;
|
||||
retro_task_t *backup_task;
|
||||
enum core_updater_download_status status;
|
||||
} core_updater_download_handle_t;
|
||||
|
||||
typedef struct update_installed_cores_handle
|
||||
{
|
||||
bool auto_backup;
|
||||
size_t auto_backup_history_size;
|
||||
char *path_dir_libretro;
|
||||
char *path_dir_core_assets;
|
||||
core_updater_list_t* core_list;
|
||||
retro_task_t *list_task;
|
||||
retro_task_t *download_task;
|
||||
size_t auto_backup_history_size;
|
||||
size_t list_size;
|
||||
size_t list_index;
|
||||
size_t installed_index;
|
||||
unsigned num_updated;
|
||||
unsigned num_locked;
|
||||
enum update_installed_cores_status status;
|
||||
bool auto_backup;
|
||||
} update_installed_cores_handle_t;
|
||||
|
||||
/*********************/
|
||||
|
@ -26,8 +26,8 @@ typedef struct powerstate powerstate_t;
|
||||
|
||||
struct powerstate
|
||||
{
|
||||
enum frontend_powerstate state;
|
||||
int percent;
|
||||
enum frontend_powerstate state;
|
||||
};
|
||||
|
||||
/* TODO/FIXME - global state - perhaps move outside this file */
|
||||
|
@ -42,8 +42,8 @@ RETRO_BEGIN_DECLS
|
||||
typedef struct nbio_buf
|
||||
{
|
||||
void *buf;
|
||||
unsigned bufsize;
|
||||
char *path;
|
||||
unsigned bufsize;
|
||||
} nbio_buf_t;
|
||||
|
||||
#ifdef HAVE_NETWORKING
|
||||
|
Loading…
x
Reference in New Issue
Block a user