Welcome to WSL!

New to the forum? Please read this and this.

SkinCorrector  [SUBMITTED]

Moderator: SecondMan

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

SkinCorrector

#1

Post by Millolab »

While working on a commercial I had to do some skin retouching, I was working in DaFusion (Fusion within Davinci) and I was trying to use the "Beauty" ofx that comes with Resolve but couldn't get the result I was looking for so I develop this macro to make my life easier.
It's obviously based on Frequency Separation, but I added some nice touches to make this one fast and very easy to use.

here a very quick tutorial


Cheers!
E.
com.Millolab.SkinCorrector.zip
Added in 7 minutes 40 seconds:
i forgot to mention this one is optimised for Fusion16. If you try and use it on F9 you'll get some strange results. The internal Blur nodes are set to "fast Gaussian" which is not there in F9.
You do not have the required permissions to view the files attached to this post.

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#2

Post by SecondMan »

Oooh! Another day, another submission! :)
Millolab wrote: Thu Dec 05, 2019 9:34 ami forgot to mention this one is optimised for Fusion16. If you try and use it on F9 you'll get some strange results.
Sigh. The bloody Fast Gaussian. I have yet to find an elegant solution to switch Filters between different Fusion versions, short of making it an explicit control on the Macro... I'm hoping for Fu17 the option will just be integrated in the Gaussian one.

Do you want to publish it in Reactor so it's not available for Fu9 at all? You can do it this way (see Minimum parameter at the bottom):
Code: [Select all] [Expand/Collapse] [Download] (com.Millolab.SkinCorrector.atom)
  1. Atom {
  2.     Name = "SkinCorrector",
  3.     Category = "Tools/Filter",
  4.     Author = "Emilio Sapia - Millolab",
  5.     Version = 3,
  6.     Date = {2019, 12, 5},
  7.     Description = [[<p>Frequency Separation made easy for skin retouching and beauty work. Fast and easy to use. <a href="https://youtu.be/y4lesRojEeA">Hop to YouTube</a> for a quick tutorial.</p>]],
  8.     Donation = {
  9.         URL = [[https://paypal.me/Millolab]],
  10.         Amount = "",
  11.     },
  12.  
  13.     Deploy = {
  14.         "Macros/Filter/SkinCorrector.setting",
  15.     },
  16.     Minimum = 16,
  17. }
I also added a clickable link for the YouTube clip as an example. Just let me know what you'd like to do... :)

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#3

Post by Millolab »

I’d love to see it up on Reactor for sure. I’ll add a core blur selection on the macro (as I did for the FastExpoGlow) as an update ASAP (btw new version of FastExpoGlow is coming!)! Thanks for the clickable link add!!

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#4

Post by SecondMan »

OK, this is not exactly elegant, but put the below Blur node in Fu9 and Fu16 and see what happens... :)

Code: Select all

{
	Tools = ordered() {
		Blur1 = Blur {
			CtrlWZoom = false,
			Inputs = {
				Filter = Input {
					Value = FuID { "Fast Gaussian" },
					Expression = "UseGPU ~= nil and \"Fast Gaussian\" or \"Gaussian\"",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 298, 17.6667 } },
		}
	}
}
I couldn't figure out a way to get Fusion's version in an expression (I think it's simply not exposed), but this leverages the fact that the UseOpenCL parameter in Fu9 has been deprecated in favour of the more generic UseGPU in later versions. Dirty, aye. Dirty. But it seems to work...

User avatar
Midgardsormr
Fusionator
Posts: 2101
Joined: Wed Nov 26, 2014 8:04 pm
Answers: 24
Location: Los Angeles, CA, USA
Been thanked: 22 times
Contact:

Re: SkinCorrector

#5

Post by Midgardsormr »

bmd._VERSION returns the version number in an expression. Unfortunately, it returns the wrong version in 16. It reports 15.0 instead of 16.1, but it should be sufficient to make the comparison if > 9.02.

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#6

Post by SecondMan »

Ahhh, thanks! There are quite a few ways to get to the version in the Console but none of those worked in expressions (like the more obvious fusion.Version, for example)

And it looked like bmd._VERSION didn't work either, but now I know what I did wrong...

bmd._VERSION returns a string, so you will have to do some formatting for it to work as a number, like splitting it at the first dot (.) or something. Or you can do bmd._VERSION:sub(1,2) which will return 15 (or 16 if the returned string is 16.1.1 - for example).

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#7

Post by Millolab »

Excuse my ignorance here... you’re making an expression to automatically set the blur type and thus make it F9 compatible?

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#8

Post by SecondMan »

Yup. :)

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#9

Post by Millolab »

❤️
I’d love to learn how!!

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#10

Post by SecondMan »

Just copy/paste that Blur node from a couple of posts back and ye shall learn!

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#11

Post by Millolab »

That’s LUA, right?
Damn so much to learn so little time... 😔

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#12

Post by SecondMan »

Yes, that's Lua. Lovely fast Lua :)

It's a "special" way of doing if-then-else expressions that's very convenient and efficient: https://www.steakunderwater.com/wesuckl ... f=6&t=1829

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#13

Post by Millolab »

❤️🙏🏼
Thanks!

User avatar
SecondMan
Site Admin
Posts: 4828
Joined: Thu Jul 31, 2014 5:31 pm
Answers: 31
Location: Vancouver, Canada
Been thanked: 39 times
Contact:

Re: SkinCorrector

#14

Post by SecondMan »

Any time!

Here's an expression that works with version numbers:

Code: Select all

tonumber(bmd._VERSION:sub(1,2)) >= 15 and "Fast Gaussian" or "Gaussian"

User avatar
Millolab
Fusionista
Posts: 792
Joined: Wed Oct 24, 2018 6:26 am
Answers: 4
Been thanked: 23 times
Contact:

Re: SkinCorrector

#15

Post by Millolab »

Do i have to send the Atom again?