Windows

ZGE Source Code discussion. Ask questions, present your changes, propose patches etc.

Moderator: Moderators

Post Reply
User avatar
Kjell
Posts: 1911
Joined: Sat Feb 23, 2008 11:15 pm

Windows

Post by Kjell »

Ok,

Let's try to get all this stuff right. Here's what I have in mind.

- Enable Minimize button ( not real-time )
- Enable Maximize button ( not real-time )
- Toggle Maximize button between Maximize and Fullscreen
- Enable user controlled Window resizing ( not real-time )
- Toggle between game staying active when minimized / out-of-focus

- Viewport
* Full ( Use Width / Height )
* Stretched
* Keep Aspect Ratio
* 1:1 Resolution
* Step ( Min, Max, Step )

- Windowed
* Specific Resolution
* User Defined

- Fullscreen
* Specific Resolution
* Use Desktop Resolution

- Range
* Minimum / Maximum supported Resolutions
* Unlimited

Some additional idea's

* Store supported resolutions in accessible array
* Selection menu lists supported resolution / hertz / depth
* Option to load & read configuration file before window is created

I've attached a example using a viewport that keeps aspect ratio, has a specific windowed resolution with unlimited range. Press F4 to switch to fullscreen, and F3 to toggle the viewport to stretched.

Comments & suggestions are welcome :)

K
Attachments
Window.zip
(5.25 KiB) Downloaded 1016 times
User avatar
VilleK
Site Admin
Posts: 2324
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

You sure are a completionist Kjell! :) I wonder does even large tools such as Unity provide all these options? For instance when would you not want to keep the aspect ratio? And when would you use the range-properties for limiting resolutions?

I'm not against it of course, I would like at least some these features too. If they can be implemented in a efficient manner without breaking anything else in ZGE. I'll help you implement it if you take charge of the changes.
User avatar
Kjell
Posts: 1911
Joined: Sat Feb 23, 2008 11:15 pm

Post by Kjell »

Hej Ville,

If I was a completionist .. i would have listed all kinds of window styles ( borderless window ), positioning methods and stuff like stay-on-top, process priority and such as well :wink: But those things are for others to mention / request. Viewport Step for example might be a bit too niche for a public implementation, but ignoring the aspect ratio ( which is still the default currently ) could be useful when you'd want users with a widescreen to have a wider view of the game while maintaining the vertical frustum ( something very common among 360 / PS3 games supporting un-letterboxed 480i ). Although a Ratio Range would be nice then as well :) And limiting the resolution range is something you'd probably want to use in combination with user controlled window scaling.

Anyway, let's try to decide what is mainstream enough, and leave the rest up to developers to insert into the source when needed.

*I noticed that in the example the viewport size can be a pixel off when not using stretch. And the positioning is a little weird as well, please ignore :roll:

K
User avatar
VilleK
Site Admin
Posts: 2324
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

Kjell wrote:Anyway, let's try to decide what is mainstream enough, and leave the rest up to developers to insert into the source when needed.
That is a very good principle I think. For every feature we need to ask ourselves: "how does this make the games created with zge better?". I mean you wouldn't dismiss a game just because it lacked a minimize-icon would you? ;) But you make a good case for the aspect-control. Just so that we understand the purpose for every feature.

While on the topic of source changes I'm currently revisiting the gamepad support we discussed earlier. I hope to make something out of that soon.
User avatar
Kjell
Posts: 1911
Joined: Sat Feb 23, 2008 11:15 pm

Post by Kjell »

8)

Depending on the PEGI/ESRB rating, minimize can be a deal-breaker :P

K
User avatar
jph_wacheski
Posts: 1005
Joined: Sat Feb 16, 2008 8:10 pm
Location: Canada
Contact:

Post by jph_wacheski »

wow,. that all sounds very good to me,. I am a fullscreen guy, if that was all that was supported personaly I would be happy,. however, I am sure many people will appretiate these features,. and when availible I will surely include them,. as well it does indeed make the system that much more profesional looking,. and usefull for a wider veriety of applications,. (porn games or gambeling or what ever, could always add a fake "work screen" image that could be called up at the press of a key otherwise ;))
iterationGAMES.com
User avatar
Kjell
Posts: 1911
Joined: Sat Feb 23, 2008 11:15 pm

Post by Kjell »

Hey jph,

The biggest feature out of everything listed for me personally is the fullscreen mode being able to use the current desktop resolution. I prefer playing PC games through TV-out, and 9 out of 10 times the extended desktop settings ( resolution / hertz ) are already the way you'd like them, so it's ideal if a game can just adjust to that.

But I also think many people have different preferences, so giving your game the freedom for them to set it the way they like it, is a small effort for what it gives you in return. ( Although that is probably personal as well :wink: )

K
Post Reply