Jump to content

Paint Sop


DaJuice

Recommended Posts

You're missing a step.

mantra can't pick up the colours you painted because the attribute Cd is not passed through. Depending on the shader you use, you might have to use an Attribute SOP to rename Cd to the same shader channel name, which is usually 'diff' for Diffuse.

To make sure, you can right click on the shader's Diffuse parameter & select Copy Parameter. If you're using Houdini 5.0.x, click on the 'Clipboard' icon beside the Presets button. In the pop-up, you'll see what has been copied:

Under References

ch("/shop/name_of_shader/colr")

ch("/shop/name_of_shader/colg")

ch("/shop/name_of_shader/colb")

The channel is just 'col' as r, g & b are the components.

For Houdini 5.5.x, you have to un-stow the bar to get to the clipboard. Alternatively, you can Right Click on another parameter & select paste Copied References to see the channel name then undo.

With the channel name, append an Attribute SOP to the Paint SOP & rename Cd to col(or whatever it is).

Now your beautifully painted cave should look like what you want. :)

I hope the above helps!

Cheers!

steven

Link to comment
Share on other sites

Hey Steven,

Is there a documented list of what attributes are accepted by Mantra? I've been hunting all over for this list so that I know what to rename to what and such. Although I have found some from the Output manual, but they seem to be very specific.

Also, is there any way to unwrap the geo with the diff attribute like you can with "mantra -u geo1" (which works with vertex instead, I guess)?

Thanks.

Alex

Link to comment
Share on other sites

Is there a documented list of what attributes are accepted by Mantra? I've been hunting all over for this list so that I know what to rename to what and such. Although I have found some from the Output manual, but they seem to be very specific.

There isn't a documented list of Attributes, at least not that I know of. It also depends on the shader you use. Most, if not all, of the default shaders uses 'diff' for Diffuse but I think the method I posted is a tried and tested way to verify or find out the name to rename the Attribute to.

Also, is there any way to unwrap the geo with the diff attribute like you can with "mantra -u geo1" (which works with vertex instead, I guess)?

I've never tried unwrap before so I can't tell you.

Anyone?

Cheers!

steven

Link to comment
Share on other sites

Uh sorry, I gotta admit I didn't understand much of what you said (it's like deep rasters all over again).

Don't be fool by the 'Houdini Master' title under my name. :lol: Nothing could be further from the truth.

Ok, my brain isn't working right now, but I'll have another stab at it.

Depending on the shader you use, you might have to use an Attribute SOP to rename Cd to the same shader channel name, which is usually 'diff' for Diffuse.

I have no shaders attached to my cave model. The last Sop is the Paint Sop.

With the channel name, append an Attribute SOP to the Paint SOP & rename Cd to col(or whatever it is).

Where do I copy Cd from?

Anyways I append an Attribut Sop (Point tab) and in the first field I paste Cd (which I don't know what it is) and rename it toooo...what?

Sorry, I realize these questions might sound stupid, but all this technical stuff is still new to me. :)

Link to comment
Share on other sites

When you use your Paint SOP to paint colors onto your points, a vector (?) attribute called Cd (Color Diffuse) is created. Since the Mantra (aka VMantra) doesn't recognize the old Cd attribute, you have to convert (aka "rename" in this case) the old Cd into something that Mantra can recognize, which in this case, "diff" is recognized by VMantra.

So in order to rename your attributes, you can simply use Attribute SOP to do it. Although I don't use Attribute SOP as much, but it's extremely useful when it comes to dealing with shader attributes.

Anyhow, I hope I understand it correctly. So please correct me if I am wrong.

Cheers,

Alex

Link to comment
Share on other sites

Hi DaJuice,

If you middle click on the Paint SOP node, you'll see "2 Point Attributes: Cd[3], Alpha[1]" in the pop-up. This tells you 'Cd' is copied to every point you painted on. 'Cd' stands for "Color diffuse".

Like Alex said, mantra is not picking up the 'Cd' attribute because 'diff' is used, in most, if not all, of the supplied shaders, for diffuse shading.

After reading through your first post again, I guess you're using a MOP instead of a SHOP. When you render with mantra3(omantra), the 'Cd' attribute is recognised, hence you render what you painted. When you render with mantra, however, the MOP is converted to a SHOP & the previous paragraph explains why.

To put it simply, append an Attribute SOP to the Paint SOP & under the Point tab, type 'Cd' in the 'From' field & 'diff' in the 'To' field.

I hope the above clears things up a bit.

Cheers!

steven

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...