mirror of https://github.com/stella-emu/stella.git
Made TIA window always open at a multiple of the minimum bounds
- this means that 320x240 is now the default 'base' size, and zoom levels are based on that - the TIA image is rendered into whatever sized window is active, meaning that NTSC and PAL modes now look similar Removed some 'small screen' dead code in FrameBuffer.
This commit is contained in:
parent
285583f959
commit
be775b53e3
|
@ -616,7 +616,7 @@ FBInitStatus Console::initializeVideo(bool full)
|
|||
const string& title = string("Stella ") + STELLA_VERSION +
|
||||
": \"" + myProperties.get(Cartridge_Name) + "\"";
|
||||
fbstatus = myOSystem.frameBuffer().createDisplay(title,
|
||||
myTIA->width() << 1, myTIA->height());
|
||||
TIAConstants::viewableWidth, TIAConstants::viewableHeight);
|
||||
if(fbstatus != FBInitStatus::Success)
|
||||
return fbstatus;
|
||||
|
||||
|
|
|
@ -88,8 +88,6 @@ bool FrameBuffer::initialize()
|
|||
// We can probably add ifdefs to take care of corner cases,
|
||||
// but that means we've failed to abstract it enough ...
|
||||
////////////////////////////////////////////////////////////////////
|
||||
bool smallScreen = myDesktopSize.w < FBMinimum::Width ||
|
||||
myDesktopSize.h < FBMinimum::Height;
|
||||
|
||||
// This font is used in a variety of situations when a really small
|
||||
// font is needed; we let the specific widget/dialog decide when to
|
||||
|
@ -98,17 +96,13 @@ bool FrameBuffer::initialize()
|
|||
|
||||
// The general font used in all UI elements
|
||||
// This is determined by the size of the framebuffer
|
||||
myFont = make_unique<GUI::Font>(smallScreen ? GUI::stellaDesc : GUI::stellaMediumDesc);
|
||||
myFont = make_unique<GUI::Font>(GUI::stellaMediumDesc);
|
||||
|
||||
// The info font used in all UI elements
|
||||
// This is determined by the size of the framebuffer
|
||||
myInfoFont = make_unique<GUI::Font>(smallScreen ? GUI::stellaDesc : GUI::consoleDesc);
|
||||
myInfoFont = make_unique<GUI::Font>(GUI::consoleDesc);
|
||||
|
||||
// The font used by the ROM launcher
|
||||
// Normally, this is configurable by the user, except in the case of
|
||||
// very small screens
|
||||
if(!smallScreen)
|
||||
{
|
||||
const string& lf = myOSystem.settings().getString("launcherfont");
|
||||
if(lf == "small")
|
||||
myLauncherFont = make_unique<GUI::Font>(GUI::consoleDesc);
|
||||
|
@ -116,9 +110,6 @@ bool FrameBuffer::initialize()
|
|||
myLauncherFont = make_unique<GUI::Font>(GUI::stellaMediumDesc);
|
||||
else
|
||||
myLauncherFont = make_unique<GUI::Font>(GUI::stellaLargeDesc);
|
||||
}
|
||||
else
|
||||
myLauncherFont = make_unique<GUI::Font>(GUI::stellaDesc);
|
||||
|
||||
// Determine possible TIA windowed zoom levels
|
||||
uInt32 maxZoom = maxWindowSizeForScreen(
|
||||
|
@ -126,8 +117,7 @@ bool FrameBuffer::initialize()
|
|||
myDesktopSize.w, myDesktopSize.h);
|
||||
|
||||
// Figure our the smallest zoom level we can use
|
||||
uInt32 firstZoom = smallScreen ? 1 : 2;
|
||||
for(uInt32 zoom = firstZoom; zoom <= maxZoom; ++zoom)
|
||||
for(uInt32 zoom = 2; zoom <= maxZoom; ++zoom)
|
||||
{
|
||||
ostringstream desc;
|
||||
desc << "Zoom " << zoom << "x";
|
||||
|
@ -841,11 +831,8 @@ void FrameBuffer::setAvailableVidModes(uInt32 baseWidth, uInt32 baseHeight)
|
|||
uInt32 aspect = myOSystem.settings().getInt(myOSystem.console().tia().frameLayout() == FrameLayout::ntsc ?
|
||||
"tia.aspectn" : "tia.aspectp");
|
||||
|
||||
// Figure our the smallest zoom level we can use
|
||||
uInt32 firstZoom = 2;
|
||||
if(myDesktopSize.w < FBMinimum::Width || myDesktopSize.h < FBMinimum::Height)
|
||||
firstZoom = 1;
|
||||
for(uInt32 zoom = firstZoom; zoom <= maxZoom; ++zoom)
|
||||
// Determine all zoom levels
|
||||
for(uInt32 zoom = 2; zoom <= maxZoom; ++zoom)
|
||||
{
|
||||
ostringstream desc;
|
||||
desc << "Zoom " << zoom << "x";
|
||||
|
|
|
@ -100,7 +100,7 @@ void TIASurface::initialize(const Console& console, const VideoMode& mode)
|
|||
mySLineSurface->setSrcSize(1, 2 * int(float(mode.image.height()) /
|
||||
floor((float(mode.image.height()) / myTIA->height()) + 0.5)));
|
||||
|
||||
#if 0
|
||||
#if 1
|
||||
cerr << "INITIALIZE:\n"
|
||||
<< "TIA:\n"
|
||||
<< "src: " << myTiaSurface->srcRect() << endl
|
||||
|
|
Loading…
Reference in New Issue