▼V Reference
52 Find a task or a name
53 Modules to require
54 Scenes and sampling
55 Scene states
56 Animation requests
57 Native model details
58 Visuals
59 Geometry
60 Number Lines and Coordinate Decorations
61 Point Markers, Scatter Plots, and Filled Areas
62 Probability and Statistical Diagrams
63 Calculus lessons
64 Colors
65 Slides
66 Slide command-line tools
67 Source Programs and Authored Timelines
68 Interactive Preview and Inspection
69 Preview controls and diagnostics
70 Projects and Final Rendering
71 Project execution and cache details
72 Pict Renderer Protocol
73 3D reference map
74 3D:   Objects, groups, and paths
75 3D:   Cameras and projection
76 3D:   Views inside a Scene
77 3D:   Animating 3D objects
78 3D:   Animating the 3D camera
79 3D:   Cuts, caps, and section measurements
80 3D:   Supplementary surface, section, and annotation bindings
81 3D:   Cuts, sections, and numerical volume
82 3D:   Vectors
83 3D:   Linear maps and rotations
84 3D:   Affine transforms
85 3D:   Bounds, rays, and planes
86 3D:   Spatial maps and homotopies
87 3D:   Materials and lights
88 3D:   Lighting inspection
89 3D:   Shadow descriptors and stable bounds
90 3D:   Finite-light animation
91 3D:   Software finite-light evaluation
92 3D:   Colour space and final output
93 3D:   Relations and geometric annotations
94 3D:   Projected labels
95 3D:   Textured billboards
96 3D:   Spatial curves and vector diagrams
97 3D:   Spatial anchors and label layout
98 3D:   Anchors and projected labels
99 3D:   Parametric surfaces and calculus
100 3D:   Adaptive, trimmed, and implicit surfaces
101 3D:   Constructive solids
102 3D:   Surface constructors and queries
103 3D:   Meshes
104 3D:   Triangle topology
105 3D:   Polygonal faces
106 3D:   Deterministic convex hulls
107 3D:   Polyhedral duals
108 3D:   Schlegel diagrams and polyhedral nets
109 3D:   Conservative mesh correspondence
110 3D:   Topology-safe mesh matching
111 3D:   Checking and repairing mesh orientation
112 3D:   Clipping, sections, and transparency
113 3D:   Prepared spatial ODE trajectories and vector fields
114 3D:   Seeds and streamline sets
115 3D:   Poincare sections and return maps
116 3D:   Equilibria and local linearization
117 3D:   Flow maps and volume change
118 3D:   Drawing and inspecting trajectories
119 3D:   Reading prepared trajectories
120 3D:   Drawing vector fields and particles
121 3D:   Trajectory display
122 3D:   Spatial inspection and exact picking
123 3D:   Retained renderer backends
124 3D:   Compiled geometry and instances
125 3D:   Frame requests and results
126 3D:   Software rendering and statistics
127 3D:   Optional Racket/  Open  GL backend
128 Experimental Derived Visuals
129 Source Package Hygiene
On this page:
65.1 Slide descriptions and content
slide
make-slide
slot-content
paragraph-content
bullets
make-bullets
65.2 Inline Te  X text content
literal-text
tex-span
inline-text
text-content?
tex-span?
tex-span-source
tex-span-plain
parse-inline-text
normalize-text-content
text-content-runs
text-content-source
text-content->plain
text-run?
text-run-kind
text-run-content
text-run-plain
text-run-start
text-run-end
exn:  fail:  inline-tex?
exn:  fail:  inline-tex-code
exn:  fail:  inline-tex-start
exn:  fail:  inline-tex-end
65.2.1 Pict and image content
pict-content
image-content
65.3 Themes and formats
slide-format
widescreen
standard
portrait
square-format
slide-theme
lecture-light
lecture-dark
theme-spacing
role-style
65.4 Layouts and regions
layout-names
layout-ref
slot-spec
layout
region
hbox
vbox
65.5 Clips, beats, and narration
build-slide
hold-slide
beat
narration
make-narration
65.6 Slot actions
reveal-slot
conceal-slot
emphasize-slot
replace-content
play-content
65.7 Storyboards and transitions
storyboard
storyboard-shot
storyboard-cut
slide-transition
65.8 Named children and frozen checkpoints
semantic-part
semantic-group
content-state
65.9 Pict and Scene conversion
65.9.1 Pict output
slide->pict
storyboard->pict
storyboard->picts
content-width
content-height
content-theme
content-format
content-color
65.9.2 Scene and timeline output
slide->scene
storyboard->scene
storyboard->timeline
scene-slot-id
scene-slot-ref
65.10 Native, mathematical, and geometry content
65.10.1 Native Scene content
scene-content
visual-content
65.10.2 Mathematical content
math-content
65.10.3 Geometry content
geometry-content
65.11 Preparation and inspection
65.11.1 Preparation
prepare-slide!
prepare-storyboard!
prepared-duration
storyboard-match-report
prepared-slide?
prepared-slide-clip?
prepared-storyboard?
65.11.2 Inspection helpers
storyboard-ref
storyboard-with-theme
storyboard-with-format
slide-ref
check-storyboard
65.12 Project sources
storyboard-source
make-storyboard-source
65.13 Gallery catalogue
slide-gallery-entries
slide-gallery-categories
select-slide-gallery-entries
make-slide-gallery
slide-gallery-entry?
slide-gallery-entry-id
slide-gallery-entry-category
slide-gallery-entry-title
slide-gallery-entry-description
slide-gallery-entry-requirements
slide-gallery-entry-example
slide-gallery-entry-source
65.14 Core predicates and read-only accessors
slide?
content?
slide-format?
slide-theme?
layout?
slot-spec?
slide-clip?
beat?
slide-action?
narration?
storyboard?
slide-transition?
semantic-group?
semantic-part?
content-state?
diagnostic?
exn:  fail:  slides?
slide-id
slide-layout
slide-slots
slide-appearance
slide-notes
slide-format-id
slide-format-width
slide-format-height
slide-theme-id
slide-theme-colors
slide-theme-typography
slide-theme-spacing
slide-theme-decorations
layout-id
layout-slots
slot-spec-name
slot-spec-required?
slot-spec-role
slide-clip-slide
beat-name
storyboard-id
storyboard-theme
storyboard-format
storyboard-motion
storyboard-subtitles?
slide-transition-effect
slide-transition-duration
slide-transition-keys
slide-transition-direction
slide-transition-easing
slide-transition-scale
slide-transition-color
slide-transition-depth
diagnostic-severity
diagnostic-code
diagnostic-path
diagnostic-message
diagnostic-details
exn:  fail:  slides-code
exn:  fail:  slides-path
exn:  fail:  slides-details
9.3

