Table of Contents

Class GraphicsCompositorHelper2D

Namespace
Stride.CommunityToolkit.Engine
Assembly
Stride.CommunityToolkit.dll

Provides helper methods for creating and configuring 2D graphics compositors.

public static class GraphicsCompositorHelper2D
Inheritance
GraphicsCompositorHelper2D

Remarks

This class includes methods to create default configurations for graphics compositors, allowing customization of rendering options such as post-processing effects, model effects, and camera settings.

Methods

CreateDefault(bool, string, CameraComponent?, Color4?, RenderGroupMask)

Creates a default GraphicsCompositor configured with specified rendering options.

public static GraphicsCompositor CreateDefault(bool enablePostEffects = false, string modelEffectName = "StrideForwardShadingEffect", CameraComponent? camera = null, Color4? clearColor = null, RenderGroupMask groupMask = RenderGroupMask.All)

Parameters

enablePostEffects bool

If true, post-processing effects such as tone mapping are enabled; otherwise, they are disabled.

modelEffectName string

The name of the effect used for rendering models. Defaults to "StrideForwardShadingEffect".

camera CameraComponent

An optional CameraComponent to be associated with the compositor. If provided, it will be assigned to a camera slot.

clearColor Color4?

The color used to clear the screen. Defaults to CornflowerBlue if not specified.

groupMask RenderGroupMask

Specifies the render group mask to be used for rendering. Defaults to All.

Returns

GraphicsCompositor

A GraphicsCompositor instance configured with the specified options, including render stages and features for opaque and transparent objects.