mirror of
https://gitee.com/anod/open_agb_firm.git
synced 2025-05-06 05:44:11 +08:00
73 lines
1.8 KiB
C
73 lines
1.8 KiB
C
#pragma once
|
|
|
|
/*
|
|
* This file is part of open_agb_firm
|
|
* Copyright (C) 2021 derrek, profi200
|
|
*
|
|
* This program is free software: you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#include "error_codes.h"
|
|
|
|
struct global_oaf_config
|
|
{
|
|
// [general]
|
|
u16 backlight; // Both LCDs.
|
|
bool directBoot;
|
|
bool useGbaDb;
|
|
|
|
// [video]
|
|
u8 scaler; // 0 = 1:1, 1 = bilinear (GPU) x1.5, 2 = matrix (hardware) x1.5.
|
|
float gbaGamma;
|
|
float lcdGamma;
|
|
float contrast;
|
|
float brightness;
|
|
|
|
// [game]
|
|
u8 saveSlot;
|
|
// TODO: Per-game save type override.
|
|
|
|
// [advanced]
|
|
bool saveOverride;
|
|
u16 defaultSave;
|
|
|
|
// [boost]
|
|
u8 savePolicy;
|
|
u8 cheatMode;
|
|
u8 haltMode;
|
|
};
|
|
|
|
#define SAVE_POLICY_GBADB 0
|
|
#define SAVE_POLICY_FIRM 1
|
|
#define SAVE_POLICY_SRAM 2
|
|
#define SAVE_POLICY_POPUP 3
|
|
#define SAVE_POLICY_SIZE 4
|
|
|
|
#define HALT_MODE_POWEROFF 0
|
|
#define HALT_MODE_REBOOT 1
|
|
#define HALT_MODE_SIZE 2
|
|
|
|
#define FIRMPATH_INCOME (const char*)0x20001000
|
|
#define FIRMPATH_SIZELIMIT 0x40
|
|
|
|
Result oafParseConfigEarly(void);
|
|
u16 oafGetBacklightConfig(void);
|
|
Result oafInitAndRun( char * , bool * );
|
|
void oafUpdate(void);
|
|
void oafFinish(void);
|
|
Result oafPreboot( const char * );
|
|
bool oafRebootReady( void );
|
|
int oafCheatMode(void);
|
|
int oafHaltMode(void);
|