UFO:Alien Invasion

Development => Newbie Coding => Topic started by: blau on September 29, 2013, 06:25:55 pm

Title: Prevent battlescape UI element upscaling?
Post by: blau on September 29, 2013, 06:25:55 pm
Hello!

I'm trying to make a battlescape UI for my standard resolution (1440x900). But UI images are looking blurry and things like bar nodes with the same size values result in bars rendered in different (pixel) sizes.

I've read in an old comment from 2010 that it looks like this because for a resolution greater than 1024x768 everything gets upscaled. Has anything changed since then and is there a way to prevent this?
Title: Re: Prevent battlescape UI element upscaling?
Post by: H-Hour on September 30, 2013, 05:44:24 pm
It's been a very long time since I worked with this, but I believe the game upscales from 1024x768 because that is the size set in the UI scripts. I believe the battlescape window size is set in base/ufos/ui/hud_default.ufo:

Code: [Select]
battlescape battlescape
{
pos "0 0"
size "1024 768"
align LAYOUTALIGN_FILL
}

Try playing around with the size parameter to see if you get any different results.
Title: Re: Prevent battlescape UI element upscaling?
Post by: geever on October 01, 2013, 12:00:01 am
It's been a very long time since I worked with this, but I believe the game upscales from 1024x768 because that is the size set in the UI scripts. I believe the battlescape window size is set in base/ufos/ui/hud_default.ufo:

As far as I know 1024x768 base is hardcoded... but I can be wrong...

-geever
Title: Re: Prevent battlescape UI element upscaling?
Post by: blau on October 02, 2013, 01:55:30 pm
Thanks for your answers.

I played around with battlescape and window node sizes but they are always rendered the same way. Looks like it is as geever says.  :'(
Title: Re: Prevent battlescape UI element upscaling?
Post by: Sandro on October 02, 2013, 07:05:34 pm
As far as I know 1024x768 base is hardcoded... but I can be wrong...

No, you are right -- it is hardcoded. Basically, UI is rendered on (virtual) 1024x768 display.