| Previous Topic (None) | Up (Contents) | Next Topic (Saving Particle Files Tutorial) |
Basic Particle Rendering Tutorial
In this first tutorial, we will build a simple particle system that will be used to explore many fundamental components of Krakatoa.
Sample Scene
You can build the demo file from scratch or download the zipped max file here: KrakatoaBasicDemoFile.zip
Quick Render Test
Let’s get right into what Krakatoa does best – quickly rendering particles.
Rendering a representative frame:
- In the Time Configuration dialog, verify that the Real Time checkbox is unchecked.
- Click Play and watch the teapot disintegrate into smoke.
- Go to frame 50, which we will use as our test frame.
- Open the Render Dialog, verify that the Production renderer is set to Krakatoa (as described in Configuring the Renderer) and click OPEN KRAKATOA GUI.
Alternatively, if you have installed the Krakatoa MacroScripts as explained in the topic Krakatoa MacroScripts, simply click the Krakatoa GUI icon. If the current renderer is not Krakatoa, you will be prompted about switching to it - answer Yes. If Krakatoa is already the current renderer, the GUI will open immediately. - Check >Override Particle Colors - this will force all particles in the scene to render in the custom particle color which by default is white. If you do not check this option, your particles will render in the display color assigned in the Particle Flow system.
- Check >USE LIGHTING which is unchecked by default - this will enable the lighting and shadow casting. If you do not check this option, your particles will render as self-illuminated, ignoring all scene lights. Krakatoa does NOT support the default lights of 3ds Max.
- Leaving the other settings to their defaults, click the large RENDER button in the Krakatoa GUI. Krakatoa will request Particle Flow to update the particle system, and will then render the frame.
The rendered result is far from impressive, but it provides what we are looking for at this stage – a quick preview of the contour of our particle cloud. At this low particle count and default render setting, you can begin to make out curves and swirls in the cloud. Viewport playback is very fast, so you can easily preview the general motion of the particle system.
Increasing Detail
We have achieved a shape of sufficient visual interest for our test renderings, but the particle count is so low that it is difficult to make out any detail. At this point, you will increase the number of particles.
- Select the PF Source 01 event in Particle View and change the Quantity Multiplier > Viewport % to 1.0 - this will make sure only 1% of all particles will be displayed in the viewport.
- In Particle View, select the Birth 01 operator and set Amount to 100000. This increases our particle count by twenty times, but the viewport will display only 1% (1000 particles), keeping the redraws fast.
- In the Krakatoa GUI > Main Controls rollout, click RENDER.
The Particle Flow will have to update all particles up to frame 50 again - you can see the progress in the status line as usual. After that, Krakatoa will acquire the new particles and render them.
There are now sufficient particles to show more detail and show self-shadowing within the cloud.
Quickly Changing the Rendered Look
When you render a frame in Krakatoa, Particle Flow will temporarily cache the particles and save you the time of computing the particle system for subsequent renders. Of course, if you change Particle Flow settings, or switch to another frame, Krakatoa will need to request the actualized particles and Particle Flow will count up again.
(Note: There are more advanced methods of caching to memory and disk that will be discussed in later sections.)
You can quickly change the look of the test frame by altering some Krakatoa settings and rendering again from the cached particle data:
- In the Main Controls rollout, in the Particle Color Controls area, change the color of the Custom Color swatch to an electric blue hue, approx. R:0 G:128 B:255. Click RENDER to see your particles in their new blue color. Notice that Particle Flow did not recalculate particle positions. Krakatoa used cached data from Particle Flow to speed up rendering time.
- In the Density Controls area, change the Density Exponent from –1 to –2. This will reduce the rendered density of each particle by an order of magnitude. Again, RENDER shows the results of your changes almost immediately.
- To obtain a different look, turn off the self-shadowing caused by scene lighting. Click the >Use Lighting button to turn it off and click QUICK RENDER to see the change.
- To complete this exercise, let’s try yet another style of rendering. In the Density Controls area, change Volumetric Density to Additive Density.
- Change the Density Per Particle from 5 to 15 to slightly increase the density of the cloud.
- Click RENDER to see your results..
In summary, Krakatoa can use cached particles from Particle Flow to allow for fast rendering adjustments or even changes in the point of view, preventing the time-consuming recalculation of your particle system. In a few quick minutes, we were able to produce swirls of silt, wispy smoke and tendrils of plasma energy – all without waiting for Particle Flow to repeatedly update. Krakatoa also provides a user-controlled manual caching system for lighting and particles from any source which we shall explore later.
Krakatoa can produce dramatically different looks rendering with Volumetric Density or Additive Density, and can quickly provide variations in particle density. Multiple options are available for color assignment and density modification. You can choose to have Krakatoa use scene lighting to produce particle self-shadowing.
Additional Refinements
So far in this tutorial, we have been able to quickly preview our particle system and several possible looks for the rendered result. To finish this example, we will further increase the volume of particles, and also demonstrate the use of matte objects, which are essential to compositing the finished Krakatoa result into your other rendered layers.
Let’s go for a silty swirl, using scene lighting and volumetric density:
- In our sample scene, raise the particle count ten times higher, to 1,000,000. To do this, in Particle View, select the Birth 01 operator. Enter 1000000 in the Amount field. Particle Flow recalculates the particle system.
- In Krakatoa, turn on >Use Lighting and select Volumetric Density again.
- In Particle View, select the PF Source 01 emitter and in the System Management rollout, take a look at the Particle Amount: Upper Limit. Users familiar with Particle Flow will notice that the setting has been adjusted automatically from the system defaults.
By default, 3ds Max creates all Particle Flow systems with a Limit of only 100,000 particles. However, since we opened the Krakatoa GUI after the creation of the Particle Flow, Krakatoa has automatically increased this value to a much higher value of 100 million. (Despite the internal value being set to 100 million, the spinner will show only 10 million. This spinner was hard-coded by 3ds Max developers to show only numbers up to 10 million, presumably because they never anticipated Krakatoa coming along to blow the lid off particle volumes!)
Note: Most 32-bit systems will have sufficient RAM to render 10 million and more particles. A 64-bit machine with 4GB of RAM can handle about 60 million particles, and there is nearly no practical limit to the amount of RAM you can install.
- Upon pressing RENDER, you will need to wait for Particle Flow to update. It will take noticeably longer than previous updates.
- Observe the results. Our cloud now has a high level of detail, but is unrealistically dense. The particles have an unnatural graininess.
- Change the Density Per Particle back to 5 and the Density Exponent to –3.
- RENDER again to see the results. (This time, the Particle Flow has the particle data ready and does not have to recalculate one million particles up to frame 50, instead of waiting minutes the rendering should be finished in a few seconds!)
- Continue to experiment with Density settings and Custom Color to produce a sandy-colored underwater silt swirl.

Note on Density settings: Density Per Particle and Density Exponent work together to create a simple editing mechanism for particle density. The Density Exponent provides a quick method to dial in density adjustments in powers of 10 and simplifies entry of very large or very small values. In our example, a Density Per Particle of 5 and a Density Exponent of –3 equate to an overall setting of 5 x 10-3 or 0.005.
In this exercise, you have continued to refine the results by making adjustments to particle counts, density settings and color. Upcoming tutorials will show you how to save particles to disk, introduce you to Krakatoa's compositing features, and enable you to maximize particle counts with particle partitioning.