Page 1 of 1

Screen resolution?

Posted: Sun Dec 13, 2015 11:04 am
by sefan
Hi, What screen resolution would you recommend for an android game?
I mean the resolution i shall make all images and stuff for. I know i need to scale it when i install it on the phone/pad.

Re: Screen resolution?

Posted: Tue Dec 15, 2015 3:51 am
by peppage
I think they are making 4K screens now so 3840 × 2160 is probably suggested. You need to be careful because there is a size limit

Re: Screen resolution?

Posted: Tue Dec 15, 2015 7:01 pm
by Karai17
4k is really bad advice. The vast majority of Android phones are running at 720-1080p with a few high end 1440p devices and a few bleeding edge devices with 4k.

You should probably target 1080p, or have multiple assets for 1440, 1080, and 720.

Re: Screen resolution?

Posted: Tue Jan 05, 2016 1:51 pm
by teeter11
Make your app work on ALL resolutions and "scale" the things you draw. This is how they do it in the ROBLOX engine which is what i am going to call it.

Not to be confused with love.graphics.scale as it is not the same

Heres a basic example of scaling:

Code: Select all

function love.load()

love.window.setMode(0,0,{resizable = true,vsync = false}) --setting the size to 0,0 will set it to the complete size of your screen

windowX,windowY = love.graphics.getDimensions()

end

function love.draw()

love.graphics.print("Example",(windowX*.5),(windowY*.5)) -- Prints the text in the middle of the screen (to make it perfect you must subtract half the X and half the Y or even more)

end

function love.update()

windowX,windowY = love.graphics.getDimensions() -- updates the dimensions every frame

end

Re: Screen resolution?

Posted: Tue Jan 05, 2016 1:52 pm
by Karai17
That code has nothing to do with scaling. You're just positioning things relative to the size of the screen.