Background
class Background extends BaseQualifier
Defines the background color to use instead of transparent background areas or when resizing with padding.
Learn more: Setting background for images | Setting background for videos
Methods
Selects the predominant color while taking only the image border pixels into account.
Selects the predominant color while taking all pixels in the image into account.
Base the gradient fade effect on the predominant colors in the border pixels of the image.
Base the gradient fade effect on the predominant colors in the image.
Sets the background color.
Background constructor.
Applies blurred background (Relevant only for videos).
Applies background color automatically.
Applies generative AI background.
Details
static AutoBackground
border()
Selects the predominant color while taking only the image border pixels into account.
static AutoBackground
predominant()
Selects the predominant color while taking all pixels in the image into account.
static AutoGradientBackground
borderGradient(int|string $gradientColors = null, string $gradientDirection = null)
Base the gradient fade effect on the predominant colors in the border pixels of the image.
static AutoGradientBackground
predominantGradient(int|string $gradientColors = null, string $gradientDirection = null)
Base the gradient fade effect on the predominant colors in the image.
static Background
color(string $color)
Sets the background color.
__construct($color)
Background constructor.
static BlurredBackground
blurred(int $intensity = null, int $brightness = null)
Applies blurred background (Relevant only for videos).
static AutoBackground
auto(string $autoBackground = null)
Applies background color automatically.
static GenerativeFillBackground
generativeFill(string|array $prompt = null, bool $ignoreForeground = null)
Applies generative AI background.