Class LumaPipeline
Measure the luma of two Texture2D using the Job System. This is used by the PSNR and SSIM algorithms.
Inherited Members
Namespace: UnityEngine.TestTools.Graphics
Assembly: UnityEngine.TestTools.Graphics.dll
Syntax
public static class LumaPipeline
Methods
Schedule(Texture2D, Texture2D, LumaColorSpaceMode, int, Allocator)
Schedule the job to compare the luma of an actual and expected image. Assumes images are in sRGB (gamma) space.
Declaration
public static LumaPipelineResult Schedule(Texture2D expected, Texture2D actual, LumaColorSpaceMode lumaColorSpaceMode = LumaColorSpaceMode.RejectLinearImages, int batchSize = 1024, Allocator allocator = Allocator.TempJob)
Parameters
| Type | Name | Description |
|---|---|---|
| Texture2D | expected | Expected image |
| Texture2D | actual | Actual image |
| LumaColorSpaceMode | lumaColorSpaceMode | Preferred handling of linear space images |
| int | batchSize | The number of pixels per batch |
| Allocator | allocator | Allocation type for the native arrays used by the job |
Returns
| Type | Description |
|---|---|
| LumaPipelineResult | Results of the pipeline |