How to change anisotropy direction in object, not in shader

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 06 June 2013   #1
Question How to change anisotropy direction in object, not in shader

Hi,

I have a doubt and probably its easy to solve, but I tried to find a solution all the day and I couldn't. The problem is that I have an anisotropic metal shader assigned to some objects, but the anisotropy rotation is not the way I want in some of the objects. I have to change the anisotropic rotation only in some objects, but keep it in the others, so I think I can't change it directly in the material.

Any advices on how I can do this rotation of the anisotropy in each object?

Thanks in advance.
 
Old 06 June 2013   #2
Why can't you copy the shader so it's separate from the original. Then change the direction and re-assignment the new shader to those specific objects?
 
Old 06 June 2013   #3
I can do it. And I can also use the Anisotropic Rotation map, but I would have to paint a texture manually. I know the two ways aren't very difficult, but I thought maybe there's some attribute in each object where I can set the value to 90 degrees, or some trick I could do in the UV Texture Editor, because I know that if I use a planar projection I can define the way the anisotropy will happen depending on the axis of the projection.
 
Old 06 June 2013   #4
Rotate the UV.
__________________
I sign here?
 
Old 06 June 2013   #5
When I rotate the UV, I rotate also the brushed metal texture in my bump map and I shouldn't rotate it.
 
Old 06 June 2013   #6
Quote:
Originally Posted by gustavopch
When I rotate the UV, I rotate also the brushed metal texture in my bump map and I shouldn't rotate it.


This is how I usually do in that case. One brushed metal texture in a shader with anisotropic direction the same way as the texture. UV all the polygon with that shader to the desired angle.
If you really don't want to or can't re-texture or re-uv, I believe you will need to split the shader as other have stated.
__________________
I sign here?
 
Old 06 June 2013   #7
you can create another UV set (multiple UV's), one specifically for the anisotropic direction that you can rotate the UV's while leaving the others alone
 
Old 06 June 2013   #8
I've attached a scene with a singleSwitch utility used to change the anisotropic rotation per object. The switch was really designed for input textures so just to switch between single values(instead of textures) is less obvious. I created an expression that sets the input values on the switch(see expression1 in expression editor):
singleShadingSwitch1.input[0].inSingle = 0; // anisotropic rot for the 3 connected objects
singleShadingSwitch1.input[1].inSingle = .2;
singleShadingSwitch1.input[2].inSingle = .4;

I think it can also work to do setAttrs on these attributes, but one can more easily see and edit the values, while the attributes are not displayed in the channel box or attribute editor.
 
Old 06 June 2013   #9
Sorry for the delay and thanks for the answers.
I don't know a lot about expressions and nodes in Maya, but I understood a little about Duncan's approach. Next weeks I'm going to deepen my studies about these two things and probably I will completely understand the approach.
sentry66, how would I tell to the material that the second UV Set is to be used for the anisotropic rotation?

Sorry for my newbie questions and thank you all again.
 
Old 06 June 2013   #10
Thread automatically closed

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.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 10:47 AM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.