Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

HideElements
cssselector#tocVertical, #tocHorizontal

This page provides information on the Phoenix Grid Texture (PhoenixFDTexture).

Overview

...

PhoenixFDTexture can be created from the Hypershade. It The Phoenix Grid Texture loads and exposes a grid channel Grid Channel of a selected Phoenix simulator object Simulator as a procedural texture. Using this component, you which can shade the content in ways that the plain Phoenix shader does not support.The main application of this texture is for shading the meshed of liquids which were simulated using an RGB color grid channel. then be used to shade the simulation wherever colors are needed. It can be created from the Hypershade.

For example, this texture can be plugged into the texture slots of a material as color or opacity, and used to shade the surfaces of liquids or meshes in general, that were exported with an RGB Grid Channel. If you want to mix together liquids, for example, with multiple RGB colors emitted from different Liquid Sources, the Grid Texture can be used to read and transfer the RGB colors to the Liquid mesh's material for shading.

UI Text Box
typeinfo
The technique of mixing colored liquids and rendering their colors is

...

demonstrated in the Paints Quick Setup preset.

The Grid Texture can also be plugged into the Simulator's volumetric options, in order to modulate the opacity of Fire and Smoke, or to color the Fire and Smoke, using any of the simulator’s Grid Channels as a basis (Smoke, Speed, RGB, etc.).

You could also use it as a blending mask, as described in the the Milk & Chocolate tutorial for Phoenix FD.. For example, the Grid Texture can be used to read the RGB color of a simulator, which can then be used as a blending factor between two different materials.

UI Text Box
typenote
Another use of the

...

Grid Texture is for rendering via an external volumetric

...

shader, such as the V-Ray Environment Fog. See the External Volumetric Shader section on the Tips and Tricks page for more information.
UI Text Box
sizemedium
typetip

UI Path:    ||Hypershade|| > Create panel > Maya section > 3D Textures
UI Path:  ||Create Render Node|| > Maya section > 3D Textures

Parameters

...


Image Added

Image Removed

 


Simulator Node | simNode  – Allows you to specify the PhoenixFDSimulator node. 

Channel | channel  – Specifies the channel retrieved from the Phoenix node:

Rendering Fire Color - Returns the resulting color for the Fire, as specified in the Rendering → Fire tab of the Phoenix FD SimulatorPhoenix Simulator.
Rendering Smoke Color - Returns the resulting color for the Smoke, as specified in the Rendering → Smoke tab of the Phoenix FD SimulatorPhoenix Simulator.
Rendering Smoke Opacity - Returns the resulting Smoke Opacity, as specified in the Rendering → Smoke Opacity tab of the Phoenix FD Simulatorthe Phoenix Simulator.
Channel Speed - Returns the contents of the Speed simulation channel. Speed Grid Channel Output has to be enabled on the Phoenix Simulator for this to work.
Channel Velocity - Returns the contents of the Velocity simulation channel. Velocity Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.
Channel RGB - Returns the contents of the RGB simulation channel. RGB Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.
Channel Temperature/Liquid - Returns the contents of the Temperature/Liquid simulation channel. Temper./Liquid Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.
Channel Smoke - Returns the contents of the Smoke simulation channel. Smoke Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.
Channel Fuel - Returns the contents of the Fuel simulation channel. Fuel Grid Channel Output has to be enabled on the Phoenix FD Simulator for this to work
Channel Speed - Returns the contents of the Speed simulation channel. Speed Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.
Channel Viscosity - Returns the contents of the Viscosity simulation channel. Viscosity Grid Channel Output has to be enabled on the Phoenix FD Simulator Phoenix Simulator for this to work.

size
UI Text Box
mediumtypenote

When doing Liquid simulations, Phoenix FD populates the grid Velocity channel only for cells / voxels inside the liquid volume - empty (air) voxels contain no velocity information. To generate velocity information for the empty voxels, enable Simulate Air Effects under the Liquid roll-out Dynamics rollout of the simulator and re-run the simulation.

...

Single – The texture will not be tiled and the region outside the simulator box will be emptyjust black.
Single Clamped – The texture will not be tiled but its edges will be clamped, thus "stretching" the edge pixels.
Wrap – Tiles the texture by repeating it infinitely.
Mirror – Tiles the texture by flipping it back and forth infinitely.

Sampler Type Sampler samplerType – Determines the blending method between adjacent grid cells.

...

Auto Mapping | autoMapping – Allows automatic 3D mapping to the simulator's box, ignoring the place3dTexture node. Note that if the Grid Texture is plugged into a Particle Shader's Color Map slot and Auto Mapping is enabled, Liquid Simulator should also be enabled and connected in the Particle Shader, otherwise the Grid Texture wouldn't know how to get mapped because the Particle Shader has no grid box like the Phoenix Simulator.

Color Scale | outputScaleoutput_scale Sets Multiplies the color output value values of the selected channelGrid Texture.

Color Offset | outputOffset – Offsets the output value of the selected channel.Image Removedoutput_offset – Multiplies the color output values of the Grid Texture. The values are first scaled by Color Scale and then the Color Offset is added.


Image Added


Rescale Grid Channel – Rescales the output values of a Grid Channel to a certain range. The colors you get from the Grid Texture can be meaningful when data that is read from the Simulator is in the 0-1 range. But in case the grid data is negative, the Grid Texture will return black color, or if the data has very large values, like e.g. the Grid Speed which can go up to several hundred, the color returned by the Grid Texture will be pure white. In such cases this data should be rescaled to meaningful color values, which usually means rescaling it to the 0-1 range. You can find out more info about the Phoenix Grid Channel Ranges here.

Rescaling using this helper simply measures the data range of the selected Channel and changes the Color Scale and Color Offset options. If you are familiar with the Phoenix channel ranges, you can directly set the Color Scale and Color Offset to the values you desire.

If you simulate new cache files, or if you load a new cache sequence in the Simulator, you will need to do this rescaling again to make sure the Grid Texture values are still in the Min-Max range. Note that rendering channels such as the Fire Color and Smoke Color/Opacity cannot be rescaled. Rescaling is especially useful when you are reading channels such as Channel Speed or Channel Temperature which can range up to several hundred or a few thousand, and you want to use them as color or opacity. With such channels, you need to a certain rangescale them down between 0-1, which would require you to set a very small Color Scale multiplier - 0.001 or even smaller.

Min – Sets the minimum value you want for the Grid Texture output.
Max – Sets the maximum valuevalue you want for the Grid Texture output.
Rescale to Current Frame – Rescales the channel Grid Channel based on the value in the Channel values only for the current frame. If the Channel changes its range for other timeline frames, the Grid Texture will output values outside the Min-Max range or smaller than that range.
Rescale to Entire Sequence – Rescales the channel based on the values in lowest and highest values of the Channel in the entire cache sequence. Close – Closes the Rescale Grid Channel dialog windowThis will make sure that the values output by the Grid Texture will not exceed Max or go below Min for any frame of the cache sequence.

Skip Displacement | skipDispl – When enabled, the content is sampled without adding Phoenix displacement.

Alpha is the Color's Intensity | alphaIntens – When enabled, the alpha for the texture will be based on the color's intensity. When disabled the alpha will be solid.