MX_Vignette
The corner-darkener that's secretly a grading blend
- images
- IMAGE
- MASK
Vignetting is the oldest trick in the film-grain-and-imperfections playbook: darken the corners a touch and the center pops, the frame feels intentional, and nobody can quite say why. MX_Vignette is this pack's take on it - and it's sneakily more flexible than a single "vignette strength" slider.
Here's the thing most people miss on first open: at the default settings this node doesn't darken anything. The whole effect is a blend between your original image and a brightness/saturation-adjusted copy, driven by a falloff mask that's strongest at the edges. brightness defaults to 0 (no change) and saturation to 0.5 (a 50% desaturate). So at defaults, you get slightly washed-out corners, not shadows. Pull brightness into negative territory - that's the actual vignette - and the corners go dark. It's a "darken what's at the edge" tool, not an auto-darkener, and that's exactly what makes it useful.
How it works
The node builds a radial distance field across your image: 0 at the center, 1 at the corners. That field becomes a mask, the image gets the brightness/saturation pass, and the two are composited so the edges show the adjusted copy while the center keeps the original. Because the mask is exposed as a second output, MX_Vignette doubles as a mask generator for other compositing nodes - darken selectively, blur the transition, feed it into a blend. The MASK output is white at the corners, black in the middle.
The controls shape that falloff rather than the color:
lens_shape(circle/rectangle) - a round optical falloff or a boxier one. For portraits, circle; for architectural or landscape shots, rectangle reads more natural.lens_curvy(default 3.0, up to 15) - the exponent on the distance. Lower values give a slow, gentle gradient; higher values make a tight dark ring right at the edges. This is the "how much does it announce itself" dial.lens_edge(around/symmetric) - this one matters on non-square images.aroundruns the falloff on your actual dimensions, so a 512×768 portrait gets an elliptical vignette.symmetricpads to a square, centers the falloff, and crops back - a true circular vignette on any aspect ratio.brightnessandsaturation- what actually happens at the edges. Negative brightness = dark corners; saturation below 1 desaturates them. Classic film look is both: darker and a touch desaturated.lens_zoom(default 0) - subtle scale on the mask. It's bumped +1 internally, and mostly shifts how far into the frame the falloff reaches. Leave it alone until you've twisted everything else.
The output is an IMAGE you can chain straight into a Save node or more grading steps.
Installing it
The pack is a one-liner, and this node carries no model files or heavy dependencies - just numpy, Pillow, torchvision, and OpenCV, which almost every ComfyUI install already has.
cd ComfyUI/custom_nodes
git clone https://github.com/Intersection98/ComfyUI_MX_post_processing-nodes
cd ComfyUI_MX_post_processing-nodes
pip install -r requirements.txt
Restart ComfyUI and it shows up under postprocessing/Effects. ComfyUI Manager can also find it - search "MX post processing" or "Intersection98" - and will handle the requirements.txt for you.
Where people get burned
- The defaults aren't a vignette. As above: no darkening until
brightnessgoes negative. Half the confusion about this node comes from people who dial one slider and expect corners. - The
cv2import. The pack's requirements listopencv-python, but if you've trimmed your environment and get aModuleNotFoundError: No module named 'cv2'on startup, that's it -pip install opencv-python. - The folder name is weird. The repo dir is
ComfyUI_MX_post_processing-nodes, with a stray hyphen. It's harmless, but if you ever poke at the Python path in a workflow, it'scustom_nodes.ComfyUI_MX_post_processing-nodes.
This pack is part of the EllangoK/ComfyUI-post-processing-nodes lineage (the README credits it and a couple of other classic post packs), and in the wild it's the thing people bolt onto the end of a workflow as a finishing grade - cool the tone, kill some contrast, add grain. MX_Vignette is the piece that sells the look by framing the subject. It won't fix a bad image, but it'll make a good one feel finished.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| lens_shape | COMBO | 2 options: circle, rectangle | |
| lens_edge | COMBO | 2 options: around, symmetric | |
| lens_curvy | FLOAT | 3.0 | — |
| lens_zoom | FLOAT | 0.0 | — |
| brightness | FLOAT | 0.00 | — |
| saturation | FLOAT | 0.50 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |
| MASK | MASK | — |