📝 S42 CutFlow Text Overlay
Titles, labels, and meme text without ever leaving the graph
- clip
- clip
- frame_count
- info
Adding text to a video is one of those things that should be easy in ComfyUI and usually isn't - you end up exporting frames, labeling them in an image editor, and re-importing. S42CF_TextOverlay kills that whole detour: it renders text directly onto your IMAGE batch with all the essentials - multi-line support, bold, stroke outline, drop shadow, a semi-transparent background box, opacity - and positions it by normalized coordinates so it works at any resolution. It's the title card / label / meme-text node of GeekyGhost's S42 CutFlow suite.
The inputs that matter
The big ones for most people:
- text (string, default "Hello World") - multi-line via newlines. This is the whole point of the node.
- position_x / position_y (floats, 0–1, both default 0.5) - normalized position of the anchor point. 0/0 is top-left, 0.5/0.5 center, 1/1 bottom-right. Normalized means the same values look right at 512px or 4K.
- font_size (int, 8–400, default 48) - text size in pixels.
- text_color (hex, default #FFFFFF) - click the swatch... when it works. See the gotcha below.
Then the styling stack, which is where this node earns its keep:
- stroke_width (int, default 0) and stroke_color (hex, default #000000) - the outline. This is the single most important readability control for text over busy footage; even 2px of black stroke makes white text legible anywhere.
- shadow_offset (int, default 0) - drop shadow distance; 0 disables. A 2–4px shadow adds depth for title cards.
- bg_padding (int, default 0) and bg_opacity (float, default 0.5) - a background box. Set bg_padding above 0 to get the "YouTube subtitle" pill behind the text; bg_opacity controls how translucent the box is.
- opacity (float, default 1) - text opacity overall.
- bold (yes/no) and alignment (center/left/right) - the last bits of formatting.
How it works
Straightforward PIL rendering per frame: it lays the text out with the chosen font, applies stroke and shadow, optionally draws the background box, and composites the whole overlay onto each frame. Because it's plain PIL, it's fast, CPU-only, and deterministic. Outputs: clip (the text-burned IMAGE batch), frame_count, and info.
Installing it
Standard S42 CutFlow install:
cd ComfyUI/custom_nodes/
git clone https://github.com/GeekyGhost/S42-CutFlow.git
pip install -r S42-CutFlow/requirements.txt # Windows portable: python_embeded\python.exe -m pip
Or ComfyUI Manager → search S42 CutFlow → install → restart. It's under S42 CutFlow/Text.
Gotchas
The one you'll actually hit: the color picker is currently broken in this pack - the README says so in so many words. The hex color inputs will show as plain text fields rather than a working swatch, so type your hex by hand (#FF9900, etc.) and don't waste time hunting for the visual picker. Beyond that: remember the text is burned in for every frame of the clip - there's no start/end timing here (that's the pack's Lower Third node's job if you want timed appearances), so if you only want a title for the first two seconds, trim the clip to two seconds first, overlay, then rejoin. And if your text is disappearing, check opacity isn't at 0 and text_color isn't close to the background - the two classic silent failures.
Inputs (14)
| Name | Type | Default | Description |
|---|---|---|---|
| clip | IMAGE | Video clip to overlay text onto. | |
| text | STRING | Hello World | Text to render. Supports multi-line with newlines. |
| font_size | INT | 488–400 | Font size in pixels. |
| bold | COMBO | no | Use bold font variant. |
| text_color | STRING | #FFFFFF | Text color (hex). Click swatch to pick. |
| position_x | FLOAT | 0.500–1 | Horizontal position. 0=left edge, 0.5=center, 1=right edge. |
| position_y | FLOAT | 0.500–1 | Vertical position. 0=top, 0.5=center, 1=bottom. |
| alignment | COMBO | center | Text alignment relative to position point. |
| stroke_width | INT | 00–20 | Text outline/stroke width in pixels. 0 = no stroke. |
| stroke_color | STRING | #000000 | Text outline/stroke color (hex). Click swatch to pick. |
| shadow_offset | INT | 00–20 | Drop shadow offset in pixels. 0 = no shadow. |
| opacity | FLOAT | 1.000–1 | Text opacity. 0 = invisible, 1 = fully opaque. |
| bg_padding | INT | 00–50 | Background box padding around text. 0 = no background box. |
| bg_opacity | FLOAT | 0.500–1 | Background box opacity. Only used when bg_padding > 0. |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| clip | IMAGE | — |
| frame_count | INT | — |
| info | STRING | — |