User Login | Reseller Access
Products | Plug-ins |Sales |Support |Downloads |News Events Community |Registration
Home » Techniques » Tips & Tutorials » Bitmap based Particles


Bitmap based Particles

(Last Updated: October 29, 2001)


This week, we are going to explore some of the new particle tools in 3.1. In this example we will show how to use a bitmap as a particle, and how to create a nice autumn scene of leaves falling from a tree.

Requirements: Digital Fusion 3.1 or higher, DFX+ With Module 7
Flow:  Download the Flow (85 Kb)
Images:  Download the Images (810 Kb)
Archive:  Archive and printable Microsoft Word Document (1.7 Mb)



First things first, you need to save the above images to your hard drive for this tip.

 

  1. Start off by creating a new flow with a global out at 89. Also set your render ranges 0-89
  2. Add a loader pointing to the "autumn-b.jpg" and also set its ranges to 0-89. (Drag the extend last frame screw to 89.) Make sure it is set to full frames.
  3. Next we add the basis for all particle systems, the particle emitter [pEm], and the particle render tools [pRn]. Connect the output from the [pEm] to the input of the [pRn].
  4. Since we plan on merging the particles over a background, we now need to match the particle render tool to the background of the tree, so open the controls and set the image size to match. 590x817. (This is not always necessary but required in this case.)
  5. Drag the particle render tool's output to the output of the "autumn-b.jpg" loader, and this will create a merge with the particles composited over the tree. Be sure to set the additive slider to 1.

This creates a basic particle flow. We have our footage, with a particle emitter and particle renderer merged over it. Next we will set up the bitmap for our particles. We could do this in a paint application, but what would be the fun in that? So in Fusion do the following to prep an image to become a particle.

 
  1. Set up a loader with the "dfgoldleaf.jpg" and set it's ranges to 0-89. Make sure it is set to full frames
  2. Add a luma keyer and set its lower value to 0.8 Check the invert matte and post multiply image. This will create the alpha of the leaf, as well as remove the unwanted white background.
  3. Next add the new color corrector and set the tint to 0.05, the strength to 0.54, and the master RGB gain to 0.7. This adjusts our leaf to match more closely with the background.



  4. Now add a resize and set it to 64x64 pixels. Remember to generally keep your bitmaps as small as possible to avoid large usage of ram.

Our leaf is now ready to be dropped into the particle emitter, but first we need to set up a few parameters to get the beginnings of a leaf storm in the wind.

 
  1. In the controls for the particle emitter select the controls tab. Here we want to adjust the following settings;
    1. Random seed. Pick a friendly number. It's your choice.
    2. Set the number (of particles per frame) to 2.
    3. Set the number variance to 2.
    4. Open the velocity settings, and set the velocity to 0.05
    5. Set the angle Z to -90. This will make it look like the leaves are moving towards the camera.
    6. Open the rotation settings and ensure that rotation mode is set to absolute.
    7. Set rotation z to 5.
    8. Set rotation z variance to 5.
    9. Set spin z to 15.
    10. Set spin z variance to 15. These settings add some random rotation to the leaves.
  2. Open the style tab, and set the following values.
    1. Style drop down to bitmap
    2. Open the color controls, and then the color variance settings, and change the red variance low to -.2, green low to -.2 and blue low to -.15. This changes the colors of the leaves slightly for each particle.
    3. In the size control settings, set the size to 0.2, and the size variance to 0.3. This will make sure all the leaves are not the same size.
    4. Under the fade control settings set the fade in to 0.05, and the fade out to 0.8. This ensures the leaves don't pop in when they are created, and fade out nicely too.
    5. Finally drag the resize from the end of the leaf "branch" of the flow and drop it into the slot that is labeled "drop tools here." If you advance in the timeline you should now see a few leaves in the middle of the particle render tool.

Ok, so now we have the basics of the type of motion we want the particles to exhibit, as well as the variations set up in the color. We could leave the emitter region set as a sphere, but then we would have one of two problems. Either the tree trunk would be emitting leaves, or the lower branches would not be emitting leaves. To fix this, we will set up a spline based emitter, and we will set up the pre-render settings.

 
  1. View the merge tool, by dragging it into the large view, and if you need to, set the view to fit. In the particle emitter, select the region tab, and set the drop down to bezier. This will enter the click append mode to create a spline. Now trace a spline to match the shape of the tree like so.



  2. To achieve the effect of the shot cutting into the action, we can simulate this by setting a few options in the particle renderer. Check the Automatic Pre-Roll option. Under the controls tab, set the pre-generate frames to 30. This will pre-generate 30 frames, and place the leaves in the tree by frame 0.

