a1studmuffin / Cataclysm-DDA-Android

An unofficial Android port of Cataclysm: Dark Days Ahead.
https://play.google.com/store/apps/details?id=com.MichaelDavies.CataclysmDDA
Other
60 stars 12 forks source link

Choose a better default terminal width + height on first run #13

Closed a1studmuffin closed 6 years ago

a1studmuffin commented 7 years ago

Currently the game defaults to 80x24 terminal size. While this works okay, the game runs best at higher sizes. However, we don't want to just see how many characters we can squeeze in at the device's native resolution at a 1:1 pixel ratio, since Android devices have much higher + more varied pixels-per-inch ratios compared to desktop monitors. It'd be cool if the game figured out a good default terminal size based on an integer scaling ratio so the fonts draw cleanly with no linear filtering, eg. 2x or 3x pixel size.

Dyrewulfe commented 7 years ago

Hmmm... So, we need to first find a means of reading the dpi, compare that against resolution, then choose an appropriate ratio?

a1studmuffin commented 7 years ago

Something like that yeah, though upon reflection I imagine that's probably a nightmare to get working reliably on Android. The other option is we just shoot from the hip and go with 120x36. It won't be perfect for all devices, but I think it will be a more reasonable default than 80x24, since the latter really doesn't work very well even though it's technically supported.

Dyrewulfe commented 7 years ago

800x480 screens are still a thing(which is kind of shameful), 120x36 would cause down-scaling with the default 8x16 font.