TEXT GENERATOR (JOV) π
Draw text into an image, fonts and all
- π
- πB
- πΌπ
- π
- πΌοΈ
- π·
ComfyUI can't render text. It can generate text in an image, but if you want an actual string drawn onto a canvas - a label, a caption, a timestamp, a watermark - you're usually reaching for a kludge. TEXT GENERATOR is Jovimetrix's take on the missing feature: a procedural text-drawing node that turns a string into an image and a mask, using your system's installed fonts. This is the pre-2.0 name; the current pack calls it TEXT GEN (JOV) π.
The inputs are self-explanatory and forgiving. π is your text (multiline, so yes, multi-line captions work). FONT is a dropdown of installed fonts - the defaults are the DejaVu and STIX families that ship with matplotlib, with more available as you add system fonts. FONT_SIZE is a float (default 10). Then the styling block: π text color and πB background color as 0β255 RGB, πΌπ the canvas size (VEC2, 512Γ512 default, 32β8192), π¦ a resize mode (NONE/FIT/CROP/ASPECT) for when text and canvas disagree, π rotation, π per-axis scale, and π³ edge blur. Outputs: πΌοΈ the rendered IMAGE and π· the text-as-MASK.
The mask output is the secret weapon. Text rendered as a mask means you can composite a label onto any image with a BLEND node, fade it in, or clip another image to the letter shapes. A word turned into a mask is just as useful as the colored version, and you get both for the price of one node. It's also genuinely handy for burning in batch metadata: string together your parameters with a STRINGER, render it here, and every output frame gets its settings stamped on it.
Since it leans on matplotlib for font handling, anything the font system knows is fair game - the pack's README calls out "full text generation support using installed system fonts" as a headline feature. That's also why FONT_SIZE and the styling options are the first things you touch: DejaVu at size 10 is a look, but not usually the one you want.
The catch is the standard legacy one. This node is the older "TEXT GENERATOR (JOV)" build and no longer appears under that name in current Jovimetrix - it was reworked into TEXT GEN (JOV) π (shorter name, same menu, plus alignment/justification options it didn't have before). If an old workflow reports this node missing, swap in TEXT GEN and the inputs map across almost 1:1.
To run it, install the pack. ComfyUI Manager β "Jovimetrix", or:
cd ComfyUI/custom_nodes
git clone https://github.com/Amorano/Jovimetrix.git
pip install -r Jovimetrix/requirements.txt
then restart. Dependencies are the pack-wide set - numpy, opencv-contrib-python, Pillow, matplotlib (the fonts live there), cozy-comfyui helpers - no model downloads. Keep ComfyUI at 0.1.3+ and mind the pack's v2.0 split: streaming/GLSL nodes moved to separate Jovi_* packs, which is why old workflow JSONs sometimes reference names today's install doesn't have.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| πopt | STRING | β | |
| FONTopt | COMBO | DejaVu Sans | 19 options: DejaVu Sans, DejaVu Sans Display, DejaVu Sans Mono, DejaVu Serif, DejaVu Serif Display, STIXGeneral, +13 |
| FONT_SIZEopt | FLOAT | 10.00 | β |
| πopt | VEC3 | 255,255,2550β255 | β |
| πBopt | VEC3 | 0,0,00β255 | β |
| πΌπopt | VEC2 | 512,51232β8192 | β |
| π¦opt | COMBO | NONE | 4 options: NONE, FIT, CROP, ASPECT |
| πopt | FLOAT | 0.00-180β180 | β |
| πopt | VEC2 | 1,1 | β |
| π³opt | FLOAT | 0.000β1 | β |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| πΌοΈ | IMAGE | β |
| π· | MASK | β |