Table Of Contents

Introduction

The 'TextureProcessor.exe' tool converts image files into a Redshift renderable format. It can be executed automatically during rendering, or used off-line to batch pre-convert textures. It is particularly useful to pre-convert textures off-line when you have a lot of them and you have a shared texture source folder over a network, in which caseautomatic local machine texture conversion can be slower than the actual rendering!
The off-line tool converts textures so that the result is stored side-by-side with the source, having the same name and the extension replaced with ".rs***bin".

When pre-converting textures, the converted textured must remain side-by-side with the source texture or it will not be found by Redshift. If Redshift does not find a converted texture side-by-side with a source texture, the source texture will be automatically converted during rendering.

Command Line Options

The syntax for TextureProcessor.exe is simple:

TextureProcessor.exe inputfile [options]


When auto-converting textures at render time, certain information is baked into the converted files based on how the texture is used. For example, the color space of the texture (e.g. sRGB) is used to correctly compute mip maps. When using TextureProcessor to manually pre-convert textures, the usage may need to be specified explicitly since TextureProcessor has no way to determine how the texture is used in your scene. The following command-line options are available to specify usage:


-l Force linear gamma (recommended for floating point textures)

-s Force sRGB gamma (recommended for integer textures)

If no gamma options are specified, TextureProcessor will assume linear gamma for floating point textures and sRGB gamma for integer textures

-wx -wy Filter MIP levels with wrapped filtering

-p Photometric IES data (for IES profile types)

-isphere Image Based Light (sphere projection)

-ihemisphere Image Based Light (hemisphere projection)

-imirrorball Image Based Light (mirrorball projection)

-iangularmap Image Based Light (angular map projection)

-ocolor Sprite Cut-Out Map Opacity (from color intensity)

-oalpha Sprite Cut-Out Map Opacity (from alpha)

By default, TextureProcessor will skip files that it determines have already been converted (based on source and converted time stamps, usage, etc…). This behavior can be disabled by specifying the following command-line option:


-noskip Disable the skipping of textures determined to have already been converted


TextureProcessor supports wildcards for its inputfile argument. For example, to convert all tiff files in the directory path\to\textures, use the following command:

TextureProcessor.exe path\to\textures\*.tiff

Render Time Considerations

By default when Redshift finds a pre-converted texture during rendering, it will copy it into the local texture cache folder and subsequently reference it from there. The assumption is that the local texture cache folder has better IO performance than the source texture folder, which is common for example when source textures are stored on slower network drives or when the local texture cache folder is on an SSD drive while the source texture folder is on a mechanical drive. In such cases, this is an important optimization as it ensures the best performance for out-of-core texture streaming.
In situations where the assumption of differences in IO performance between the local texture cache folder and the source texture folder does not hold, this optimization will actually hurt performance. For example, if the texture cache folder is on a slower network drive or if the texture cache folder and source texture folder are located on the same drive or drives of equal performance. In these cases, the optimization can be disabled by turning OFF the Copy Pre-Converted Textures to Cache Folder option on the Optimizations tab of the Redshift render options.