Table of Contents

Class ToneMap

Namespace
Stride.Rendering.Images
Assembly
Stride.Rendering.dll

A tonemap effect.

[DataContract("ToneMap")]
public class ToneMap : ColorTransform
Inheritance
ToneMap
Inherited Members

Constructors

ToneMap()

Initializes a new instance of the ToneMap class.

public ToneMap()

ToneMap(string)

Initializes a new instance of the ToneMap class.

public ToneMap(string toneMapEffect)

Parameters

toneMapEffect string

The tone map shader effect (default is ToneMapEffect).

Exceptions

ArgumentNullException

toneMapEffect

Properties

AdaptationRate

Gets or sets the adaptation rate.

[DataMember(40)]
public float AdaptationRate { get; set; }

Property Value

float

The adaptation rate.

AutoExposure

Gets or sets a value indicating whether the tonemap is calculating the exposure based on the average luminance of the image else Exposure is used.

[DataMember(30)]
public bool AutoExposure { get; set; }

Property Value

bool

true if the tonemap is calculating the exposure based on the average luminance of the image; otherwise, false.

AutoKeyValue

Gets or sets a value indicating whether the tonemap key is automatically calculated based on common perceptive behavior.

[DataMember(15)]
public bool AutoKeyValue { get; set; }

Property Value

bool

true if [automatic key value]; otherwise, false.

Brightness

Gets or sets the brightness.

[DataMember(70)]
public float Brightness { get; set; }

Property Value

float

The brightness.

Contrast

Gets or sets the contrast.

[DataMember(60)]
public float Contrast { get; set; }

Property Value

float

The contrast.

Exposure

Gets or sets the manual exposure value if AutoExposure is false.

[DataMember(32)]
public float Exposure { get; set; }

Property Value

float

The exposure value.

KeyValue

Gets or sets the key value.

[DataMember(20)]
public float KeyValue { get; set; }

Property Value

float

The key value.

LuminanceLocalFactor

Gets or sets the luminance local factor. 0.0: No local influence, only global influence, 1.0: No global influence, Only local influence.

[DataMember(50)]
[DataMemberRange(0, 1, 0.01, 0.1, 2)]
public float LuminanceLocalFactor { get; set; }

Property Value

float

The luminance local factor.

Operator

Gets or sets the operator used for tonemap.

[DataMember(10)]
public ToneMapOperator Operator { get; set; }

Property Value

ToneMapOperator

The operator.

TemporalAdaptation

Gets or sets a value indicating whether to update the luminance progressively based on the current time.

[DataMember(35)]
[Display("Temporal adaptation?", null)]
public bool TemporalAdaptation { get; set; }

Property Value

bool

true the luminance is updated progressively based on the current time; otherwise, false.

UseLocalLuminance

Indicates if the luminance in the neighborhood of a pixel is used in addition to the overall luminance of the input.

[DataMember(45)]
public bool UseLocalLuminance { get; set; }

Property Value

bool

Methods

PrepareParameters(ColorTransformContext, ParameterCollection, string)

Prepare copy operations for parameters.

public override void PrepareParameters(ColorTransformContext context, ParameterCollection parentCollection, string keyRoot)

Parameters

context ColorTransformContext
parentCollection ParameterCollection
keyRoot string

UpdateParameters(ColorTransformContext)

Updates the parameters for this transformation.

public override void UpdateParameters(ColorTransformContext context)

Parameters

context ColorTransformContext

The context.

Remarks

This method is called just before rendering the ColorTransformGroup that is holding this ColorTransformBase