mirror of
https://github.com/Lorenzooone/cc3dsfs.git
synced 2026-08-14 04:46:27 -05:00
Fix risk of bad initial fullscreen mode
This commit is contained in:
@@ -9,6 +9,14 @@
|
||||
#include <queue>
|
||||
#include <cmath>
|
||||
|
||||
#define xstr(a) str(a)
|
||||
#define str(a) #a
|
||||
|
||||
#define APP_VERSION_MAJOR 0
|
||||
#define APP_VERSION_MINOR 0
|
||||
#define APP_VERSION_REVISION 0
|
||||
#define APP_VERSION_LETTER M
|
||||
|
||||
bool is_big_endian(void) {
|
||||
union {
|
||||
uint32_t i;
|
||||
@@ -18,6 +26,10 @@ bool is_big_endian(void) {
|
||||
return value.c[0] == 1;
|
||||
}
|
||||
|
||||
std::string get_version_string() {
|
||||
return std::to_string(APP_VERSION_MAJOR) + "." + std::to_string(APP_VERSION_MINOR) + "." + std::to_string(APP_VERSION_REVISION) + xstr(APP_VERSION_LETTER);
|
||||
}
|
||||
|
||||
std::string get_float_str_decimals(float value, int decimals) {
|
||||
float approx_factor = pow(0.1, decimals) * (0.5);
|
||||
int int_part = (int)(value + approx_factor);
|
||||
|
||||
Reference in New Issue
Block a user