If we create a preview here, (Try holding the "alt" key while dragging the merge to the large view. Go ahead, I'll wait….), we notice that the leaves are just expanding from the tree. Not exactly the final product. We need to add a gravity style direction force, a wind style direction force, and finally some turbulence.

 
  1. Make some room between the particle emitter and particle render tools (about room for 4 tools), and drop a particle directional force tool [pDF] on the connection close to the particle emitter. (It should highlight, and insert itself.) Rename this tool to "pDirectionalForce gravity."
    1. Set the strength to 0.05
    2. The default tool settings are acceptable in the other options.
  2. Drop a second [pDF] after the one just added, in between the first and the particle renderer. Rename this one to "pDirectionalForce wind."
  3. Under the wind tool, make the following changes;
    1. Pick a random seed.
    2. Set direction to 0
    3. Right click on the strength slider, and modify it with shake.
    4. In the shake modifier (under the modifier tab just under the small view), set it to be smooth 5, min 0, max 0.05. This will create a random type increase and decrease in the wind strength.
  4. Between the wind and render nodes, insert a turbulence tool, [pTr]. Change the settings to;
    1. Pick a random seed
    2. X strength to 0.2
    3. Y strength to 0.2
    4. Z strength to 0.2
    5. Density to 20
    6. We can leave the conditions and region at their default values.

If we make a preview now, we can see it is coming along nicely. We just have one last touch to add to the particle system, a friction to simulate the ground.

 
  1. Drop a particle friction in between the turbulence and the render tools. Set the following values;
    1. Pick a random seed
    2. Velocity friction to 1
    3. Spin friction to 1
    4. Change to the region tab, and set the region pull down to "when inside region"
    5. Make sure you are viewing the merge 1 tool, then set the region drop down to "bezier." Again, this will enter the click append mode to create a spline. Draw a ground spline similar to this;

This completes the particle branch of the flow. If you create a preview now, you will see more what we were aiming for. The final touch would be to animate the full size image over a background to get a camera pan and add some motion blur.

 
  1. Add a background, and set it to NTSC-D1. Change the process mode to full frames.
  2. Drag the output from the merge containing both the particles and autumn-b.jpg, over the output of the new background tool.
  3. Go to the frame 19.
  4. Highlight the merge 2 tool, and view it on the large view.
  5. Set the size value to 1.25
  6. Add a path to the center by right clicking on the "+" in the view, and select "set key creating path."
  7. Drag the "+" down (use the vertical lines to constrain to just the y axis) so that the top of the foreground image is just outside of frame. A value of about 0.93 is right.
  8. Go to frame 69, and drag the control center (+) up so that the bottom of the frame is just outside of the frame, about 0.07
  9. Enter the spline editor by hitting "F8", select inside the editor, and hit "ctrl+f" to fit the spline into view. (Use "F6" to get back to the flow view, or "F7" to enter the timeline editor.)
  10. Select both points by dragging a box around them.
  11. Type "shift+s" to smooth out the spline. (Alternately use "shift+l" to get a linear spline.)
  12. Open the controls for the prender tool, and enter the radio active tab, and check the motion blur box. The default values are acceptable.
  13. Open the controls for the merge 2 tool, and enter the radio active tab. Check the motion blur box, and set the following;
    1. Quality = 3. This adds an extra sample to the blur.
    2. Shutter angle = 270. This will increase the amount of blur.
So now if you create a preview, you can see the final product. In this example we learned how to use the bitmap particle function, and how to simulate a few natural forces on the particles, like the wind, gravity, and how to stop the particles when they hit the ground. Hopefully this will set you on the path of experimenting with particles in your next project to add a little something extra.

Jason Kolodziejczak
eyeon Software Inc.
      © Copyright 1988-2011 eyeon Software | About Us | Contact Us | Careers | Privacy Policy