View Full Version : Setting color set values inside an MPxNode

10 October 2010, 05:27 PM
Hello guys!

I'm trying to set some per face colors using an MPxNode, I have 2 input meshes, and my node calculates some values based on the 2 meshes, and outputs the first mesh with some additional vertex color attributes.

But I get "object not exists" errors when I try to create a color set, or try to set the current color set on my output mesh. And when I set the color nothing happens. The color set is black, and I can't change any values. So that means I can't change the color set values inside a compute function, and I need to use a MPxCommand to do it?

regards, Pal.

10 October 2010, 10:15 AM
Hi Pal,

You might want to have a look for: MFnMesh::createColorSetDataMesh

It is a "hidden" method that allow you to create a colorSet without a shape.

Hope that helps,

10 October 2010, 12:22 PM
Hello Pascal!

Thanks for the tip, I'll try out later :) .

regards, Pal.

CGTalk Moderation
10 October 2010, 12:22 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.