Blender

Blender

Incorporating Photoshop's Vivid Light Blend Mode
So I modified an image in Photoshop and blended two layers using Vivid Light, and I'm attempting to recreate the effect in Blender in the compositor or VSE. Is there any addon or node setup that does this? I've tried to emulate the blend mode using my own node setups but it doesn't look quite right.
< >
Showing 1-4 of 4 comments
The Renderer Dec 2, 2017 @ 2:16pm 
---
From Adobe's website:
Vivid Light

Burns or dodges the colors by increasing or decreasing the contrast, depending on the blend color. If the blend color (light source) is lighter than 50% gray, the image is lightened by decreasing the contrast. If the blend color is darker than 50% gray, the image is darkened by increasing the contrast.
---
As formula:
(Blend > 0.5) * (1 - (1-Target) / (2*(Blend-0.5))) + (Blend <= 0.5) * (Target / (1-2*Blend))
(found here: http://www.deepskycolors.com/archive/2010/04/21/formulas-for-Photoshop-blending-modes.html)
---

So, should be easy enough to reproduce using nodes. No Photoshop here, though, so you'll have to try it yourself. Be aware that this most likely will not work in scene-referred color space. Didn't do the math myself but the reliance on 0.5 as mid point indicates that you may need display-referred color space to make this formula work (i.e. all color values have to be in the 0 to 1 range). As is the case with most Photoshop color blending modes.
TheByteNinjλ Dec 3, 2017 @ 7:21pm 
I've attempted to model that formula before using nodes, but there seems to be something missing. It always seems to output extreme 0 or 1 values from the blend layer. Not quite sure what's going wrong. Anyways, I've managed to somewhat replicate the vivid light mode using a node setup through trial and error, but of course it still isn't as good as the real thing.
JoeMammaFu May 2, 2019 @ 6:29pm 
Very glad to find this thread and thank you both for your contributions already!

Any chance for one of you to provide a bit more details on this? I can't quite figure out how to turn that formula into a node graph..? Or more details on how you "somewhat replicated" the results??

I've been struggling with this for a while as there is an amazing trick where you use vivid light to blend a blurred and inverted copy, and overlay the result to achieve a very flexible and artifact free sharpening and/or local contrast (Same thing you were trying to achieve TheByteNinjλ?)...



FYI, I found a discussion In the developers forums around 2014, where somebody actually wrote the code and got it approved (and even made a PowerPoint presentation!!) to incorporate the missing blending modes, however the idea was struck down because somebody didn't think anyone would ever need these blending modes *facepalm...
The Renderer May 2, 2019 @ 11:01pm 
Well, there is the Math node (under "Converter"). You can set that to all kinds of math operations (add, multiply, etc), including comparisons (e.g. less than). You can take a bunch of these math nodes and string them together to create that formula.

The inputs obviously are then the two pictures you want to layer (called "Blend" and "Target" in the formula).

Example:
2*Blend means you have a math node set to multiply, with one input being connected to the image node of the first picture and the second input simply manually set to 2.
(1-2*Blend) means you add another math node after that and set it to substract and the inputs to 1 and the output of the multiply node above.
(Target / (1-2*Blend)) means you add another math nod after that, set it to divide, and use a second image node with the second picture as one input and the result of the substract node above as the oder one.
... and so on, until you got the whole formula.

The > and < are a little more complicated. The output of those nodes is 0 or 1, depending on whether the statement is true. So you'll have to use those as inputs to further nodes that then let the information pass (or not) depending on the brightness value in order to get e.g. the (Blender > 0.5) statement. Kind of as a mask.


At least that's how it should work, I never did it myself. ;)
< >
Showing 1-4 of 4 comments
Per page: 1530 50

Date Posted: Dec 1, 2017 @ 5:26pm
Posts: 4