aspect ratio in fullscreen

For questions about using Classic.

Post » Sat Sep 29, 2012 12:49 pm

hello,
when I switch my game to fullscreen mode, it works. but when I try it on widescreen, it is strangely stretched.
is it possible to setup it in construct classic, that if there is wide screen and fullscreen, then it will not be stretched. so there will be for example black zones on left and right.
B
4
S
2
G
1
Posts: 143
Reputation: 1,211

Post » Sat Sep 29, 2012 4:29 pm

I think you need to set it to Letterbox scale on the configuration settins, that way it will remain its own aspect ratio and remain centered on the browser though it will scale nicely =)

(letterbox scale integer does the same but won't let it scale BIGGER than the layout size)
B
42
S
11
G
5
Posts: 446
Reputation: 6,417

Post » Sat Sep 29, 2012 7:09 pm

[QUOTE=Sargas] I think you need to set it to Letterbox scale on the configuration settins, that way it will remain its own aspect ratio and remain centered on the browser though it will scale nicely =)

(letterbox scale integer does the same but won't let it scale BIGGER than the layout size)[/QUOTE]Unfortunately it's not this way in Construct Classic, which is what the question concerned.

It's very easy to do in CC as well, though only for unscrolling layers. You simply just use the system condition Set Display size and the game will be rendered in the center of the letterbox after which you can set the game to run on fullscreen which in turn will give you the proper aspect ratio for the game (assuming the aspect ratio matches that of your display's, but you knew that already).

With scrolling content however the most straightforward solution is to create an unscrolling layer and create the letterboxing yourself. You'll also have to make use of Unbounded scrolling to make it possible to scroll outside the layout bounds, which is necessary for the object positions to appear correctly. You'll however be quick to notice that with Unbounded scrolling you'll have to account for any space outside the actual layout bounds, because the scrolling will reach these areas.

Here, I baked something similar to what you'll need. CC r2 cap:
http://up.servut.us/40386.5kwk4xh
B
11
S
2
G
3
Posts: 100
Reputation: 2,150

Post » Sun Sep 30, 2012 2:42 pm

Zotged: thanks very much, looks good. but what I need is keep aspect ratio on fullscreen. when i try this on fullscreen, it seems very wierd to me...
B
4
S
2
G
1
Posts: 143
Reputation: 1,211

Post » Sun Sep 30, 2012 10:02 pm

You'll have to elaborate further, since I obviously tested it in fullscreen before uploading and tried it again just now to be sure. It works perfectly for me, you might have some scaling issue with your graphics driver.

So what specifically is wrong with the display?
B
11
S
2
G
3
Posts: 100
Reputation: 2,150

Post » Mon Oct 01, 2012 11:21 am

Zotged: it was black, and after some time I could see only part of scene and right down corner. but I restart my computer and it seems ok now.
many thanks!
B
4
S
2
G
1
Posts: 143
Reputation: 1,211

Post » Mon Oct 01, 2012 7:21 pm

I tried to apply this to my game, but I have troubles with it...
It works for me only on widescreen, when I try this application on normal screen, then it is deformed in fullscreen (not stretched but shringed)...

what I need is, when it is on windows it will have allways 1024x768. but when it is on fullscreen and on normal screen I need my game fill the screen. but if screen is wider I need to keep aspect ratio and in these empty places (on left and right) I need some dark zones...
B
4
S
2
G
1
Posts: 143
Reputation: 1,211


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 6 guests