I have a problem with a background image for my game. The image has a resolution of 1920 x 1080 and is designed to work with resolutions down to 1280 x 720. In this case just the inner section of the image shall be shown (Position: (Resolution.width - 1920) / 2, (Resolution.height - 1080) / 2; Size: 1920, 1080). The positioning is no problem, but the scaling doesn't work. It seems like CEGUI (using 0.8.4 right now) always scales the image down to e.g. 1280 x 720 if this resolution is selected. For setting the size I use
Code: Select all
_window->setSize(CEGUI::USize(CEGUI::UDim(0.0f, float(w)), CEGUI::UDim(0.0f, float(h))));
with w = 1920.0, h = 1080.0 and _window is a CEGUI::Window (in this case a StaticImage).
The imageset looks like this:
Code: Select all
<?xml version="1.0" ?>
<Imageset name="MainMenu_Background" imagefile="ui_screen_bg_1_wBorders.png" nativeHorzRes="1920" nativeVertRes="1080" autoScaled="false" version="2">
<Image name="Background" xPos="0" yPos="0" width="1920" height="1080" />
</Imageset>
I disabled autoScaled because I thought this might cause the scaling, but it doesn't work.
Is it possible to use a scaling greater than the screen size without rescaling it? I think it should, don't see a reason why this shouldn't be possible. Is it a bug or am I doing something wrong?