love.graphics.getPixelHeight

Available since LÖVE 0.11.0
This function is not supported in earlier versions.

Gets the height in pixels of the window.

love.graphics.getHeight gets the height of the window in units scaled by the screen's DPI scale factor, rather than pixels. Use getHeight for calculations related to drawing to the screen and using the graphics coordinate system (calculating the center of the screen, for example), and getPixelHeight only when dealing specifically with underlying pixels (pixel-related calculations in a pixel Shader, for example).

Function

Synopsis

pixelheight = love.graphics.getPixelHeight( )

Arguments

None.

Returns

number pixelheight
The height of the window in pixels.

See Also


Other Languages