cfyzium / bearlibterminal

Interface library for applications with text-based console-like output
Other
119 stars 18 forks source link

Terminal is significantly scaled down on MacOS #3

Open l4tte opened 3 years ago

l4tte commented 3 years ago

The code

#include <stdio.h>
#include "BearLibTerminal.h"

int main()
{
    terminal_open();

    terminal_print(1, 1, "Hello, world!");
    terminal_refresh();

    while (terminal_read() != TK_CLOSE);

    terminal_close();
}

As taken from here will compile and run just fine, but the text is significantly scaled to 25% of the display

image

This happens with all BearLibTerminal terminals, for example, the SampleOmni program looks like this

image

And the mouse program looks like this (Mouse is in top right corner of screen)

image

redblobgames commented 3 years ago

My guess is that there's a mismatch between the window size in "points" and "pixels", and bearlibterminal is using one when it needs to use the other. I don't know how to fix it though.

l4tte commented 3 years ago

I've been messing around with it, and you're right. It's an issue with glut too for the same reason

quulah commented 3 years ago

Has someone managed to workaround this or find the root cause?

hazeled commented 3 years ago

It's most likely because of MacOS' retina HiDPI screens, they're scaled up and have more pixels than a standard screen

quulah commented 3 years ago

Yeah, sounds likely. I'm guessing we're waiting for this then: #9