adonthell-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Adonthell-devel] Porting to SDL2


From: Kai Sterker
Subject: Re: [Adonthell-devel] Porting to SDL2
Date: Sat, 4 Jun 2016 22:33:31 +0200

On Thu, Jun 2, 2016 at 10:01 AM, Kai Sterker <address@hidden> wrote:
 
* switching between Window and Fullscreen must be implemented

That'll be today's task, together with introducing the Letterbox mode and some provisions for multi-monitor setups (should be able to at least pick the display on which to go fullscreen).

While it sounded simple enough, it took me until now to get working (mostly) correctly. The 3 modes are implemented as described and starting up into each mode works. Switching between the modes works for the most part, except when switching back from true fullscreen to letterbox mode. As the same behavior can be reproduced with SDL2's own test program, I reported a bug and call my own work done. Of course, I only tested under Linux so far, so more issues may come up when trying things out on other systems.
 
 
* some flickering while scrolling needs tracking down

I am wondering if this has something to do with flipping the render buffer at the wrong time. So I am thinking about enabling VSync and upping the framerate from 50 to 60. Since on my new PC it only takes about 1% CPU on average, that shouldn't be too bad ;-).

Turning on VSync certainly helped to get the flickering under control. I haven't yet touched any of the framerate related knobs inside the engine, but may also play around with those.


There is one larger task related to the text rendering, due to a change in the scaling implementation. [...] I guess that returning to the v0.3 way of scaling everything upfront is the better approach. While this makes scaling a bit less elegant, it'll avoid unnecessary complexity elsewhere.

I'll see if I can get that done tomorrow. Looks as simple as the screen modes, but might also hold some nasty surprises.

Kai

reply via email to

[Prev in Thread] Current Thread [Next in Thread]