varying primitive scale according to point number?

   9153   6   1
User Avatar
Member
245 posts
Joined: Sept. 2008
Offline
Hi,

I was wondering if I had a line with several points on it and I creeped a grid onto that line, how would I change the scaling of the primitives of the grid according to the point numbers of the line. I have been thinking about a stamp function but haven't got it to work. In essence I would like to create an undulating surface that changes according to $PT from the line sop (given that I have created the $PT attribute using attribcreate). This will enable me to modify the $PT information in CHOPs and assign noise and other variations to the mix to vary the undulation. Any ideas? (It seems really simple but I couldn't get it to work as I stated above).

Sincerely,
markerline
User Avatar
Member
519 posts
Joined:
Offline
Is this what you are after?

Cheers,
Hans

Attachments:
scale_by_point.hip (46.3 KB)

User Avatar
Member
245 posts
Joined: Sept. 2008
Offline
Yes, that seems to be right–the point expression. Of course! Now, I anticipate that I can vary the undulation instead of making it steadily increase I can have it be different values in random succession or even the same value at two or more different points? Introducing a sort sop would give me variation, but what about making two or more points have the same value? (I can see that if I clamp the results I could simulate that but it would only apply to maximum or minimum values).
User Avatar
Member
245 posts
Joined: Sept. 2008
Offline
The sort sop didn't work but rand($PT)*5 in the attribcreate sop did work, but still no beans on the repetition of similar values
User Avatar
Member
8595 posts
Joined: July 2007
Offline
you can change size directly in sweep SOP

to vary size attribute you can for example use ramp VOP as in example

or instead of random you can use noise() expression or vop

Attachments:
scale_by_point_mod.hip (55.2 KB)

Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
245 posts
Joined: Sept. 2008
Offline
That's a nice solution temte. I have shyed away from Vex up until this point. I've seen a tut by Peter Quint on procedural shaders and it was very involved. It made sense, but not enough for me to do it on my own. I guess I will have to force myself to learn the methodology. Vex is very powerful. Thanks for pointing it out to me.

Sincerely,
markerline
User Avatar
Member
106 posts
Joined: March 2009
Offline
repetition in the rand expression are most likely caused by inputing integer vales into it. Try somehting like rand($PT + 0.1) instead…
Georg Kaltenbrunner - fx lead DDVC
  • Quick Links