65 Slides🔗ℹ

This chapter documents the public slide modules. It describes implemented operations, not proposed syntax. For a first lesson, see Make a slide and give it time. For short examples, see Slide recipes.

Unless stated otherwise, lengths are world units and durations are seconds. Numbers used for positions and times must be finite. IDs are nonempty interned symbols. Descriptions are immutable; preparation and rendering are explicit. Private struct fields and wire-format records are not public constructors.

    65.1 Slide descriptions and content

    65.2 Inline TeX text content

      65.2.1 Pict and image content

    65.3 Themes and formats

    65.4 Layouts and regions

    65.5 Clips, beats, and narration

    65.6 Slot actions

    65.7 Storyboards and transitions

    65.8 Named children and frozen checkpoints

    65.9 Pict and Scene conversion

      65.9.1 Pict output

      65.9.2 Scene and timeline output

    65.10 Native, mathematical, and geometry content

      65.10.1 Native Scene content

      65.10.2 Mathematical content

      65.10.3 Geometry content

    65.11 Preparation and inspection

      65.11.1 Preparation

      65.11.2 Inspection helpers

    65.12 Project sources

    65.13 Gallery catalogue

    65.14 Core predicates and read-only accessors

65.1 Slide descriptions and content🔗ℹ

syntax

(slide option ... [slot-name slot-option ... content] ...)

Creates a slide description. Put all slide keywords before the slot clauses. The keywords are those of make-slide, except #:slots. Slot keywords are those of slot-content. Slot names are literal identifiers. Unknown, duplicate, and missing required slots are errors.

procedure

