1 /* RetroArch - A frontend for libretro. 2 * Copyright (C) 2011-2019 - Daniel De Matteis 3 * Copyright (C) 2016-2019 - Brad Parker 4 * 5 * RetroArch is free software: you can redistribute it and/or modify it under the terms 6 * of the GNU General Public License as published by the Free Software Found- 7 * ation, either version 3 of the License, or (at your option) any later version. 8 * 9 * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 10 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 11 * PURPOSE. See the GNU General Public License for more details. 12 * 13 * You should have received a copy of the GNU General Public License along with RetroArch. 14 * If not, see <http://www.gnu.org/licenses/>. 15 */ 16 17 #ifndef __PATHS_H 18 #define __PATHS_H 19 20 #include <boolean.h> 21 #include <retro_common_api.h> 22 23 #include <lists/string_list.h> 24 25 RETRO_BEGIN_DECLS 26 27 enum rarch_dir_type 28 { 29 RARCH_DIR_NONE = 0, 30 RARCH_DIR_SAVEFILE, 31 RARCH_DIR_SAVESTATE, 32 RARCH_DIR_CURRENT_SAVEFILE, 33 RARCH_DIR_CURRENT_SAVESTATE, 34 RARCH_DIR_SYSTEM 35 }; 36 37 enum rarch_content_type 38 { 39 RARCH_CONTENT_NONE = 0, 40 RARCH_CONTENT_MOVIE, 41 RARCH_CONTENT_MUSIC, 42 RARCH_CONTENT_IMAGE, 43 RARCH_CONTENT_GONG 44 }; 45 46 enum rarch_path_type 47 { 48 RARCH_PATH_NONE = 0, 49 RARCH_PATH_CORE, 50 RARCH_PATH_NAMES, 51 RARCH_PATH_CONFIG, 52 RARCH_PATH_CONTENT, 53 RARCH_PATH_CONFIG_APPEND, 54 RARCH_PATH_CORE_OPTIONS, 55 RARCH_PATH_DEFAULT_SHADER_PRESET, 56 RARCH_PATH_BASENAME, 57 RARCH_PATH_SUBSYSTEM 58 }; 59 60 void dir_clear(enum rarch_dir_type type); 61 62 size_t dir_get_size(enum rarch_dir_type type); 63 64 char *dir_get_ptr(enum rarch_dir_type type); 65 66 void dir_set(enum rarch_dir_type type, const char *path); 67 68 void dir_check_defaults(const char *custom_ini_path); 69 70 void path_deinit_savefile(void); 71 72 bool path_set(enum rarch_path_type type, const char *path); 73 74 void path_set_special(char **argv, unsigned num_content); 75 76 size_t path_get_realsize(enum rarch_path_type type); 77 78 struct string_list *path_get_subsystem_list(void); 79 80 char *path_get_ptr(enum rarch_path_type type); 81 82 const char *path_get(enum rarch_path_type type); 83 84 void path_clear(enum rarch_path_type type); 85 86 bool path_is_empty(enum rarch_path_type type); 87 88 enum rarch_content_type path_is_media_type(const char *path); 89 90 RETRO_END_DECLS 91 92 #endif 93