Difference between revisions of "love.graphics.newFramebuffer"

(Added newin template)
m (width used twice instead of width/height)
Line 20: Line 20:
 
=== Arguments ===
 
=== Arguments ===
 
{{param|number|width|The desired width of the framebuffer.}}
 
{{param|number|width|The desired width of the framebuffer.}}
{{param|number|height|The desired width of the framebuffer.}}
+
{{param|number|height|The desired height of the framebuffer.}}
 
=== Returns ===
 
=== Returns ===
 
{{param|Framebuffer|framebuffer|A new framebuffer with specified with and height.}}
 
{{param|Framebuffer|framebuffer|A new framebuffer with specified with and height.}}

Revision as of 19:07, 14 November 2010

Available since LÖVE 0.7.0
It is not supported in earlier versions.


Creates a new framebuffer object for offscreen rendering.

Function

Synopsis

framebuffer = love.graphics.newFramebuffer( )

Arguments

None.

Returns

Framebuffer framebuffer
A new framebuffer with width/height equal to the window width/height.

Function

Synopsis

framebuffer = love.graphics.newFramebuffer( width, height )

Arguments

number width
The desired width of the framebuffer.
number height
The desired height of the framebuffer.

Returns

Framebuffer framebuffer
A new framebuffer with specified with and height.

Notes

Specifying a size different from the window size will not resize the canvas but the resulting image itself. To resize the canvas you have to use love.graphics.scale.

See Also