PDA

View Full Version : Vortex Methods


Mike Truly
06-10-2008, 05:43 PM
If you open the attached MAX2008_32 file, you will see an animated dummy moving across the screen. Linked to the dummy is a spline. Also linked to the dummy are two helix splines which are path deformed to the first spline. The Path Deforms have their rotation animated and the result is a rotating vortex that follows an object. In addition, the first spline acts as a control object of the two vortices splines... this allows me to animate (using either vertex animation or linked XForm animation) this control spline and change the shape of the vortices. All this works fine and gives me the control I need.

I setup a PFlow that uses Speed by Icons and the 2 icons are set to path constraint to the 2 helixes. As long as there is no animation on the control spline, the particles follow the helix paths perfectly. But when the control spline verts are animated (to change the overall shape of the helixes) the particles no longer properly follow the helix paths and drift off in the middle of the paths.

Does anyone know of another method to get this exact control of the vortices but have the particles properly follow the helix paths?

Thanks!

charleyc
06-10-2008, 06:02 PM
There is a fairly simple Box3 method using Gradient Maps to define Speed direction where you can take a Renderable Spline (need a Mesh Select to be used by PF) with a series of nested materials (multi-subobj) with one gradient defining the along length of spline direction and two others defining the rotation around the spline. You need two materials to go continouosly around because the particles will stop where the Gradient white meets the black, so you offset one and continuously swap between the two as the particles go around.

JohnnyRandom
06-10-2008, 06:23 PM
Cool approach Mike:)

I have been beating my head against my desk since we last talked about this.

I have been trying to build a box#3 op (unsuccessfully I might add), using a gradient map but obvisously I missed the fact that you need 3.

Of course Charley says its simple:D

I noticed thinking particles has a tornado in the sample files "TP_OP_Orbit_PathPosition.max"
, mmmnn Orbit ORBIT OORRBIT, what a great operator.

Still fact of the matter box#3 is my only option. So more advil please:)

charleyc
06-10-2008, 06:49 PM
This is a slightly more complex version, but it is specifically made to create a tornado type effect. There is an unexposed value in the Data Op that control the radial pull (think Vortex space warp) that is set to an auto adjustment here. That could be exposed to give user control as well as tied to the the Gradient Map if desired.

To keep continuity at sharper curves along the length, you need to increase the subdivisions (or use a turboSmooth)

Also, as it is now, the Integration Step impacts the degree of accuracy for the orbit meaning that a smaller step results in a tighter orbit (keep in mind of your viewport step is not the same as your render step).

Attached is a 2008 Max file.

Mike Truly
06-10-2008, 06:52 PM
Thanks very much for the ideas guys... greatly appreciated.

I do have PFlow Box3 as well as TP3. (Although I'm no expert with either and am trying to learn more every day with each).

The frustrating thing is that I get very, very close with each method I try but then there's a gotcha that stops me dead. The reason I was asking about this particular method is that I'm sooooo close to making it work with all the control I need, yet it seems I have hit another impossibility.

Thanks to the helpful folks on the TP forum (thanks Goran & Joe!), I do have a working setup using Orbit (as one of many ops) but it currently doesn't have the complete control as in this PFlow setup (particularly the taper/turns of the vortex-controlled by the helix creation stack and the animated vortex overall shape-controlled by the path deform spline). I will be revisting that TP3 setup to see if I can incorporate the spline control portion at least.

Charley, is there any particular example or tutorial that would shed light on that Box3 method? What operator(s) uses the maps to define the force? Oleg has mentioned something similar about using the Data Operator but I don't have any examples about how to set something like this up. I'm pretty green with all things particle but if I find an example or tutorial I will be closer to figuring this out. I'm currently going through Allan McKays DVDs and have been learning a lot... thanks Allan!).

John, at this point Vallium or some particle Prozac would be nice!

Thanks again.

Mike Truly
06-10-2008, 06:56 PM
Charley,

Thanks very much for this example... I will dissect!

Thanks again.

JohnnyRandom
06-10-2008, 07:01 PM
DUDE! That is beautiful! Far more complex than I imagined (although simple I am sure as compared to some of the ops I have seen :) ).

