ToneMap Class
Namespace: Stride.Rendering.ImagesAssembly: Stride.Rendering.dll
A tonemap effect.
[DataContract("ToneMap")]
public class ToneMap : ColorTransform
Name | Description | |
---|---|---|
Constructors | ||
ToneMap() | Initializes a new instance of the ToneMap class. |
|
ToneMap(String) | Initializes a new instance of the ToneMap class. |
|
Properties | ||
AdaptationRate | Gets or sets 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. |
|
AutoKeyValue | Gets or sets a value indicating whether the tonemap key is automatically calculated based on common perceptive behavior. |
|
Brightness | Gets or sets the brightness. |
|
Contrast | Gets or sets the contrast. |
|
Exposure | Gets or sets the manual exposure value if AutoExposure is |
|
KeyValue | Gets or sets 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. |
|
Operator | Gets or sets the operator used for tonemap. |
|
TemporalAdaptation | Gets or sets a value indicating whether to update the luminance progressively based on the current time. |
|
UseLocalLuminance | Indicates if the luminance in the neighborhood of a pixel is used in addition to the overall luminance of the input. |
|
Methods | ||
PrepareParameters(ColorTransformContext, ParameterCollection, String) | ||
UpdateParameters(ColorTransformContext) |
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
Type | Name | Description |
---|---|---|
System.String | toneMapEffect | The tone map shader effect (default is |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | toneMapEffect |
Properties
AdaptationRate
Gets or sets the adaptation rate.
[DataMember(40)]
public float AdaptationRate { get; set; }
Property Value
Type | Description |
---|---|
System.Single | 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
Type | Description |
---|---|
System.Boolean |
|
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
Type | Description |
---|---|
System.Boolean |
|
Brightness
Gets or sets the brightness.
[DataMember(70)]
public float Brightness { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The brightness. |
Contrast
Gets or sets the contrast.
[DataMember(60)]
public float Contrast { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The contrast. |
Exposure
Gets or sets the manual exposure value if AutoExposure is false
.
[DataMember(32)]
public float Exposure { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The exposure value. |
KeyValue
Gets or sets the key value.
[DataMember(20)]
public float KeyValue { get; set; }
Property Value
Type | Description |
---|---|
System.Single | 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
Type | Description |
---|---|
System.Single | The luminance local factor. |
Operator
Gets or sets the operator used for tonemap.
[DataMember(10)]
public ToneMapOperator Operator { get; set; }
Property Value
Type | Description |
---|---|
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
Type | Description |
---|---|
System.Boolean |
|
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
Type | Description |
---|---|
System.Boolean |
Methods
PrepareParameters(ColorTransformContext, ParameterCollection, String)
public override void PrepareParameters(ColorTransformContext context, ParameterCollection parentCollection, string keyRoot)
Parameters
Type | Name | Description |
---|---|---|
ColorTransformContext | context | |
ParameterCollection | parentCollection | |
System.String | keyRoot |
Overrides
UpdateParameters(ColorTransformContext)
public override void UpdateParameters(ColorTransformContext context)
Parameters
Type | Name | Description |
---|---|---|
ColorTransformContext | context |