A framebuffer is a chunk of memory that the GPU can render things onto. By default, the framebuffer that is used for rendering is the one belonging to the game window, but custom framebuffers can be used as well. A common use-case for custom framebuffers is applying post-processing effects: The entire scene is rendered to a framebuffer, and then the contents of that framebuffer are applied to a post-processing shader and rendered to the game window. The post-processing shader could do any number of things: scaling, antialiasing, motion blur, etc.
linear
] [#:mag-filter linear
] [#:wrap-s repeat
] [#:wrap-t repeat
]Create a new framebuffer that is width pixels wide and height pixels high.
min-filter and mag-filter determine the scaling algorithm
applied to the framebuffer when rendering. By default, linear scaling
is used in both cases. To perform no smoothing at all, use
nearest
for simple nearest neighbor scaling. This is typically
the best choice for pixel art games.
Return #t
if obj is a framebuffer.
Return the texture backing the framebuffer fb.
Return the default viewport (see Viewports) used by the framebuffer fb.
The default framebuffer.
Return the current framebuffer.
Render state for framebuffers (see Rendering Engine.)