Draws a rectangle.
love.graphics.rectangle( mode, x, y, width, height )
DrawMode mode
number x
number y
number width
number height
Nothing.
Available since LÖVE 0.10.0
This variant is not supported in earlier versions.
Draws a rectangle with rounded corners.
love.graphics.rectangle( mode, x, y, width, height, rx, ry, segments )
DrawMode mode
number x
number y
number width
number height
number rx
number ry (rx)
number segments (nil)
Nothing.
function love.draw() love.graphics.rectangle("fill", 20, 50, 60, 120 ) end
© 2006–2016 LÖVE Development Team
Licensed under the GNU Free Documentation License, Version 1.3.
https://love2d.org/wiki/love.graphics.rectangle