BlueAmulet/OCEmu

High DPI Support?

samwalls opened this issue · 6 comments

When using the emulator on my machine which has a high-dpi screen, it's really difficult to read the text. Is there a way of configuring the emulator for different screen sizes currently?
If not, SDL apparently has a windowing flag called SDL_WINDOW_ALLOW_HIGHDPI maybe enabling this would help - however I think it has to be called when the window is created and an openGL context is attached (might not be accessible through the lua binding, but you know better than me).

Here's a picture for context ;)

screen5

Ahh thank you for reporting this, the SDL2 binding I uses is just a raw ffi binding to SDL2 so everything is accessable, though it currently doesn't know about the SDL_WINDOW_ALLOW_HIGHDPI flag

I'll go add that in and add the flag.

the SDL2 window is now being created with SDL_WINDOW_ALLOW_HIGHDPI, can you check and see if it's working properly now?

EDIT: I'm being told this won't matter on anything that isn't macOS, as the Windows and Linux backends don't support the HIGHDPI flag, and rely on the OS to scale the window up.

Until SDL2 gets proper highdpi support or Linux gets better low dpi window support, the best I can offer for now is a --highdpi flag you can pass to OCEmu

Thank's for looking into it - it was kind of looking bleak for high-dpi support anyway. I'll test it out when I get a chance.

Report back on this? how does the function work for you?

I was a bit of a bad person and forgot about this completely ;)

Anyway, for my configuration at least, you can consider it fixed!

ocemu

The computer on the right was opened with --highdpi