Jump to content
  • 0
Jason

Maya - What's the best way to handle file rotation and scaling

Question

I'd like to see if anyone knows how to scale a UV texture before rotating it..

I currently have a setup that looks something like:

image.png

And I'm using the place2dTexture node to position the little vertical rectangle right where I want it:

image.png

I've got 2 challenges..

1 - I'd like to scale the texture with something more interesting than using the coverage and translate frame values, because right now you have to counter-animate both in order to scale the image.  I'd much rather just scale the darn image!

2dTextureScale.gif

2 - Because rotating the image requires adjusting the RotateUV parameter, the "scale" happens in UV space.. just up and down.

I'd really like to figure out how to make the scale work before the rotation is applied.. not seemingly after, like you see here.

2dTextureRotate.gif

 

I was hoping there was some node I could insert after the image to scale it.. or before the place 2d texture node or something.. anyone have any ideas?

 

Share this post


Link to post
Share on other sites

6 answers to this question

Recommended Posts

  • 0
On 7/19/2018 at 10:52 AM, Mark Therrell said:

Its been awhile on this one..

im just now reading it... any luck so far?

if not,  id be happy to take a crack at.

 

cheers.

 

Hey mark!

Not really - if you had time to look at it, that'd be great! ?

Share this post


Link to post
Share on other sites
  • 0

There are likley several ways to do this. but as i am beginning to explore,  this was the first and most expedient method for more intuitively transforming the image.. vs trying to manipulate the uvs or use place2dTexture:

use a place3DTexture node feeding a projection:

806703085_ScreenShot2018-07-24at2_58_49PM.png.76ae1f531309f10a9b6ed7f6f75f7795.png

 

the left plane is just a normal place2dTexture similar to what you have:

116002965_ScreenShot2018-07-24at2_59_22PM.png.059fcaacf362339258fb6ebfeefee144.png

on the right is the same result, but the image is being projected, note the lower res hardware render. (this is not permanent and i think there is asetting somewhere to hardware render it in higher res).

you can translate rotate and scale the placement of the image in a more intuiitive way, then you can use "Convert To File Texture" to bake the projection into the uvs of the plane.:

32669869_ScreenShot2018-07-24at3_00_07PM.png.34d1693b9a545bd30024fbb8a0fbcd26.png1905093529_ScreenShot2018-07-24at3_00_30PM.png.f9f7a9816f20d18d5e12339d6f43ff34.png

you will want to select the surface and the material and in the hypershade Edit menu:  1981267307_ScreenShot2018-07-24at3_01_12PM.png.efc85a561d72062030ae169fe3a11930.png453057323_ScreenShot2018-07-24at3_01_35PM.png.6654c06da99eaf782f018c71dec9078a.png

Of course you may want to use a layerd texture.. and / or  maybe define an alpha so its more like a label, and so that the background can stay the same color without showing the edges of the image.. any of that stuff is possible.

This specific projection process can also be made a little more prcedural and user friendly with a bit of rigging/scripting.

if you want the demo file, let me know... and as i think more about it there may be other ways to do this as well.. this was just the fastest out of the box version that came to mind first.

 

Edited by Mark Therrell
refinement

Share this post


Link to post
Share on other sites
  • 0

As another fairly simple alternative (but maybe requiring  a little knowledge of writing expressions for transforms).... you could write a "not-to-difficult" expression that would control the "Coverage", "Translate Frame" and "Rotate Frame" inputs to the 2d texture placement node.  Via  inputs to this expression  you could have the intuitive effect of scaling translating and rotating the 2d texture as you are hoping for. It would require the additional input of a uv coordinate for the "uv--space-pivot" that represents the more intuitive "pivot" that you may be thinking of scaling and rotating around. With this approach  the transforms could be created for the mentioned 2d placement attrs through this "controller" node via inputs that were processed by the expression. (this could acutally be pretty elegant but you'd have to allow some time to come up with the expression!).. the proection method above is more pragmatic.

Edited by Mark Therrell

Share this post


Link to post
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.

Guest
Answer this question...

×   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...