I was attemping to use a point position and closest point by surface. While I could get the particles to travel in the z direction get them to orbit has been beyond my comprehension.

I will have to try an figure out exactly what is going on with the function operators, Thanks Charley:)

Mike Truly
06-10-2008, 11:25 PM
Charley,

Wow... that is impressive. But complex for my level of Data Operator knowledge.

Is there any training available for BOX3 (and Data Operator in particular) anywhere?

John,

Any chance you could upload your Data Operator loft experiment so I could dissect that too.

Thanks again.

charleyc
06-11-2008, 12:50 AM
Here are a few.
http://www.orbaz.com/forum/viewforum.php?f=6

It is fairly straight forward once you learn the 'language' of connecting the nodes. A good way to learn is to do simple things like what you see in these tutorials, playing with the data you have access to. From there find simple mathematical formulas and start recreating those using the SubOps. Once you learn what you have access to and how to reproduce the math formulas necessary, it all starts to fall in place.

JohnnyRandom
06-11-2008, 01:19 AM
It is built in max2009, if that is ok, else it will take a minute to rebuild it 2008 but haven't got access to that machine at the moment.

Mike Truly
06-11-2008, 02:05 AM
Charley,

Thanks very much for those links... I was unaware of those. I will definitely do those tutorials shortly.

John,

Ahhh. I forgot about the version issue. I do have 2009 but haven't installed it yet (and don't really plan to for a while) because changing to a new MAX version is always such a hassle what with updating MAX & plugins across 20 systems in the production pipeline and 2008 is working so well for me at the moment. I'll do those tutorials Charley mentioned and see what I can pick up.

Do any of the CG Academy DVDs cover the BOX3 stuff?

Thanks again.

JohnnyRandom
06-11-2008, 02:41 AM
John,

Ahhh. I forgot about the version issue. I do have 2009 but haven't installed it yet (and don't really plan to for a while) because changing to a new MAX version is always such a hassle what with updating MAX & plugins across 20 systems in the production pipeline and 2008 is working so well for me at the moment. I'll do those tutorials Charley mentioned and see what I can pick up.

Do any of the CG Academy DVDs cover the BOX3 stuff?

Thanks again.

Totally understandable, just testing 2k9 myself and happended to build this there, I rebuild it tomorrow when I get back to my workstation.

Chris Thomas has been talking about doing some Box#3 dvd's for a little while. Been trying to get Charley to do one too :D ;) but as we all know free time is hard to come by. I tell you I'll bounce on those in a second:)

Mike Truly
06-11-2008, 02:50 AM
John,

Yea... I'd definitely buy those immediately if they were available. As well as some TP3 DVDs too!

Thanks again.

CapitanRed
06-11-2008, 02:20 PM
I'd love to see into these files too. Unfortunately I'm in max9 :(

so if anybody has time and motivation to recreate these things for max9, would make me very happy :)
It's a pitty that the things that have no update in newer max can't be opened in older versions.

JohnnyRandom
06-11-2008, 08:01 PM
a max9 version

CapitanRed
06-11-2008, 08:48 PM
awesome!!tnx man :)

Mike Truly
06-11-2008, 09:45 PM
Excellent John. Thanks very much for this... I will examine

Thanks again.

JohnnyRandom
06-12-2008, 03:50 AM
No worries:), it is still pretty rookie, but maybe something useful will come out of it.

PsychoSilence
06-15-2008, 05:13 PM
Thatīs awesome! i wrapping my head around tornados for weeks now (but i dont work on it every day...)

