Texture Processor Tool 纹理处理工具

 

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".

工具可以将图像文件转换成可红移渲染的格式。它可以在渲染过程中自动执行,也可以离线批处理预转换纹理。当你有大量的纹理并且你有一个网络上的共享纹理源文件夹时,预先脱机转换纹理是特别有用的,在这种情况下,自动局部机器纹理转换可能比实际的渲染速度慢!离线工具转换纹理,以便结果与源并排存储,具有相同的名称和扩展替换为”。“ 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:

Exe 的语法很简单:

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:

当在渲染时自动转换纹理时,根据纹理的使用方式将某些信息烤制到转换后的文件中。例如,纹理的颜色空间(例如 sRGB)用于正确计算 mip 映射。当使用 TextureProcessor 手动预转换纹理时,可能需要明确指定使用方法,因为 TextureProcessor 无法确定纹理在场景中的使用方式。以下命令行选项可用于指定用途:

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

L 力线性伽玛(推荐用于浮点纹理)

-s Force sRGB gamma (recommended for integer textures)

- s Force sRGB gamma (推荐用于整数纹理)

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

如果没有指定 gamma 选项,TextureProcessor 将对浮点纹理采用线性 gamma 选项,对整数纹理采用 sRGB gamma 选项

-wx -wy Filter MIP levels with wrapped filtering

- wx-wy 带包裹过滤的过滤 MIP 级别

-p Photometric IES data (for IES profile types)

- p 光度计测量系统数据(适用于测量系统剖面类型)

-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)

基于光的角度地图投影(angularmap Image Based Light)

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

- ocolor Sprite 剪切图不透明度(从颜色强度)

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

- oalpha 精灵剪切图不透明度(从 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:

默认情况下,TextureProcessor 将跳过它确定已经转换的文件(基于源和转换的时间戳、用法等)。.).可以通过指定以下命令行选项禁用此行为:

-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 支持通配符作为其 inputfile 参数。例如,要将目录路径中的所有 tiff 文件转换为纹理,请使用以下命令:

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.

默认情况下,当红移在渲染过程中找到一个预转换的纹理时,它会将其复制到本地纹理缓存文件夹,然后从那里引用它。假设本地纹理缓存文件夹具有比源纹理文件夹更好的 IO 性能,这是很常见的,例如当源纹理存储在较慢的网络驱动器上,或者当源纹理文件夹在固态硬盘驱动器上而源纹理文件夹在机械驱动器上时。在这种情况下,这是一个重要的优化,因为它确保了外核纹理流的最佳性能。在本地纹理缓存文件夹和源纹理文件夹的 IO 性能不同的假设不成立的情况下,这种优化实际上会损害性能。例如,如果纹理缓存文件夹位于较慢的网络驱动器上,或者纹理缓存文件夹和源纹理文件夹位于同一驱动器或性能相同的驱动器上。在这些情况下,可以通过关闭红移渲染选项的 Optimizations 选项卡上的 Copy Pre-Converted Textures to Cache Folder 选项来禁用优化。

2

赶快留个言打破零评论!~

返回顶部

显示

忘记密码?

显示

显示

获取验证码

Close