Hi everybody,
Here comes an other question…
I have got 2 boxes, the first one has got 7 in Y size and the second one 3 . I'm applying a brick pattern on these objects . How can my shader “read” those Y sizes so it can, according to that value, create a brick pattern 10 times smaller than that Y size. So, depending on which objects it's applied on, the pattern will have different sizes …
I'm not sure if I have to do that in VEXbuilder or elsewhere …
Thanks again in advance
Julien
Little shader question
3671 2 1- Undertaker
- Member
- 113 posts
- Joined: July 2005
- Offline
- aracid
- Member
- 154 posts
- Joined: July 2005
- Offline
i would have the same size of the brick or box to start off with, or if its not a standard object then match it with a a transformation sop accordingly.
ie, get both objects scaled to the same size, then apply your transformation sop, to scale to your needs, then uvtexture sop that uses the inverse of the scale info from ur transform sop.
ie.
copy the parameters from ur transform scalex, and paste using relative refs in the uvtexture size parameters, and have 1 divided by that
ie 1/ ch (“obj/box/xtramsform/sx”) *10
its keeps it relative to the scale of the object
hope this works
aracid
ie, get both objects scaled to the same size, then apply your transformation sop, to scale to your needs, then uvtexture sop that uses the inverse of the scale info from ur transform sop.
ie.
copy the parameters from ur transform scalex, and paste using relative refs in the uvtexture size parameters, and have 1 divided by that
ie 1/ ch (“obj/box/xtramsform/sx”) *10
its keeps it relative to the scale of the object
hope this works
aracid
- Undertaker
- Member
- 113 posts
- Joined: July 2005
- Offline
-
- Quick Links