this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

removed Integer Scale from the options, it works in non CRT mode only #1818

nesbox 1f3f722b 89c50825

+16 -34
-1
src/studio/config.c
··· 237 237 .volume = MAX_VOLUME, 238 238 .vsync = true, 239 239 .fullscreen = false, 240 - .integerScale = true, 241 240 #if defined(BUILD_EDITORS) 242 241 .devmode = false, 243 242 #endif
-20
src/studio/screens/mainmenu.c
··· 109 109 optionFullscreenSet, 110 110 }; 111 111 112 - static s32 optionIntegerScaleGet(void* data) 113 - { 114 - StudioMainMenu* main = data; 115 - return main->options->integerScale ? 1 : 0; 116 - } 117 - 118 - static void optionIntegerScaleSet(void* data, s32 pos) 119 - { 120 - StudioMainMenu* main = data; 121 - main->options->integerScale = (pos == 1); 122 - } 123 - 124 - static MenuOption IntegerScaleOption = 125 - { 126 - OPTION_VALUES({OffValue, OnValue}), 127 - optionIntegerScaleGet, 128 - optionIntegerScaleSet, 129 - }; 130 - 131 112 #if defined(CRT_SHADER_SUPPORT) 132 113 static s32 optionCrtMonitorGet(void* data) 133 114 { ··· 236 217 #endif 237 218 {"VSYNC", NULL, &VSyncOption, "VSYNC needs restart!"}, 238 219 {"FULLSCREEN", NULL, &FullscreenOption}, 239 - {"INTEGER SCALE", NULL, &IntegerScaleOption}, 240 220 {"VOLUME", NULL, &VolumeOption}, 241 221 {"SETUP GAMEPAD", showGamepadMenu}, 242 222 {""},
-1
src/studio/system.h
··· 122 122 123 123 bool fullscreen; 124 124 bool vsync; 125 - bool integerScale; 126 125 s32 volume; 127 126 tic_mapping mapping; 128 127
+16 -12
src/system/sdl/main.c
··· 588 588 589 589 static void calcTextureRect(SDL_Rect* rect) 590 590 { 591 - bool integerScale = studio_config(platform.studio)->options.integerScale; 591 + // Integer Scaling works in non CRT mode only 592 + bool integerScale = !studio_config(platform.studio)->options.crt; 592 593 593 594 s32 sw, sh, w, h; 594 595 SDL_GetWindowSize(platform.window, &sw, &sh); ··· 1567 1568 s32 w, h; 1568 1569 SDL_GetWindowSize(platform.window, &w, &h); 1569 1570 1570 - static const SDL_Rect Src[] = 1571 + s32 offset = tic->ram->input.mouse.x < TIC80_FULLHEIGHT / 2 1572 + ? TIC80_FULLWIDTH-TIC80_OFFSET_LEFT : 0; 1573 + 1574 + const SDL_Rect Src[] = 1571 1575 { 1572 - {0, 0, TIC80_FULLWIDTH, TIC80_OFFSET_TOP}, 1573 - {0, TIC80_FULLHEIGHT-TIC80_OFFSET_TOP, TIC80_FULLWIDTH, TIC80_OFFSET_TOP}, 1574 - {0, 0, TIC80_OFFSET_LEFT, TIC80_FULLHEIGHT}, 1575 - {TIC80_FULLWIDTH-TIC80_OFFSET_LEFT, 0, TIC80_OFFSET_LEFT, TIC80_FULLHEIGHT}, 1576 - {0, 0, TIC80_FULLWIDTH, TIC80_FULLHEIGHT}, 1576 + {offset, 0, TIC80_OFFSET_LEFT, TIC80_OFFSET_TOP}, // top border 1577 + {offset, TIC80_FULLHEIGHT-TIC80_OFFSET_TOP, TIC80_OFFSET_LEFT, TIC80_OFFSET_TOP}, // bottom border 1578 + {offset, 0, TIC80_OFFSET_LEFT, TIC80_FULLHEIGHT}, // left border 1579 + {offset, 0, TIC80_OFFSET_LEFT, TIC80_FULLHEIGHT}, // right border 1580 + {0, 0, TIC80_FULLWIDTH, TIC80_FULLHEIGHT}, // center 1577 1581 }; 1578 1582 1579 1583 const SDL_Rect Dst[] = 1580 1584 { 1581 - {0, 0, w, rect.y}, 1582 - {0, rect.y + rect.h, w, h - (rect.y + rect.h)}, 1583 - {0, rect.y, rect.x, rect.h}, 1584 - {rect.x + rect.w, rect.y, w - (rect.x + rect.w), rect.h}, 1585 - {rect.x, rect.y, rect.w, rect.h} 1585 + {0, 0, w, rect.y}, // top border 1586 + {0, rect.y + rect.h, w, h - (rect.y + rect.h)}, // bottom border 1587 + {0, rect.y, rect.x, rect.h}, // left border 1588 + {rect.x + rect.w, rect.y, w - (rect.x + rect.w), rect.h}, // right border 1589 + {rect.x, rect.y, rect.w, rect.h}, // screen 1586 1590 }; 1587 1591 1588 1592 for(s32 i = 0; i < COUNT_OF(Src); ++i)