Author Topic: User Channel to Mask Filter  (Read 4534 times)

Hey guys!

So Ive been trying to solve this issue for some time now and havnt been able to find a solution so im hoping that someone here can help me.

So I am basically trying to create a filter for Substance Painter that will create a Mask for me. Ive created a "User0" channel and want that to be the mask that the filter creates.

I created a super simple filter but Im getting an error and cant really figure out what the issue is. Here is the error:
"[Effect Procedural View] Effect selected can't be used as an effect because: generic output is defined and input doesn't match"

This is the current setup:



If anyone has a solution for this I would very much appreciate it!

Cheers guys!

hey, could you just try to place a level node between the input & the output?
Not sure it is this, but it may be.

I've created a few filters with the ability to plug a custom map and / or user0 as a manual painted mask.
You need to remove any usage from the input and output nodes.  once applied in painter, the filter will affect all channels, but you can enable / disable them manually in the program.

Hope this helps.

Bek


Did you ever find a solution that works Fearwar? I am trying to do exactly the same thing — It would be incredibly useful if the user channels could be fed to masks within SP. But it just doesn't seem to work. I tried your suggestion zurhoch (removing  usage from the in/out nodes) but SP still returns the

Code: [Select]
[Effect Procedural View] Effect selected can't be used as an effect because:
generic output is defined and input doesn't match

error when using it on a filter. Using it on a procedural fill doesn't error, but it just has the generic "image Input" / 0-1 greyscale slider; it doesn't read from the user channel at all.

What's strange is user channels are definitely being read in SD, but connecting them to an output doesn't work.
Last Edit: March 01, 2017, 08:34:46 am

Hi Bek, could you try this file in SP, and let me know if it's working?
Need to do the following:
1. add user0 channel to the project
2. add paint layer
3. right click the layer and add filter "Damascus Steel"
4. in the filter settings, under Pattern there's a switch called Custom Pattern - turn it on
5. click on the layer, you should only have user0 channel, paint on it and it should drive the effect of the filter

If this is the behaviour you are after, I will share the SBS with you so you can see how I've set it up, if it's not what you're after then I probably misunderstood what you guys are after, sorry.

Bek


Hey Zuroch, you're right on both accounts — that does work and it's not exactly what I'm after.

In your example, information is added to the user channel to blend between materials — I want this too. But instead of supplying the materials via the .sbsar, I want to have the user0 mask to apply to a group's mask. In this setup I'd use a layer to paint the user0 info, which the filter turns into a 'master mask' which is applied to a group's mask.

The simplest setup I can think of would be taking the userchannel, output that as a fill, and apply that fill to a mask in SP. But it just doesn't seem to work. User channels via filters work on layers, but not masks.

edit: here's the simple example, if you use it as a fill it does nothing; if you use it as a filter you get the error. The SBS is just an in/out node with no usage defined.

Nice damascus metal material by the way, I've been mucking around with it too (I'd really really like to replicate specific patterns like Wootz/Bulat rather than the modern pattern welded stuff, no luck on that yet either...)
Last Edit: March 02, 2017, 04:52:05 pm

Oh I see what you're after, having layers passing data from one to another. That would be very interesting indeed, and it's something I also asked for, along with instancing stacks from one layer to another etc.  I'm afraid I can't help here.

And, thanks.  I've made that filter for the specific designs I wasn't able to replicate procedurally.  Combine the two and you get some really nice looking patterns :]
Last Edit: March 02, 2017, 05:30:47 pm

Bek


So I was thinking about this and one reason it might not work is it's possible to create an infinite loop. If your user0 is an input, and the output is a fill, that can be applied to a layer that (potentially, though I'm not wanting to do this) feeds back into user0; and bam, recursion. So maybe that's why this doesn't work as expected.

However, it would be nice if it worked in other cases. I'm hoping someone from Allegorithmic can chime in.