(make-slide [#:id id    
  #:layout chosen-layout    
  #:slots slots    
  #:theme theme    
  #:notes notes]) → slide?
  id : symbol? = 'slide
  chosen-layout : (or/c symbol? layout?) = 'blank
  slots : (or/c hash? list?) = (hash)
  theme : (or/c #f slide-theme?) = #f
  notes : string? = ""
The procedural slide constructor. Supply a hash or association list from slot names to content or slot-content wrappers. A false theme inherits the conversion or storyboard theme. Notes do not become visible slide text.

procedure

(slot-content content    
  [#:key key    
  #:align align    
  #:valign valign    
  #:fit fit]) → any/c
  content : any/c
  key : (or/c #f symbol?) = #f
  align : (or/c #f 'left 'center 'right) = #f
  valign : (or/c #f 'top 'center 'bottom) = #f
  fit : (or/c #f 'contain 'cover 'natural) = #f
Wraps content with slot options. False options inherit the layout choice. A nonfalse continuity key must be unique within the slide. It names the same concept across slides, independently of the slot’s role.

procedure

(paragraph-content text    
  [#:role role    
  #:align align]) → content?
  text : (or/c string? text-content? tex-span?)
  role : (or/c #f symbol?) = #f
  align : (or/c #f 'left 'center 'right) = #f
Declares text to measure later. A plain string already adopts the slot’s text role. Use this form to override the role or line alignment. Text wraps at its selected size; it is not silently shrunk. This is not the native paragraph constructor.

syntax

(bullets option ... [item-name content] ...)

Creates named text items. The optional #:ordered? defaults to false. Item names are literal identifiers and must be unique. Select an item with a path such as '(body check). Items accept strings, paragraph-content, text-content?, and tex-span?, not arbitrary nested figures.

procedure

(make-bullets entries [#:ordered? ordered?]) → content?

  entries : list?
  ordered? : boolean? = #f
The procedural form of bullets. Each entry is a pair made with cons: an item symbol and its content.

65.2 Inline TeX text content🔗ℹ

 (require animate/text-content) package: animate

The normal slide text surfaces accept mixed ordinary prose and TeX mathematics. This module also provides explicit immutable content values for programmatic authoring. It is pure: parsing a string does not load a Pict renderer, invoke TeX, or create a file.

In an ordinary slot string, $...$ and \(...\) create inline mathematics. $$...$$ and \[...\] create display mathematics on a line of their own. Write \$ for a literal dollar sign. A bare or mismatched delimiter, nested delimiters, and empty mathematics are errors; use literal-text for code, currency, or other content that must remain literal. TeX comments inside a mathematical fragment are respected while the closing delimiter is found.

Racket and markup escaping are separate. For example, "As $h\\to0$" supplies one runtime TeX backslash, while "Price: \\$5; position: $x_0$" keeps the price literal and typesets the position. Formula source is trusted TeX input; the native preparation adapter invokes the configured TeX backend and is not a sandbox.

procedure

(literal-text source [#:plain plain]) → text-content?

  source : string?
  plain : (or/c #f string?) = #f
Creates one literal prose value. No delimiter in source is parsed. The optional whole-content plain value is used for plain-text export.

procedure

(tex-span source [#:plain plain]) → tex-span?

  source : string?
  plain : (or/c #f string?) = #f
Creates one nonempty, delimiter-free inline TeX fragment. Its optional plain fallback is used by text-content->plain.

procedure

(inline-text [#:plain plain] piece ...) → text-content?

  plain : (or/c #f string?) = #f
  piece : (or/c string? tex-span? text-content?)
Joins literal string pieces, explicit mathematical fragments, and existing content values. String pieces are literal here, not recursively parsed. Use this advanced constructor when a formula needs an authored plain-text fallback or when literal dollars are common.

procedure

(text-content? value) → boolean?

  value : any/c
Recognizes a normalized immutable mixed-content value.

procedure

(tex-span? value) → boolean?

  value : any/c
Recognizes an explicit TeX fragment.

procedure

(tex-span-source value) → string?

  value : tex-span?
Returns delimiter-free TeX source.

procedure

(tex-span-plain value) → (or/c #f string?)

  value : tex-span?
Returns the optional fragment plain-text fallback.

procedure

(parse-inline-text source) → text-content?

  source : string?
Parses one markup-enabled ordinary string. It reports an exn:fail:inline-tex? with runtime source offsets for malformed input.

procedure

(normalize-text-content value) → text-content?

  value : (or/c string? tex-span? text-content?)
Converts either shorthand or explicit input to the common immutable normal form.

procedure

(text-content-runs value) → list?

  value : text-content?
Returns source-ordered text, inline-math, display-math, and hard-break runs. Repeated equal formulas remain separate occurrences.

procedure

(text-content-source value) → (or/c #f string?)

  value : text-content?
Returns the original shorthand string when one exists.

procedure

(text-content->plain value) → string?

  value : text-content?
Returns a whole-content fallback when authored, otherwise joins ordinary prose, hard breaks, and each fragment fallback (or its TeX source). This operation does not typeset TeX.

procedure

(text-run? value) → boolean?

  value : any/c
Recognizes a normalized run.

procedure

(text-run-kind run) → symbol?

  run : text-run?
Returns 'text, 'inline-math, 'display-math, or 'hard-break.

procedure

(text-run-content run) → string?

  run : text-run?
Returns prose or delimiter-free TeX source.

procedure

(text-run-plain run) → string?

  run : text-run?
Returns the run’s deterministic plain-text representation.

procedure

(text-run-start run) → exact-nonnegative-integer?

  run : text-run?
Returns the inclusive runtime-string character offset.

procedure

(text-run-end run) → exact-nonnegative-integer?

  run : text-run?
Returns the exclusive runtime-string character offset.

procedure

(exn:fail:inline-tex? value) → boolean?

  value : any/c
Recognizes a source-local inline-TeX parser error.

procedure

(exn:fail:inline-tex-code value) → symbol?

  value : exn:fail:inline-tex?
Returns the error category.
Returns the inclusive error offset.
Returns the exclusive error offset.

Mixed text is measured and typeset only by prepare-slide! or prepare-storyboard!. Calling a conversion that has not prepared TeX-bearing text reports 'preparation-required. Prepared prose and formula runs share line baselines; a fraction or radical can increase line height, but cannot be split or silently scaled to fit. An atom wider than its line is a measured overflow error. Theme role, foreground, width, alignment, and line spacing are part of preparation, so later reveal, replacement, and Scene sampling replay fixed geometry without TeX calls or reflow. Raw draw-text calls, speaker notes, and SRT/WebVTT text remain literal.

65.2.1 Pict and image content🔗ℹ

procedure

(pict-content picture-or-factory [#:fit fit]) → content?

  picture-or-factory : any/c
  fit : (or/c 'contain 'cover 'natural) = 'contain
Wraps a Pict or a one-argument factory. A factory receives a content context during preparation. It must be deterministic and tolerate measurements at different widths. Pict drawing units use 100 units per slide authoring unit before fitting. An opaque Pict does not expose inner semantic parts.

syntax

(image-content path option ...)

Declares an image path, with optional #:fit (default 'contain) and #:asset-base. The syntax captures its source module’s directory as the default asset base. Without a source module, use a complete path or explicit base. Images are read at preparation, not by constructing the description.

65.3 Themes and formats🔗ℹ

procedure

(slide-format #:id id    
  #:width width    
  #:height height) → slide-format?
  id : symbol?
  width : real?
  height : real?
Creates a format with positive finite width and height.

The 16-by-9 format.
The 12-by-9 format.
The 9-by-16 format.
The 12-by-12 format.

procedure

(slide-theme #:id id    
  [#:extends parent    
  #:colors colors    
  #:typography typography    
  #:spacing spacing    
  #:decorations decorations]) → slide-theme?
  id : symbol?
  parent : (or/c #f slide-theme?) = #f
  colors : (or/c #f color-theme?) = #f
  typography : (or/c #f typography-theme?) = #f
  spacing : hash? = (hash)
  decorations : hash? = (hash)
Combines the existing color and typography systems with layout spacing and decoration. Missing settings inherit from the parent. Without a parent, colors use the native light theme and typography uses the lecture slide roles. Overrides are copied into complete descriptions.

The default light slide theme.
The default dark slide theme.

procedure

(theme-spacing theme key-or-number) → real?

  theme : slide-theme?
  key-or-number : (or/c symbol? real?)
Returns a named spacing value or the supplied nonnegative literal.

procedure

(role-style theme role) → text-style?

  theme : slide-theme?
  role : symbol?
Returns the native text style for a slide typography role.

Default spacing includes safe-x = 0.65, safe-y = 0.50, section-gap = 0.35, column-gap = 0.60, bullet-gap = 0.23, paragraph-gap = 0.25, footer-height = 0.35, subtitle-height = 0.85, title-band = 1.20, caption-band = 0.85, and math-minimum-scale = 0.70. Band tokens do not force built-in text to a fixed height; text is measured. Custom nonnegative numeric spacing tokens are allowed. The minimum math scale must lie in [0,1].

Decoration keys are title-rule? and footer-rule?, both false by default. Other decoration keys are errors. The slide lecture typography differs from the core native typography theme; use its actual roles rather than copying a native font-size table.

65.4 Layouts and regions🔗ℹ

procedure

(layout-names) → list?

Returns the built-in layout names.

procedure

(layout-ref name-or-layout) → layout?

  name-or-layout : (or/c symbol? layout?)
Resolves a catalogue name or returns the supplied layout. Unknown names are errors.

Layout

  

Required

  

Optional

title

  

title

  

subtitle

section

  

title

  

subtitle

title+body

  

title, body

  

none

title+two-column

  

title, left, right

  

none

title+figure

  

title, figure

  

body

figure+caption

  

figure

  

caption

figure-full

  

figure

  

none

equation-focus

  

equation

  

annotation

equation+explanation

  

equation, body

  

title

theorem

  

title, statement

  

body

quote

  

quote

  

attribution

blank

  

none

  

content

All built-ins also permit a footer. Hidden content retains its region. An omitted body in title+figure releases room to the figure. Portrait two-column text stacks at natural heights with a section gap. equation-focus groups its equation and annotation into one centered block.

procedure

(slot-spec name    
  [#:required? required?    
  #:role role]) → slot-spec?
  name : symbol?
  required? : boolean? = #f
  role : symbol? = 'body
Declares one custom slot and its typography role.

procedure

(layout #:id id    
  #:slots slots    
  #:arrange wide-tree    
  [#:standard standard-tree    
  #:portrait portrait-tree    
  #:fallback fallback]) → layout?
  id : symbol?
  slots : (listof slot-spec?)
  wide-tree : any/c
  standard-tree : any/c = #f
  portrait-tree : any/c = #f
  fallback : (or/c #f 'wide) = #f
Creates a custom box layout. Every supplied tree must name every declared region exactly once. The shared footer cannot be declared as a custom region. Standard format can use the wide tree; portrait needs its own tree. Other formats require a supported variant or explicit wide fallback.

procedure

(region name    
  [#:basis basis    
  #:grow grow    
  #:align align    
  #:valign valign    
  #:padding padding    
  #:min minimum    
  #:max maximum]) → any/c
  name : symbol?
  basis : (or/c real? 'content) = 0
  grow : real? = 0
  align : (or/c 'left 'center 'right) = 'left
  valign : (or/c 'top 'center 'bottom) = 'top
  padding : real? = 0
  minimum : real? = 0
  maximum : real? = +inf.0
Creates a named region. Basis, grow, padding, and minimum are nonnegative. Maximum is at least minimum, with positive infinity permitted.

procedure

(hbox [#:basis basis    
  #:grow grow    
  #:gap gap    
  #:padding padding    
  #:min minimum    
  #:max maximum]    
  child ...) → any/c
  basis : (or/c real? 'content) = 0
  grow : real? = 0
  gap : (or/c real? symbol?) = 'column-gap
  padding : real? = 0
  minimum : real? = 0
  maximum : real? = +inf.0
  child : any/c
Arranges children left to right. Numeric gaps are nonnegative; a symbol names a theme spacing value. The other allocation rules are the same as for regions.

procedure

(vbox [#:basis basis    
  #:grow grow    
  #:gap gap    
  #:padding padding    
  #:min minimum    
  #:max maximum]    
  child ...) → any/c
  basis : (or/c real? 'content) = 0
  grow : real? = 0
  gap : (or/c real? symbol?) = 'section-gap
  padding : real? = 0
  minimum : real? = 0
  maximum : real? = +inf.0
  child : any/c
Arranges children top to bottom. 'content asks for natural measured size; positive grow weights divide remaining space. These boxes do not run a general constraint solver.

65.5 Clips, beats, and narration🔗ℹ

procedure

(build-slide slide    
  [#:initial initial    
  #:poster poster    
  #:motion motion]    
  beat ...) → slide-clip?
  slide : slide?
  initial : any/c = 'visible
  poster : any/c = 'end
  motion : (or/c #f 'normal 'reduced) = #f
  beat : beat?
Adds timed beats to a slide. Initial visibility is 'visible, 'hidden, or a list of selectors. Beat names are unique. Ordinary embedded content starts at local time zero. A content-state stays at its selected checkpoint.

procedure

(hold-slide slide #:duration duration) → slide-clip?

  slide : slide?
  duration : real?
Makes a positive-duration clip holding the slide and its embedded poster states. A plain slide is not itself a valid storyboard shot.

procedure

(beat name    
  [#:duration duration    
  #:narration voice    
  #:tail-hold tail-hold]    
  action ...) → beat?
  name : symbol?
  duration : (or/c #f real?) = #f
  voice : (or/c #f narration?) = #f
  tail-hold : real? = 0
  action : slide-action?
Creates an interval. Supply a positive explicit duration or narration. With narration and no explicit duration, its length is the larger of narration end and action end, plus the nonnegative tail hold. An explicit duration must fit that span. Beats run in order; actions within one beat run concurrently.

A clip poster can be 'start, 'end, a nonnegative time, or a named beat boundary such as '(explain end). Visibility changes persist; emphasis returns to the base scale. Overlapping writes to the same property, including conflicting parent/child visibility, are errors.

syntax

(narration text option ...)

Uses the arguments of make-narration, but captures its source module’s directory as the default asset base. It does not generate speech.

procedure

(make-narration text    
  [#:audio audio    
  #:draft-duration draft-duration    
  #:at at    
  #:source-start source-start    
  #:duration duration    
  #:captions captions    
  #:asset-base asset-base]) → narration?
  text : string?
  audio : (or/c #f path-string?) = #f
  draft-duration : (or/c #f real?) = #f
  at : real? = 0
  source-start : real? = 0
  duration : (or/c #f real?) = #f
  captions : any/c = #f
  asset-base : (or/c #f path-string?) = #f
Supply exactly one of an audio path and a positive silent-draft duration. Preparation inspects recordings with ffprobe. Trimming is explicit and applies to recordings only. Nonnegative #:at delays the narration inside its beat, not the visual actions.

Captions are an ordered, nonoverlapping list of (list start end text) relative to the selected recording interval. False derives captions from the text; an empty list suppresses them. Captions must fit their interval. Relative paths used by the procedure need an explicit base.

65.6 Slot actions🔗ℹ

Selectors are a slot symbol or a nonempty symbol path, such as '(body check). They are resolved against the prepared content. Times and durations below are finite and nonnegative.

procedure

(reveal-slot selector    
  [#:at at    
  #:duration duration    
  #:effect effect]) → slide-action?
  selector : any/c
  at : real? = 0
  duration : real? = 0.4
  effect : (or/c 'fade 'instant) = 'fade
Makes selected content visible without changing the reserved layout space.

procedure

(conceal-slot selector    
  [#:at at    
  #:duration duration    
  #:effect effect]) → slide-action?
  selector : any/c
  at : real? = 0
  duration : real? = 0.4
  effect : (or/c 'fade 'instant) = 'fade
Hides selected content without removing its region.

procedure

(emphasize-slot selector    
  [#:at at    
  #:duration duration    
  #:scale scale]) → slide-action?
  selector : any/c
  at : real? = 0
  duration : real? = 0.8
  scale : real? = 1.08
Applies a temporary scale pulse, then restores the base scale. Scale is positive. No extra layout space is allocated for the pulse.

procedure

(replace-content slot    
  content    
  [#:at at    
  #:duration duration    
  #:effect effect]) → slide-action?
  slot : any/c
  content : any/c
  at : real? = 0
  duration : real? = 0.4
  effect : (or/c 'crossfade 'instant) = 'crossfade
Replaces one complete slot. All replacement alternatives are measured before playback. It does not perform an algebraic rewrite or infer glyph matches.

procedure

(play-content slot    
  [#:at at    
  #:from from    
  #:to to    
  #:duration duration    
  #:retime retime]) → slide-action?
  slot : any/c
  at : real? = 0
  from : any/c = #f
  to : any/c = 'end
  duration : (or/c #f real?) = #f
  retime : (or/c #f 'stretch) = #f
Advances one animated component in a complete slot. False from resumes its previous local time. An explicit from resets it. To accepts a time, start/end, or an adapter cue. The natural duration is to minus from. A different duration requires explicit stretch; backwards playback and stretching imported audio are not supported. Reveal/conceal never advance this clock by themselves.

65.7 Storyboards and transitions🔗ℹ

procedure

(storyboard [#:id id    
  #:theme theme    
  #:format format    
  #:motion motion    
  #:subtitles? subtitles?]    
  entry ...) → storyboard?
  id : symbol? = 'storyboard
  theme : slide-theme? = lecture-light
  format : slide-format? = widescreen
  motion : (or/c 'normal 'reduced) = 'normal
  subtitles? : boolean? = #t
  entry : any/c
Orders clips and bridges. A storyboard starts and ends with a shot. Occurrence IDs are unique. Adjacent shots imply a cut; consecutive transitions are errors. Subtitles are separate authored-timeline media, not burned into the usual Pict.

procedure

(storyboard-shot occurrence-id clip) → any/c

  occurrence-id : symbol?
  clip : slide-clip?
Names one use of a clip in a storyboard. The same clip can be used again under a different occurrence ID.
Creates a zero-duration transition.

procedure

(slide-transition [#:effect effect    
  #:duration duration    
  #:keys keys    
  #:direction direction    
  #:easing easing    
  #:scale scale    
  #:color color    
  #:depth depth]) → slide-transition?
  effect : symbol? = 'crossfade
  duration : real? = 0.6
  keys : (listof symbol?) = '()
  direction : (or/c #f 'left 'right 'up 'down) = #f
  easing : symbol? = 'linear
  scale : (or/c #f real?) = #f
  color : (or/c #f color-spec?) = #f
  depth : (or/c #f 'auto 'slot 'semantic) = #f
Creates a positive-duration bridge. The duration adds to the video rather than overlapping either clip. The valid effects and their options are listed below. Inapplicable options are errors, not ignored hints.

Effect

  

Behavior

crossfade

  

Fade the outgoing content out and incoming content in.

match

  

Match selected keys; other content crossfades.

push

  

Move both compositions by one canvas extent.

wipe

  

Keep both stationary and move a reveal boundary.

cover

  

Move the destination over the stationary source.

uncover

  

Move the source away from the stationary destination.

zoom

  

Grow source and destination with a crossfade.

fade-through

  

Fade to an opaque intermediate color, then from it.

Direction applies only to push, wipe, cover, and uncover; its default is left. Leftward travel brings the incoming composition from the right. These four effects require opaque endpoint backgrounds. They include backgrounds, decorations, and existing crops, not only content leaves.

Easing is one of 'linear, 'smooth (cubic smoothstep), 'ease-in, 'ease-out, or 'ease-in-out (quadratic). These are symbols for the slide API. They are not core rate-function constructors: native scene-play may instead take (smooth).

Scale applies only to zoom and lies strictly between 0 and 1; default 0.85. The source grows from 1 to its reciprocal; the destination grows from scale to 1. Color applies only to fade-through; default black. It resolves under the destination theme and must be opaque. The solid intermediate frame occurs at eased progress one half, not necessarily halfway in clock time.

Keys and depth apply to match. Missing, ambiguous, or wholly invisible keyed endpoints fail. Auto depth uses named-part matching or supported checkpoint replay where available, then falls back to compatible whole-asset matching or crossfade. Slot depth disables the recursive/replay mechanisms. Semantic depth requires supported correspondence for the requested keys and rejects unsupported domain relationships. It still permits defined create/remove/replacement behavior within a supported named group.

Clip clocks stay at the outgoing endpoint and incoming start. A matched pair of compatible content-state values deliberately replays its child interval through the bridge. This is the exception, not automatic playback of both clips.

Reduced storyboard motion replaces match, push, wipe, cover, uncover, and zoom with same-duration/easing crossfades. Cuts and fade-through retain their behavior. Per-clip reduced motion separately suppresses emphasis scaling and uses instant slot visibility changes without changing beat intervals. It does not replace arbitrary embedded animation choreography.

65.8 Named children and frozen checkpoints🔗ℹ

procedure

(semantic-part id    
  content    
  [#:x x    
  #:y y]    
  #:width width    
  #:height height    
  [#:align align    
  #:valign valign    
  #:fit fit]) → semantic-part?
  id : symbol?
  content : any/c
  x : real? = 0
  y : real? = 0
  width : real?
  height : real?
  align : (or/c 'left 'center 'right) = 'center
  valign : (or/c 'top 'center 'bottom) = 'center
  fit : (or/c 'contain 'natural) = 'contain
Names one child’s rectangle inside a group. X and y are top-left coordinates; y increases downwards. Width and height are positive. A group checks that each child rectangle stays inside its viewport.

procedure

(semantic-group #:width width    
  #:height height    
  part ...) → semantic-group?
  width : real?
  height : real?
  part : semantic-part?
Creates a positive-sized group with at least one part. Sibling IDs are unique. Groups can nest; identity is the full child path. Declaration order and visible text do not decide correspondence. Different siblings may overlap.

Matched child placements compose with the matched parent placement. Surviving names move, changed appearances crossfade within their moving rectangle, and created/removed children fade. This is not a general text or geometry morph.

procedure

(content-state content    
  #:at at    
  [#:viewport viewport]) → content-state?
  content : content?
  at : any/c
  viewport : list? = '(16 9)
Freezes math, geometry, or native Scene content at a time or domain cue. Viewport is a pair of positive finite dimensions. Both corresponding checkpoints need a compatible shared source and viewport for domain replay. This content remains fixed during a held or built shot.

A poster chooses how ordinary content is previewed; a content state fixes what that content shows. Those are different operations. State replay is visual-only: imported media is rejected rather than duplicated or stretched. Narrate outside that replay or author media explicitly in the parent. Unrelated formulas and independently realized constructions do not establish a replay interval merely because their slot keys agree.

65.9 Pict and Scene conversion🔗ℹ

65.9.1 Pict output🔗ℹ

procedure

(slide->pict source    
  [#:at at    
  #:theme theme    
  #:format format    
  #:size size    
  #:fit fit    
  #:debug debug]) → pict?
  source : any/c
  at : any/c = #f
  theme : (or/c #f slide-theme?) = #f
  format : (or/c #f slide-format?) = #f
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
  debug : list? = '()
Converts a slide, clip, context-bound reference, or compatible prepared value. A plain slide is fully populated. A clip defaults to its poster; at selects a numeric time or named beat boundary.

procedure

(storyboard->pict source    
  [#:at at    
  #:size size    
  #:fit fit    
  #:debug debug]) → pict?
  source : any/c
  at : any/c = 'end
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
  debug : list? = '()
Samples a whole storyboard at a numeric time or start/end.

procedure

(storyboard->picts source    
  [#:size size    
  #:fit fit    
  #:debug debug]) → (listof pict?)
  source : any/c
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
  debug : list? = '()
Returns one poster per shot, in storyboard order.

procedure

(content-width value) → real?

  value : any/c
(content-height value) → real?
  value : any/c
(content-theme value) → slide-theme?
  value : any/c
(content-format value) → slide-format?
  value : any/c
Returns the dimensions, theme, or format from a Pict-content factory context. Intrinsic measurement can supply a provisional height.

procedure

(content-color context role) → any/c

  context : any/c
  role : symbol?
Resolves a drawing color for a Pict factory from its provided context.

Size is false or a list of two positive exact pixel counts. False uses 80 pixels per world unit. An aspect mismatch is an error unless letterbox is explicit. Debug flags are slots, safe-area, and baselines. Ordinary output excludes the separate narration-subtitle track. In-memory content can resolve automatically; content needing file/tool effects requires explicit preparation first.

65.9.2 Scene and timeline output🔗ℹ

procedure

(slide->scene source    
  [#:theme theme    
  #:format format    
  #:size size    
  #:fit fit]) → scene?
  source : any/c
  theme : (or/c #f slide-theme?) = #f
  format : (or/c #f slide-format?) = #f
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
Returns an ordinary native Scene. A plain slide has duration zero. A clip retains its authored duration. Output size and fitting follow the Pict rules.

procedure

(storyboard->scene source    
  [#:size size    
  #:fit fit]) → scene?
  source : any/c
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
Converts the visual storyboard without its separate media tracks.

procedure

(storyboard->timeline source    
  [#:size size    
  #:fit fit]) → authored-timeline?
  source : any/c
  size : any/c = #f
  fit : (or/c 'error 'letterbox) = 'error
Also retains sections, beat cues, narration, subtitles, and explicitly imported child media in the ordinary authored timeline.

procedure

(scene-slot-id selector) → symbol?

  selector : any/c
Encodes a native slot ID. Use a slot symbol for a single slide, or a shot/slot path for a storyboard. Do not depend on the private encoded spelling.

procedure

(scene-slot-ref scene selector [#:at at]) → visual?

  scene : scene?
  selector : any/c
  at : real? = (scene-duration scene)
Returns the resolved native slot group at that time. At the clip endpoint it can receive ordinary native animation. This does not expose arbitrary inner formula or geometry IDs as outer Scene paths.

65.10 Native, mathematical, and geometry content🔗ℹ

65.10.1 Native Scene content🔗ℹ

procedure

(scene-content source    
  [#:fit fit    
  #:poster poster    
  #:media media    
  #:background? background?]) → content?
  source : (or/c scene? authored-timeline?)
  fit : (or/c 'contain 'cover 'natural) = 'contain
  poster : any/c = 'end
  media : (or/c #f 'visual-only 'import) = #f
  background? : boolean? = #f
Embeds a native Scene or timeline. Its camera defines the viewport. Its background is transparent unless enabled. A timeline with media requires an explicit import or visual-only policy. Native resource preparation remains the source author’s responsibility.

procedure

(visual-content visual    
  [#:fit fit    
  #:width width    
  #:height height]) → content?
  visual : visual?
  fit : (or/c 'contain 'cover 'natural) = 'contain
  width : (or/c #f real?) = #f
  height : (or/c #f real?) = #f
Wraps one native Visual. Positive dimensions can provide the envelope instead of measuring it.

Imported media runs only while its child clock advances. Audio must use bounded cues. Partial trimming through faded cue envelopes and overlapping parent/child subtitles are rejected instead of silently changing their meaning.

65.10.2 Mathematical content🔗ℹ

procedure

(math-content plan    
  [#:poster poster    
  #:fit fit    
  #:aspect aspect]) → content?
  plan : any/c
  poster : any/c = 'end
  fit : (or/c 'contain 'natural) = 'contain
  aspect : real? = 16/9
Wraps a mathematical presentation plan, not an arbitrary expression. Aspect is a positive preferred ratio for intrinsic measurement. Preparation still uses the actual slot region. Cues come from native compiled step boundaries.

Step cues can be (step-name start) or (step-name end); qualify with a segment index when names repeat. Existing domain context headings and working-row margins remain inside the viewport. Mathematical foreground/background colors must resolve to opaque colors. Fitting below the theme’s minimum math scale fails.

65.10.3 Geometry content🔗ℹ

procedure

(geometry-content program-or-timeline    
  [#:poster poster    
  #:fit fit    
  #:aspect aspect]) → content?
  program-or-timeline : any/c
  poster : any/c = 'end
  fit : (or/c 'contain 'natural) = 'contain
  aspect : real? = 16/9
Wraps a construction program or a ready timeline. Aspect is a positive preferred ratio. Preparation freezes its geometry, annotation layout, styles, reveal data, and timing. A ready timeline keeps its supplied realization.

Geometry supports the module-backed worker route. Workers reconstruct samplers from parent-prepared data without realizing the construction or placing labels again. Explicit realization in module-level user code can still repeat when that module is loaded in workers; the adapter cannot remove arbitrary source effects.

65.11 Preparation and inspection🔗ℹ

65.11.1 Preparation🔗ℹ

procedure

(prepare-slide! source    
  [#:theme theme    
  #:format format    
  #:asset-base asset-base]) → any/c
  source : any/c
  theme : (or/c #f slide-theme?) = #f
  format : (or/c #f slide-format?) = #f
  asset-base : (or/c #f path-string?) = #f
Measures and freezes a slide or clip, loading images, probing recordings, and preparing supported domain content as needed. It does not render the final video.

procedure

(prepare-storyboard! source 
  [#:asset-base asset-base]) 
 → prepared-storyboard?
  source : any/c
  asset-base : (or/c #f path-string?) = #f
Prepares shots, matching, timing, and media for a whole storyboard. A prepared value is tied to its theme and format; change the description and prepare again.

procedure

(prepared-duration source) → real?

  source : any/c
Returns the duration of prepared slide content. A prepared plain slide has zero duration.

procedure

(storyboard-match-report source) → list?

  source : any/c
Returns actual planned matching data. Prefer a prepared storyboard so this does not need to resolve anything. Each report records from/to, depth, reduced-motion policy, and matches. This is not a prediction based on unmeasured source.

procedure

(prepared-slide? value) → boolean?

  value : any/c
(prepared-slide-clip? value) → boolean?
  value : any/c
(prepared-storyboard? value) → boolean?
  value : any/c
Tests whether a value is one of the public prepared slide values.

65.11.2 Inspection helpers🔗ℹ

procedure

(storyboard-ref source occurrence-id) → any/c

  source : any/c
  occurrence-id : symbol?
Returns a shot with inherited storyboard context, or its prepared counterpart. Use this instead of an isolated card when investigating storyboard layout.

procedure

(storyboard-with-theme board theme) → storyboard?

  board : storyboard?
  theme : slide-theme?
Returns a new description with the requested theme.

procedure

(storyboard-with-format board format) → storyboard?

  board : storyboard?
  format : slide-format?
Returns a new description with the requested format.

procedure

(slide-ref slide slot) → any/c

  slide : slide?
  slot : symbol?
Returns a slot’s content without its options wrapper.

procedure

(check-storyboard source) → list?

  source : any/c
Reports declaration/preparation diagnostics. It does not invoke external tools or turn an unprepared declaration into measured output. Fatal validation occurs in constructors or preparation.

Slide exceptions expose a code, semantic path, and details. Domain exceptions retain their own types. No automatic font-fallback or effective-resolution advisories are supplied; absence of a diagnostic is not evidence of good type.

65.12 Project sources🔗ℹ

syntax

(storyboard-source module-path binding option ...)

Declares the exported storyboard to load. It accepts the keywords of make-storyboard-source and captures its declaring module’s directory as the default asset base. Construction alone starts neither an encoder nor workers.

procedure

(make-storyboard-source module-path    
  binding    
  [#:asset-base asset-base    
  #:seed seed]) → any/c
  module-path : path-string?
  binding : symbol?
  asset-base : (or/c #f path-string?) = #f
  seed : exact-integer? = 0
Returns a native module-builder source. A programmatic relative path requires an explicit base. The render project’s color and typography choices must agree with the storyboard. Parent-prepared text, math, and geometry are transferred through the normal verified project preparation route.

Prepared artifacts are data, not a promise of persistent frame-cache reuse. Workers need compatible source, Racket, and fonts. No font binaries are transferred. Arbitrary renderer factories and arbitrary closures are not made portable by this API. slides/render-example.rkt configures the ordinary runner from an exported film; it avoids duplicating those theme settings.

65.13 Gallery catalogue🔗ℹ

The ordered gallery catalogue.
The categories: layouts, transitions, integration.

procedure

(select-slide-gallery-entries [#:entries entries    
  #:category category]) → list?
  entries : (or/c #f list?) = #f
  category : (or/c #f symbol?) = #f
Selects entries without rendering. Explicit IDs must be nonempty, duplicate-free, and known. Their order is preserved. A category combined with IDs must contain every selected entry.

procedure

(make-slide-gallery [#:entries entries    
  #:category category    
  #:theme theme    
  #:format format    
  #:motion motion]) → storyboard?
  entries : (or/c #f list?) = #f
  category : (or/c #f symbol?) = #f
  theme : slide-theme? = lecture-light
  format : slide-format? = widescreen
  motion : (or/c 'normal 'reduced) = 'normal
Builds a storyboard from selected examples. Preparation and output remain separate. Listing does not typeset math or realize geometry. The CLI is documented in Gallery runner.

procedure

(slide-gallery-entry? value) → boolean?

  value : any/c
Tests whether a value is a gallery entry.

Returns the entry’s catalogue metadata.

65.14 Core predicates and read-only accessors🔗ℹ

These operations inspect values; they do not prepare or render them.

procedure

(slide? value) → boolean?

  value : any/c
(content? value) → boolean?
  value : any/c
(slide-format? value) → boolean?
  value : any/c
(slide-theme? value) → boolean?
  value : any/c
(layout? value) → boolean?
  value : any/c
(slot-spec? value) → boolean?
  value : any/c
(slide-clip? value) → boolean?
  value : any/c
(beat? value) → boolean?
  value : any/c
(slide-action? value) → boolean?
  value : any/c
(narration? value) → boolean?
  value : any/c
(storyboard? value) → boolean?
  value : any/c
(slide-transition? value) → boolean?
  value : any/c
(semantic-group? value) → boolean?
  value : any/c
(semantic-part? value) → boolean?
  value : any/c
(content-state? value) → boolean?
  value : any/c
(diagnostic? value) → boolean?
  value : any/c
(exn:fail:slides? value) → boolean?
  value : any/c
Tests whether a value has the indicated public type.

procedure

(slide-id value) → symbol?

  value : slide?
(slide-layout value) → layout?
  value : slide?
(slide-slots value) → hash?
  value : slide?
(slide-appearance value) → (or/c #f slide-theme?)
  value : slide?
(slide-notes value) → string?
  value : slide?
(slide-format-id value) → symbol?
  value : slide-format?
(slide-format-width value) → real?
  value : slide-format?
(slide-format-height value) → real?
  value : slide-format?
(slide-theme-id value) → symbol?
  value : slide-theme?
(slide-theme-colors value) → color-theme?
  value : slide-theme?
(slide-theme-typography value) → typography-theme?
  value : slide-theme?
(slide-theme-spacing value) → hash?
  value : slide-theme?
(slide-theme-decorations value) → hash?
  value : slide-theme?
(layout-id value) → symbol?
  value : layout?
(layout-slots value) → list?
  value : layout?
(slot-spec-name value) → symbol?
  value : slot-spec?
(slot-spec-required? value) → boolean?
  value : slot-spec?
(slot-spec-role value) → symbol?
  value : slot-spec?
(slide-clip-slide value) → slide?
  value : slide-clip?
(beat-name value) → symbol?
  value : beat?
(storyboard-id value) → symbol?
  value : storyboard?
(storyboard-theme value) → slide-theme?
  value : storyboard?
(storyboard-format value) → slide-format?
  value : storyboard?
(storyboard-motion value) → symbol?
  value : storyboard?
(storyboard-subtitles? value) → boolean?
  value : storyboard?
(slide-transition-effect value) → symbol?
  value : slide-transition?
(slide-transition-duration value) → real?
  value : slide-transition?
(slide-transition-keys value) → list?
  value : slide-transition?
(slide-transition-direction value) → (or/c #f symbol?)
  value : slide-transition?
(slide-transition-easing value) → symbol?
  value : slide-transition?
(slide-transition-scale value) → (or/c #f real?)
  value : slide-transition?
(slide-transition-color value) → (or/c #f color-spec?)
  value : slide-transition?
(slide-transition-depth value) → symbol?
  value : slide-transition?
(diagnostic-severity value) → symbol?
  value : diagnostic?
(diagnostic-code value) → symbol?
  value : diagnostic?
(diagnostic-path value) → list?
  value : diagnostic?
(diagnostic-message value) → string?
  value : diagnostic?
(diagnostic-details value) → any/c
  value : diagnostic?
(exn:fail:slides-code value) → symbol?
  value : exn:fail:slides?
(exn:fail:slides-path value) → list?
  value : exn:fail:slides?
(exn:fail:slides-details value) → any/c
  value : exn:fail:slides?
Returns the named field. Treat any returned private wrapper values as opaque.