my approach was for an AfterBurn setup. I tried Krakatoa too but couldnt get the nice volume look i was after...probably because my notebook is only core duo :( cant go too crazy on the particle count :( John helped alot here too!!! :love:

for the krak part the neat thing is the PRT loaderīs ability to be modified after caching. so i cached a vertical vortex movement without and fany bending. then loaded it into a prt loader and used a path deform for the typical tornado beding...

im running max9 still too...hurts to see all the nice posted files without being able to open them :(

cheers,
anselm

charleyc
06-15-2008, 09:03 PM
Here is the R9 version of what I posted earlier.

Enjoy :)

Edit: On another note, R9 is now two version back..... :D

JohnnyRandom
06-15-2008, 11:21 PM
Cool method with the PRT loader, going to try that out :D

Polimeno
06-17-2008, 10:45 AM
lol, nice thread......

i wish to learn about PFtool box and TP .........
one of you knows a good links and tutorial to start with both ??

and if is possible,
tell me a method using standard PFLow to get a Vortex.


iīll keep my eyes in here.

---- *EDIT -------

i remember my first Vortex tutorial :

http://www.computerarts.co.uk/tutorials/premium_content/3d__and__animation/assisted_twister

=P
haha....

PsychoSilence
06-17-2008, 02:45 PM
iīm not sure if it is a good idea to start learning two strong particle tools simultaniously...

to get a vortex motion going u need a fore operator and obviously a vortex fore. then add this in the GUI of the fore operator. there are plenty of scene files around. i did some r&d and afer an hour i had about 5-10 max files people posted. search forums...

cheers,
anselm

Mike Truly
07-28-2008, 09:51 PM
OK... after a long hiatus, I'm back in vortex-ville.

I have done the Box3 tutorials that Charley mentioned (and gained a bit of insight from them) and I have examined Charley's tornado example closely. I have reorganized the data flow to make it easier to look at and understand for my meager abilities. I have also renamed some items as well (again... to make it easier to understand). But I'm at that brain-fried point of the day where I feel like I understood more several hours ago than I do now.

The vortex setup is working pretty well (thanks Charley for this example!) but I am trying to grasp all aspects of how it works.

I am currently trying to grasp how the B/W gradient ramps influence where the particles go. I understand how the nearest surface point to the particle location is sampled but do particles always want to go in a particular luminance direction? Like from their current dark position to a lighter position next? Or is there a setting that says which luminance value defines the next direction?

I don't really understand the difference (or need) between the 'Point Color' op and the 3 'Point Color Gradient' ops. I know the point color gradient ops are to sample the gradient and build vectors but I'm not sure why the 'Point Color' is needed to do this?

I understand what Charley was saying about the need for 2 circumference maps to avoid stopping at the seam but I'm having a hard time visualizing how the passing off between the maps makes for infinite travel around the cone.

Any layman's explanation of how some of this stuff works would be very helpful.

Attached is my MAX2008_32 modified version of Charley's file.

Thanks!

charleyc
07-29-2008, 04:07 PM
Thanks for the compliments.

Ok, I will see how many of the questions I can answer.

First off, Point Color returns the point3 color value (normalized, if you will, to 0-1 rather than 0-255). It returns this using a Vector data type (point3)

Point Color Gradient returns a direction vector pointing from dark to light (there is no setting to change this, but you can mathematically change it as needed). This is the data necessary to send the particles around as well as up the funnel.

In order to get a continuous rotation around, there needs to be two maps to gather data from. The first map is used if the Point Color data is within a specified threshold and once exceeded (gets too close to the seam) it is sent to the other map (rotated offset to the first map) with a similar threshold. By switching between the two, the particles are constantly in motion.

So the breakdown

The Point Color subOp gathers the color data from Sub Material2 (MatID2) and sends to the pipe to determine which sub Material is being used. If the value is less than or equal to .5, then it uses sub material 2 and if greater, then sub Material3

The first Point Color Gradient is set to subMaterial2, the second to SubMaterial3, both go into the pipe and are sent as according to the Point Color data

The third Point Color Gradient is using sub Material1 which is the gradient used to send the particles up the funnel.

It is essentially that simple, however there is a scalar multiplier (Circum Multiplier) which determines the Radial Pull (to barrow from the Vortex SW). If this is exposed you can get some pretty cool randomization to the radial path. And it can be mathematically adjusted based on distance from geometry to determine speed and get the more central particles moving faster than the ones further away.

I hope this clears up some things.

Mike Truly
07-29-2008, 05:02 PM
Charley,

Thanks very much for this explanation... greatly appreciated. I will chew on this while I re-examine the flow.

Thanks again.

CGTalk Moderation
07-29-2008, 05:02 PM
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.