ControlNet Preprocess Lineart
The Character-Consistency Shortcut
- image
- image
If you've ever wanted to keep the same character across a series of generations, the community's oldest reliable trick is lineart: extract clean outlines from a reference, run ControlNet on those lines, and the model redraws the character with the same structure every time. Runware_controlnet_preprocess_lineart is that extraction step, hosted on Runware's cloud - image in, clean line map out, no local preprocessing models to install. The KB's controlnet essay calls lineart "the preferred conditioning for character consistency," and a high-scoring community thread demonstrated exactly that: reference + lineart keeping characters consistent across scenes.
How it works
The source image goes up, Runware extracts a line-art-style outline (softer and cleaner than Canny's hard edges), and a line map comes back as an IMAGE. That map is the guide - it holds the drawing's structure while the prompt supplies everything else: colors, style, background, mood. The generation follows the lines without being told to.
The inputs
- image (required) - the reference whose outlines you want.
- outputFormat (JPG/PNG/WEBP) and ttl (toggle + value) - delivery details. That's the whole node.
Output is image - the line map. Preview it before generating; if the lines are broken or noisy, the source image is the problem, not the workflow.
Wiring it up
Standard ControlNet chain: this node → RunwareBuild_controlNet (guideImage) → an image model's controlNet socket. For character work, pair it with a reference-image approach - lineart holds the drawing, the reference keeps the look. On the builder, weight tunes how faithfully the model follows the lines; start near 1.0 and back off if the output gets stiff.
Install and setup
Standard pack install: ComfyUI Manager → "Runware" → install → restart, or clone and pip install -r ComfyUI-Runware/requirements.txt (runware-sdk, pillow, soundfile). API key via Settings → Runware API key, RUNWARE_API_KEY, or runware auth login. Preprocessing is cheap per call; the ~$20 minimum top-up with a card on file is the standing entry friction.
Troubleshooting
- Lines too loose - if the output drifts from the reference, raise
weightin the ControlNet builder and consider the lineart-specific ControlNet model in its dropdown. - Map is noisy - the source image is too busy or low-contrast. Clean lineart needs a clear subject.
- Wrong flavor of lines - for manga/anime-style outlines specifically, use the
lineart_animepreprocessor instead; this one is the general-purpose variant.
It's the smallest possible input to a big win: one image in, a structure-lock for your character out. For anyone tired of the "same prompt, different face" lottery, this is the fix that's been working since the SD 1.5 era - now without the local dependency install.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| ttlopt | BOOLEAN | false | Enable to set ttl. Off uses the model's default. |
| ttl_valueopt | INT | 60 | Time-to-live (TTL) in seconds for generated content. Only applies when `outputType` is `URL`. |
| outputFormatopt | COMBO | JPG | File format for the generated image. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |