11#define WINDOW_WIDTH 640
12#define WINDOW_HEIGHT 480
30#define DTTR_DRIVER_AUTO "auto"
31#define DTTR_DRIVER_VULKAN "vulkan"
32#define DTTR_DRIVER_DIRECT3D12 "direct3d12"
33#define DTTR_DRIVER_DIRECT3D12_SHORT "d3d12"
34#define DTTR_DRIVER_OPENGL "opengl"
48#define DTTR_GAMEPAD_MAPPING_NONE (-1)
49#define DTTR_GAMEPAD_TRIGGER_THRESHOLD 300
51#define DTTR_GAMEPAD_SOURCE_TRIGGER_LEFT (SDL_GAMEPAD_BUTTON_COUNT)
52#define DTTR_GAMEPAD_SOURCE_TRIGGER_RIGHT (SDL_GAMEPAD_BUTTON_COUNT + 1)
53#define DTTR_GAMEPAD_SOURCE_COUNT (SDL_GAMEPAD_BUTTON_COUNT + 2)
55#define DTTR_CONFIG_SCHEMA_MAJOR_VERSION 1
56#define DTTR_CONFIG_DISABLED_MODS_MAX 32
57#define DTTR_MODS_SHADOW_PREFIX "_dttr_hot_"
59#define DTTR_GAMEPAD_AXIS_MAPPING_COUNT 3
60#define DTTR_GAMEPAD_AXIS_IDX_STICK_X 0
61#define DTTR_GAMEPAD_AXIS_IDX_STICK_Y 1
62#define DTTR_GAMEPAD_AXIS_IDX_CAMERA_RZ 2
64#define PCDOGS_GAMEPAD_IDX_UP 0
65#define PCDOGS_GAMEPAD_IDX_DOWN 1
66#define PCDOGS_GAMEPAD_IDX_LEFT 2
67#define PCDOGS_GAMEPAD_IDX_RIGHT 3
68#define PCDOGS_GAMEPAD_IDX_POV_UP 4
69#define PCDOGS_GAMEPAD_IDX_POV_DOWN 5
70#define PCDOGS_GAMEPAD_IDX_BTN_0 6
71#define PCDOGS_GAMEPAD_IDX_BTN_1 7
72#define PCDOGS_GAMEPAD_IDX_BTN_2 8
73#define PCDOGS_GAMEPAD_IDX_BTN_3 9
74#define PCDOGS_GAMEPAD_IDX_BTN_4 10
75#define PCDOGS_GAMEPAD_IDX_BTN_5 11
76#define PCDOGS_GAMEPAD_IDX_BTN_6 12
77#define PCDOGS_GAMEPAD_IDX_BTN_7 13
78#define PCDOGS_GAMEPAD_IDX_BTN_8 14
79#define PCDOGS_GAMEPAD_IDX_BTN_9 15
80#define PCDOGS_GAMEPAD_IDX_BTN_10 16
81#define PCDOGS_GAMEPAD_IDX_BTN_11 17
82#define PCDOGS_GAMEPAD_IDX_BTN_12 18
180 const char *mod_filename,
197#define DTTR_CONFIG_FILENAME "dttr.json"
DTTR_Graphics_COM_Direct3DDevice7 void DWORD flags DWORD count
@ DTTR_VERTEX_PRECISION_NATIVE
@ DTTR_VERTEX_PRECISION_SUBPIXEL
bool DTTR_Config_SetModEnabled(DTTR_Config *config, const char *mod_filename, bool enabled)
@ DTTR_GRAPHICS_API_DIRECT3D12
@ DTTR_GRAPHICS_API_OPENGL
@ DTTR_GRAPHICS_API_VULKAN
@ DTTR_CONFIG_VALUE_FLOAT
@ DTTR_CONFIG_VALUE_VERTEX_PRECISION
@ DTTR_CONFIG_VALUE_GAMEPAD_AXIS
@ DTTR_CONFIG_VALUE_PRESENT_FILTER
@ DTTR_CONFIG_VALUE_MINIDUMP_TYPE
@ DTTR_CONFIG_VALUE_STRING
@ DTTR_CONFIG_VALUE_LOG_LEVEL
@ DTTR_CONFIG_VALUE_GRAPHICS_API
@ DTTR_CONFIG_VALUE_SCALING_FIT
@ DTTR_CONFIG_VALUE_SCALING_METHOD
void DTTR_Config_SetDefaults(DTTR_Config *config)
Resets a config object to built-in defaults.
@ DTTR_SCALING_METHOD_PRESENT
@ DTTR_SCALING_METHOD_LOGICAL
const char * DTTR_Config_GraphicsAPIName(DTTR_GraphicsApi api)
Returns the config token for a graphics API selection.
#define DTTR_GAMEPAD_SOURCE_COUNT
int DTTR_Config_SchemaCount()
void DTTR_Config_ClearGamepadButtonMap(int *map)
bool DTTR_Config_SchemaChanged(const DTTR_Config *current, const DTTR_Config *base)
@ DTTR_SCALING_MODE_STRETCH
@ DTTR_SCALING_MODE_INTEGER
@ DTTR_SCALING_MODE_LETTERBOX
@ DTTR_CONFIG_CHOICES_MINIDUMP_TYPE
@ DTTR_CONFIG_CHOICES_GAMEPAD_AXIS
@ DTTR_CONFIG_CHOICES_GRAPHICS_API
@ DTTR_CONFIG_CHOICES_LOG_LEVEL
@ DTTR_CONFIG_CHOICES_SCALING_FIT
@ DTTR_CONFIG_CHOICES_SCALING_METHOD
@ DTTR_CONFIG_CHOICES_PRESENT_FILTER
@ DTTR_CONFIG_CHOICES_GAME_ACTION
@ DTTR_CONFIG_CHOICES_VERTEX_PRECISION
const char * DTTR_Config_LastError()
Returns details from the most recent config load failure, or NULL when none exist.
bool DTTR_Config_IsModDisabled(const DTTR_Config *config, const char *mod_filename)
const DTTR_ConfigChoice * DTTR_Config_Choices(DTTR_ConfigChoiceList list, int *count)
bool DTTR_Config_DisabledModsChanged(const DTTR_Config *current, const DTTR_Config *base)
const DTTR_ConfigChoice * DTTR_Config_ChoiceGet(DTTR_ConfigChoiceList list, int index)
#define DTTR_CONFIG_DISABLED_MODS_MAX
const DTTR_ConfigFieldSpec * DTTR_Config_SchemaGet(int index)
bool DTTR_Config_Save(const char *filename, const DTTR_Config *config)
Saves config values back to a strict JSON file.
bool DTTR_Config_Load(const char *filename)
Loads config values from a strict JSON file into the global config object.
#define DTTR_GAMEPAD_AXIS_MAPPING_COUNT
bool DTTR_Config_FieldChanged(const DTTR_Config *current, const DTTR_Config *base, const DTTR_ConfigFieldSpec *spec)
int DTTR_Config_ChoiceCount(DTTR_ConfigChoiceList list)
DTTR_ConfigValueType value_type
SDL_GPUFilter present_filter
DTTR_GraphicsApi graphics_api
int gamepad_button_map[DTTR_GAMEPAD_SOURCE_COUNT]
float mss_sample_preemphasis
char pcdogs_path[MAX_PATH]
DTTR_VertexPrecision vertex_precision
int gamepad_axes[DTTR_GAMEPAD_AXIS_MAPPING_COUNT]
DTTR_MinidumpType minidump_type
bool generate_texture_mipmaps
char log_file_path[MAX_PATH]
char disabled_mods[DTTR_CONFIG_DISABLED_MODS_MAX][MAX_PATH]
DTTR_ScalingMethod scaling_method
char saves_path[MAX_PATH]
int gamepad_axis_deadzone[DTTR_GAMEPAD_AXIS_MAPPING_COUNT]
DTTR_ScalingMode scaling_fit