Jump to content
Sign in to follow this  
Furox

Deform Grid with attribute color

Recommended Posts

Hi guy!

I little question about how to deform a grid with the attribute color...

Is a simple question, but i don't know how :O!

 

Thank so much!

Share this post


Link to post
Share on other sites

By attribute color, you mean a kind of vector displacement ?

If you want to do it in SOP context (not at render time), then using a simple Point Wrangle with the following VEX code should do the trick (provided your Cd attribute is a point attribute):

@P += @Cd ;

If you meant classic displacement of points (along normal - so you need to get normals prior to the Point Wrangle node) with intensity driven by Cd attribute then :

@P += @N * len(@Cd) ; 

Note that len(@Cd) could be replace by only one component of your color attribute (Cd.x for red etc.), or by luminance if you linearly combine each component with proper weights.

If you want to do it through texture, then put an Attribute from Map node prior to the above solutions.

Last but not least, you can displace at render time, but that’s another story.

 

 

Edited by StepbyStepVFX

Share this post


Link to post
Share on other sites

Thank you, for the fast reply!
This is working!!
But, can i have mush control's on the height, the displacement and  the angle of my color?

With the attribute transfer, i can do a treshold, but not more..

I will share my scene, but I wish to have more control...

AttributeColor.hip

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×