-
Notifications
You must be signed in to change notification settings - Fork 0
How to use Inferno3D
This document lists all options of Inferno3D and it gives a short tutorial for creating your first spritesheet with Inferno 3D: An explosion.
Tip
The Tutorial will use these green boxes. First, open Inferno3D.
The first thing you will see after launching Inferno3D is the main screen. Here you can configure your fire simulation:
Let's start with what is already there. In the center you can see a running fire simulation. Use the following for navigating the 3D view:
- Mouse Wheel: Zoom
- Middle Mouse + Drag: Rotate the view
- Shit + Middle Mouse + Drag: Shift the view
At the top left of the 3D view there is a menu where you can adjust the 3D view.
- The Preview toggle enables the preview of the rendering camera which shows how your simulation will appear in the spritesheet.
- The Pause toggle pauses the simulation.
- The other options allow you to preview the different render passes.
Tip
Rotate the camera into a position that is comfortable for you.
Around the simulation you can see two white boxes. The bigger one shows the simulation domain - the simulation is limited to this box. The smaller box shows the position and size of the rendering camera, which is used to render the spritesheet.
Important
The rendering camera always looks in the -Z direction! Plan your simulation accordingly!
On the left you can see a list of sources. Sources continuously add smoke and fuel to the simulation. In the sources list, you can:
- add additional sources with the "Add Source" button on the bottom of the source list.
- remove sources by right-clicking into the source list and selecting delete or by pressing the Delete key.
- rename sources by double-clicking their name or using the right-click menu.
- duplicate selected sources with Ctrl+D or using the right click menu.
For now there is only one source in the simulation, named "Source".
Tip
This source should be already selected. If not, click on its name or directly on the source in the 3D view to select it.
With a source selected, you can adjust its properties in the panel on the right:
- The position is the center of the source. You can adjust it using the number fields in the panel or drag the arrows in the 3D view.
- The radius is the size of the source. Smoke and fuel will spawn within this radius.
- The edge property can be used to make the source appear smoother. A lower value means that less smoke and fuel will be spawned close to the edge of the radius.
- The smoke rate is the amount of smoke spawned per time. Sources with a larger radius require a larger smoke rate to achieve the same smoke density.
- Same as smoke rate, but for fuel.
- Explode adds radial velocity outwards for the source, resulting in an explosion-like fireball effect.
- Velocity determines the initial velocity of the fire and smoke. This is added on top of the radial velocity from explode.
- Usually, if a source does not spawn any smoke or fuel (i.e. smoke rate and fuel rate are zero), it will not add any velocity to the simulation. Use Air Vel Factor to add velocity to the empty air. Useful for adding wind which moves smoke from another source.
Note
It is recommended that you use numbers for your source positions that are slightly off. If the source position aligns perfectly with the grid of the simulation, artifacts may occur.
Tip
Move the source up to the center of the domain. Also, offset the x and z coordinates slightly (by around 0.01) to avoid artifacts. Give it some Explode (around 50 should do)
The panel on the left also has a Simulation tab. Use this tab to adjust the parameters of the simulation:
- Resolution of the simulation. Higher resolution means more detail, but also higher computational cost. Since the camera is looking in z-direction you can try to reduce the z-resolution without impacting visual quality as long as you are not cutting off your simulation.
- Cell size is the size of one "pixel" of the simulation. The entire simulation has a size of
Resolution * Cell Size
- Jacobi Iterations: How many diffusion iterations the simulation runs per frame. Higher values lead to better looking results at the cost of performance.
- Delta Time: the length of one simulation time step. Higher values lead to faster moving smoke but decreased simulation accuracy.
- Dissipation: How quickly smoke dissipates. A value of zero means smoke disappears instantly, a value of one means smoke never disappears.
- Vorticity: Higher values introduce additional turbulence to the simulation.
- Burn Rate: How quickly fuel burns. A value of one means fuel combusts instantly.
- Smoke Rate: How much smoke is created during combustion.
- Burn Temp: Temperature of the burning fuel. Affects buoyancy and color of the flame.
- Cool Rate: How quickly the temperature drops outside flames.
- Buoyancy: How much higher-temperature air is pulled upwards.
- Up Vector: Which way is up for buoyancy. Since you cannot rotate the camera, use this instead.
Tip
Our explosion is escaping to the top, so set buoyancy to 0.
The Rendering tab on the right allows you to set options for the spritesheet generation as well as how the fire and smoke looks:
-
Resolution: resolution of one frame of the spritesheet. Do not confuse this with the simulation resolution.
-
Camera Offset: moves the camera for rendering the spritesheet relative to the simulation.
-
Camera scale: scales the camera for rendering the spritesheet
-
Smoke Color: Albedo Color of the smoke.
-
Scatter Factor: How much the smoke scatters light.
-
Emission: How much flames and glowing smoke emit light.
-
Emission Gradient Adjustment: This is gradient from 0°C to 10000°C defines the color of flames. It is a standard blackbody radiation gradient by default.
-
Light Direction: Direction of the light illuminating the smoke.
-
Light: Color and intensity of the light illuminating the smoke. Use the "Raw" mode of the color picker to make the light intensity go above one.
-
Ambient Light: Color and intensity of ambient light.
-
Normal Strength: Strength of the normal map of the spritesheet.
-
Normal Smoothness: Higher values smooth the normal map of the spritesheet.
-
Velocity Strength: Strength of the velocity/flow map of the spritesheet.
Tip
In the emission gradient, select the red point (the third one) and make its color slightly more orange for a more firey look. Depending on how much you changed the color, you may also want to adjust the orange point on the gradient (the forth one).
Inferno3D supports simple animations of properties of both sources and the simulation and rendering parameters. Currently, there is only linear interpolation between the keyframes.
At the bottom of the screen you can see the timeline.
- Use the Mouse Wheel to zoom
At the top of the timeline there is
- A play/pause button which will play/pause the animations (NOT the simulation).
- A stop button which stops the animation and returns the animations back to the start.
- A dropdown menu for selecting an animation. Selecting an animation here will show the keyframes in the timeline.
To the left you can adjust Warmup and Length.
- Warmup is the amount of frames simulated before rendering starts. These frames will not appear in the final spritesheet. They have negative numbers in the timeline.
- Length the length of the animation timeline. This just affects how long animations can be (the simulation runs indefinitely).
Parameters which can be animated have a small diamond symbol next to them.
- If the diamond is gray, the property is not animated.
- If the diamond is orange, your timeline cursor is at a keyframe for this property.
- If the diamond is white, your timeline cursor is NOT at a keyframe for this property, but the property is animated (keyframes exist).
If the diamond is gray or white, click it to create a keyframe at the position of your timeline cursor.
If the diamond is orange, click it again to remove the keyframe.
If you want to adjust the keyframed value, go to the keyframe in the timeline and then adjust the property.
If you want to move the keyframe to another frame, click and drag it in the timeline.
Tip
Time to animate the explosion!
- Go to frame -1 in the timeline.
- Select your source, go to its properties and create a keyframe for the Fuel Rate.
- Go to frame 15 and add another Fuel Rate keyframe.
- Go to frame 16, adjust set the Fuel Rate to 0 and add a keyframe.
- Go to frame -2, set the Fuel Rate to 0 and add a keyframe.
Note
The reason for using frame -1 as start is that otherwise frame 0 would be empty (no fire or smoke). Frame 0 is always the first frame in the spritesheet, so that would be a waste of space.
At the top of the window you can switch to the spritesheet screen. Here you can render and export your spritesheets.
On the left you can adjust how many rows and columns your sprite sheet has. Usually, you would not render every simulation frame to the sprite sheet. With the Skip Frame setting, you can control how many simulation frames are skipped.
When you are ready, press the Render button. You will see the spritesheet getting filled. Once it is done, you can view the different images created by using the dropdown menu at the top. If you are satisfied with your result, press the Export button to export the images as png.
Note
The file name you give will be extended for the different images: filename_combined.png
for the combined render, filename_albedo.png
for the albedo image etc.
Tip
Render your explosion! You may want to set the Skip Frames to something like 15, to capture more of the smoke dissipating. If you like it, save it with the export button!