From f16fed3d50fd3d56deb46a3d4641a81460e389de Mon Sep 17 00:00:00 2001 From: David Thompson Date: Wed, 12 Dec 2018 09:20:10 -0500 Subject: Update Chickadee manual and home page for 0.3.0. Better late than never! --- manuals/chickadee/Framebuffers.html | 55 +++++++++++++++++++++++++++++++++---- 1 file changed, 49 insertions(+), 6 deletions(-) (limited to 'manuals/chickadee/Framebuffers.html') diff --git a/manuals/chickadee/Framebuffers.html b/manuals/chickadee/Framebuffers.html index c57a82a..d7bedc4 100644 --- a/manuals/chickadee/Framebuffers.html +++ b/manuals/chickadee/Framebuffers.html @@ -16,16 +16,16 @@ Foundation Web site at http://www.gnu.org/licenses/fdl.html. The document was typeset with http://www.texinfo.org/ (GNU Texinfo). --> - + -The Chickadee Game Toolkit: Framebuffers + +Framebuffers (The Chickadee Game Toolkit) - - + + - @@ -94,7 +94,50 @@ Next: ,
-

2.4.9 Framebuffers

+

2.3.10 Framebuffers

+ +

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. +

+
+
Procedure: make-framebuffer width height [#:min-filter '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. +

+ +
+
Procedure: framebuffer? obj
+

Return #t if obj is a framebuffer. +

+ +
+
Procedure: framebuffer-texture fb
+

Return the texture backing the framebuffer fb. +

+ +
+
Procedure: framebuffer-viewport fb
+

Return the default viewport (see Viewports) used by the +framebuffer fb. +

+ +
+
Procedure: null-framebuffer
+

The default framebuffer. +

-- cgit v1.2.3