App config settings for desktop width and height result in incorrect window size.

Amon

Member
Joined
Nov 19, 2018
Messages
64
#GLFW_WINDOW_TITLE="Template"
#GLFW_WINDOW_WIDTH=1920
#GLFW_WINDOW_HEIGHT=1080
#GLFW_WINDOW_RESIZABLE=False
#GLFW_WINDOW_FULLSCREEN=False
#GLFW_WINDOW_SAMPLES=0 'Set to number of samples for multisampling (glfw3 only).
#GLFW_WINDOW_DECORATED=True 'Set to false to create a broderless window (glfw3 only).

#GLFW_MACOS_RETINA_ENABLED=False

Above are the app config settings I'm using. When I run the app though the window is huge, bigger than the laptop display of 2560x1600

I have no idea why. On windows it worked fine.
 

Amon

Member
Joined
Nov 19, 2018
Messages
64
Argggh! Retina displays.

Ok. From what I've gathered retina displays work differently. I have no idea how to fix it except to divide the resolution by 2. It seems to fix it so that a 1920x1080 resolution works properly.

I set my appconfig settings to this. If there was a way to detect whether I am on a retinas display or not it would further make things easier but for now if the host is macos i put this.

Code:
#If HOST = "macos"
    #GLFW_WINDOW_WIDTH=2460/2           
    #GLFW_WINDOW_HEIGHT=1400/2
#Else
    #GLFW_WINDOW_WIDTH=1920           
    #GLFW_WINDOW_HEIGHT=1080
#End
 

MikeHart

Administrator
3rd Party Module Dev
3rd Party Target Dev
3rd Party Tool Dev
Joined
Jun 19, 2017
Messages
3,345
How was it behaving when you tested it with this line? I am sure you did, or?

Cerberus:
#GLFW_MACOS_RETINA_ENABLED=True
 
Top Bottom