FMaterialBakingHelpers::PerformUVBorderSmearAndShrink

Applies a box blur to magenta pixels found in given texture represented by InOutPixels using non-background pixels, this creates a smear across the magenta/filled pixels.

Unreal Engine C++ API Reference > Developer > MaterialBaking > FMaterialBakingHelpers

References

   
Module MaterialBaking
Header /Engine/Source/Developer/MaterialBaking/Public/MaterialBakingHelpers.h
Include #include "MaterialBakingHelpers.h"
Source /Engine/Source/Developer/MaterialBaking/Private/MaterialBakingHelpers.cpp
static void PerformUVBorderSmearAndShrink
(
    [TArray](API\Runtime\Core\Containers\TArray)< [FColor](API\Runtime\Core\Math\FColor) > & InOutPixels,
    int32 & InOutImageWidth,
    int32 & InOutImageHeight,
    [FColor](API\Runtime\Core\Math\FColor) BackgroundColor
)

Remarks

Applies a box blur to magenta pixels found in given texture represented by InOutPixels using non-background pixels, this creates a smear across the magenta/filled pixels.

This version is allowed to shrink the array to a single pixel if the entire output is monochrome. Params will be adjusted accordingly when this occurs.

Parameters

Name Description
InOutPixels The image to apply the smear to
InOutImageWidth The width of the image in pixels
InOutImageHeight The height of the image in pixels
BackgroundColor The pixel color considered background in the image, and that can be smeared into

Ask questions and help your peers Developer Forums

Write your own tutorials or read those from others Learning Library