Jump to content
  • 0
grinseengel

Problem with screen resolution

Question

Ok, I have the possibility to get a 4k resolution. I have a Gforce 1070.

In the script I find the following code:

"local gfxmode = System: GetGraphicsMode (System: CountGraphicsModes () - 1)
if System: GetProperty ("devmode") == "1" then
gfxmode.x = math.min (1280, gfxmode.x)
gfxmode.y = Math: Round (gfxmode.x * 9/16)
windowstyle = Window.Titlebar "

How can I change the resolution?

Greetings Andreas

Share this post


Link to post

23 answers to this question

Recommended Posts

  • 0

This is the setting I am asking about:

Image1.jpg

  • Like 1

Share this post


Link to post
  • 0

Here is the code that creates the window:

local gfxmode = System:GetGraphicsMode(System:CountGraphicsModes()-1)
if System:GetProperty("devmode")=="1" then
	gfxmode.x = math.min(1280,gfxmode.x)
	gfxmode.y = Math:Round(gfxmode.x * 9 / 16)
	windowstyle = Window.Titlebar
else
	gfxmode.x = System:GetProperty("screenwidth",gfxmode.x)
	gfxmode.y = System:GetProperty("screenheight",gfxmode.y)
	windowstyle = Window.Fullscreen
end
window = Window:Create(title,0,0,gfxmode.x,gfxmode.y,windowstyle)

It is set up so that when launched from the editor, it creates a smaller window. If launched alone, it creates a fullscreen window at maximum resolution. This is because you often need to go back and forth with the editor when you are working on a project.

Share this post


Link to post
  • 0
Thank you for your prompt reply. However, this is exactly the script which is included in the 
tutorial level. My problem is that I can set in Editor mode and after the publish in the 
menu of the screen resolution max only 1280x 720 pixels. I can set a small resolution but 
none about it. Since my graphics card and my current games under 4k run I do not understand. 
Is it possibly the version of Lead Works?

Share this post


Link to post
  • 0

Leadwerks 4 does not support high DPI resolutions because it would make the GUI tiny.

Share this post


Link to post
  • 0
Ok, then is the max resolution at 1280x720 pixels? Or is there a way with Leaswerks also projects 
with higher resolution to create?

Share this post


Link to post
  • 0

It's dependent on your monitor resolution and DPI. What is your monitor resolution, and is it a high DPI monitor?

Share this post


Link to post
  • 0

Your max resolution will be 1920x1080.

Share this post


Link to post
  • 0
Quote

It is set up so that when launched from the editor, it creates a smaller window. If launched alone, it creates a fullscreen window at maximum resolution. This is because you often need to go back and forth with the editor when you are working on a project.

 

The resolution in the editor max 1280x 720 pixels is I understood. But I have even if the project is published only as a max. Resolution 1280x720 pixels.
A max resolution of 1920x1080 pixels I can not select as a standalone game.

What am I doing wrong?

 

 

Share this post


Link to post
  • 0

Run your game without the editor.

Share this post


Link to post
  • 0
Ok, that's what I did.

1) Project loaded
2) Publish project
3) Leadwerk finished
4) Project started from hard disk
5) max. Resolution = 1280x720 pixels in full screen
6) a higher resolution is not possible

Share this post


Link to post
  • 0

are you on the latest beta. as josh did fix a screen bug in that 

 

  • Thanks 1

Share this post


Link to post
  • 0

You can install the 4.6 beta, update your project, and see if that fixes the issue. If not I suggest uploading an example here so we can all try it.

 

Share this post


Link to post
  • 0
Ok, to load the beta steam asks me a betacode.

I can not download the 4.6 beta therefore.

Where can I get that?

Share this post


Link to post
  • 0

just select beta-latest build for testing  option and dont worry about code it not needed

it will start loading the beta after you come out of properties

 

 

Share this post


Link to post
  • 0
I now have the version 4.6 installed. However, my problem has not changed.

I can not get beyond a resolution of 1280x720 pixels.

Can it be because I do not use a monitor but a TV device?

Share this post


Link to post
  • 0

I doubt it. What is the display scaling factor in Windows display properties?

Please upload an example we can run.

Share this post


Link to post
  • 0
The scales in Windows, I've tried all three.

1) aspect ratio
2) Full screen
3) no scaling

All settings have not changed the appearance.

I have uploaded a start level.

test1.rar

Share this post


Link to post
  • 0
Thanks alot.

It works now.....

A question about Leadwerk 5. Is the version already available and is it supported 4k?

 

 

Share this post


Link to post
  • 0

Yes, Leadwerks 5 will support high DPI monitors. The GUI will scale to fit the DPI.

Share this post


Link to post
  • 0

It does not yet exist. In development.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Create Your Account

Sign in

Already have an account? Sign in here.

Sign In Now
×