1. Home
  2. Docs
  3. PopcornFX v2.3
  4. Baking
  5. Resource ovens
  6. Oven: Texture

Oven: Texture

COvenBakeConfig_Texture

Used for texture resources.
Applied to: *.dds, *.png, *.jpg, *.jpeg, *.tga, *.tif, *.tiff, *.pkm, *.pvr, *.exr
 

Property nameDefault valueDescription
All common properties, see COvenBakeConfig_Base
AlsoCopyOriginalFiletrueWhen enabled, will run the command-line, AND copy the original texture to the target path.

 

For example, a config that calls the DirectX utility texconv on windows to convert all files to dds files, and performs a simple copy on linux/mac, but disabling ‘AlsoCopyOriginalFile’ would look like:

COvenBakeConfig_Texture $D734A95F
{
    CommandLine_Windows = "\"%DXSDK_DIR%\\Utilities\\bin\\x86\\texconv.exe\" -o \"$(TargetDir)\" \"$(InputPath)\"";
    CommandLine_Linux = "cp \"$(InputPath)\" \"$(TargetPath)\"";
    CommandLine_MacOsX = "cp \"$(InputPath)\" \"$(TargetPath)\"";
    AlsoCopyOriginalFile = false;
    OverrideDefaultBakeWithCmdline = true;
    AlwaysMkdirTarget = true;
}

Note: the 8 hex digits following the ‘$’ after the object type is a 32-bits UID that must be unique within that file. Any value will work, as long as another object in the same file doesn’t have the same one
 

COvenBakeConfig_TextureAtlas

Used for texture atlas resources.
Applied to: *.pkat
 

Property nameDefault valueDescription
All common properties, see COvenBakeConfig_Base
TrimTexturesfalseIf enabled, will store trimming data
TrimBlendedFramestrueIf enabled, will generate a second set of data generated from a blend of each frame and the next frame. Needed for correct rendering when frame-blending is enabled.
TrimmerVertexCount8Number of trimmed vertices to produce for each frame, or for the whole image if no atlas file exists.
TrimmerThreshold0Texel value [0-255] below which a texel is considered not significant enough and is discarded by the trimmer.
TrimmerOptimizationHybridOptimization mode:

  • Relaxation : very fast, good quality results : Iteratively simplifies the trimmed hull.
  • Bruteforce : very slow, best possible hull : Tries all combinations of simplifications for the target vertex count, keeps the best one.
  • Hybrid : will try to keep running time as low as possible, while outputting the best quality cutouts it can.
TrimmerOptimizationSearchLimit160000Number of possible hull permutations below which the ‘Hybrid’ method should use bruteforce. when the domain space is larger than this number, will switch a monte-carlo sampling algorithm limited to this number of iteration, then also run the relaxation algorithm, and pick the best result.
Higher numbers has more chance to converge to the best result, but require more time to compute.
TrimmerMaskRGBAuint4(255, 255, 255, 255)Color channel mask to be applied when filtering the image texels before trimming.
Still stuck? Contact us
Was this article helpful to you? Yes No

How can we help?