Show / Hide Table of Contents

Interface IStages

Render Stage Operations Creation, configuration and destruction of render stages and viewports

Namespace: Yak2D
Assembly: Yak2D.Api.dll
Syntax
public interface IStages

Properties

CountRenderStages

Returns the number of user created render stages currently managed by the framework

Declaration
int CountRenderStages { get; }
Property Value
Type Description
System.Int32

CountViewports

Returns the number of user created viewports currently managed by the framework

Declaration
int CountViewports { get; }
Property Value
Type Description
System.Int32

Methods

CreateBloomStage(UInt32, UInt32)

A RenderStage that can apply a bloom effect to a texture source and render to a target Brightness threshold, additive mix amount with source and number of blur component samples can be configured for the stage The source texture is downsampled and threhold clipped onto a smaller surface before being blurred and re-mixed with the original

Declaration
IBloomStage CreateBloomStage(uint sampleSurfaceWidth, uint sampleSurfaceHeight)
Parameters
Type Name Description
System.UInt32 sampleSurfaceWidth

The width of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

System.UInt32 sampleSurfaceHeight

The height of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

Returns
Type Description
IBloomStage

CreateBlur1DStage(UInt32, UInt32)

A RenderStage that applies a directional (1d) blur effect to a texture source and render to a target For non-directional blur, use the standard Blur effect instead Blur direction, fractional mix amount with source and number of blur component samples can be configured for the stage

Declaration
IBlur1DStage CreateBlur1DStage(uint sampleSurfaceWidth, uint sampleSurfaceHeight)
Parameters
Type Name Description
System.UInt32 sampleSurfaceWidth

The width of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

System.UInt32 sampleSurfaceHeight

The height of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

Returns
Type Description
IBlur1DStage

CreateBlurStage(UInt32, UInt32)

A RenderStage that applies a blur effect to a texture source and render to a target The blur is applied in both x and y texture coordinate directions, it is not a directional blur - use Blur1D effect instead in that scenario Fractional mix amount with source and number of blur component samples can be configured for the stage

Declaration
IBlurStage CreateBlurStage(uint sampleSurfaceWidth, uint sampleSurfaceHeight)
Parameters
Type Name Description
System.UInt32 sampleSurfaceWidth

The width of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

System.UInt32 sampleSurfaceHeight

The height of the downsampling texture used. Smaller == less computationally intensive, lower quality bloom, but larger blur distance per sample

Returns
Type Description
IBlurStage

CreateColourEffectsStage()

Provides simple colour modification effects to a texture source and render to a target Effects are: single colour mix, grayscale, negative, colourise and opacity A combination of all the effects can be applied together

Declaration
IColourEffectsStage CreateColourEffectsStage()
Returns
Type Description
IColourEffectsStage

CreateCustomShaderStage(String, AssetSourceEnum, ShaderUniformDescription[], BlendState, Boolean)

Creates a stage for a user defined shader effect The user defines the shader code, constrained by a set maximum number of texture and uniform configuration variable inputs

Declaration
ICustomShaderStage CreateCustomShaderStage(string fragmentShaderPathName, AssetSourceEnum assetType, ShaderUniformDescription[] uniformDescriptions, BlendState blendState, bool useSpirvCompile = false)
Parameters
Type Name Description
System.String fragmentShaderPathName

Shader code filename (no extension) including path"

AssetSourceEnum assetType

Embedded in the binary or a file location"

ShaderUniformDescription[] uniformDescriptions

Description of shader uniforms (textures or data structs)

BlendState blendState

How source pixels are mixed with destination pixels on surfaces

System.Boolean useSpirvCompile

Compile shader code at runtime from .glsl SPIRV shader

Returns
Type Description
ICustomShaderStage

CreateCustomVeldridStage(CustomVeldridBase)

Create a stage for a user defined custom piece of veldrid logic, enabling operations or integrations that require complete access to veldrid library functions

Declaration
ICustomVeldridStage CreateCustomVeldridStage(CustomVeldridBase customVeldridBase)
Parameters
Type Name Description
CustomVeldridBase customVeldridBase

User's custom render stage code must inherrit from this base class

Returns
Type Description
ICustomVeldridStage

CreateDistortionStage(UInt32, UInt32, Boolean)

A RenderStage that applies a distortion effect to a texture source and render to a target The per-pixel distortion amount is generated from a distortion height map The distortion height map is drawn each frame, in a similar way that DrawStage draw requests are generated, queued and sorted The final distortion amount per-pixel is scaled by a configurable scalar quantity

Declaration
IDistortionStage CreateDistortionStage(uint internalSurfaceWidth, uint internalSurfaceHeight, bool clearDynamicRequestQueueEachFrame)
Parameters
Type Name Description
System.UInt32 internalSurfaceWidth

The width of the internal textures used for generating the height and gradient maps. Smaller == less computationally intensive, lower quality distortion

System.UInt32 internalSurfaceHeight

The height of the internal textures used for generating the height and gradient maps. Smaller == less computationally intensive, lower quality distortion

System.Boolean clearDynamicRequestQueueEachFrame

Set to automatically remove (clear) draw requests from the stage's queue following each draw iteration. Stops the user being required to remember to clear the queues at the start of each draw update. A useful default as this can regularly catch users (me...) out, resulting in ever increasing draw queue sizes :)

Returns
Type Description
IDistortionStage

CreateDrawStage(Boolean, BlendState)

Draw Queues are used to collect, sort and process 2d drawing requests

Declaration
IDrawStage CreateDrawStage(bool clearDynamicRequestQueueEachFrame = true, BlendState blendState = BlendState.Alpha)
Parameters
Type Name Description
System.Boolean clearDynamicRequestQueueEachFrame

Set to automatically remove (clear) draw requests from the stage's queue following each draw iteration. Stops the user being required to remember to clear the queues at the start of each draw update. A useful default as this can regularly catch users (me...) out, resulting in ever increasing draw queue sizes :)

BlendState blendState

How source pixels are mixed with destination pixels on surfaces

Returns
Type Description
IDrawStage

CreateMeshRenderStage()

A RenderStage that will render a 3D Textured Mesh Ambient, Directional and Spotlights can be configured for the stage, along with the Mesh to render

Declaration
IMeshRenderStage CreateMeshRenderStage()
Returns
Type Description
IMeshRenderStage

CreateMixStage()

A RenderStage that enables the mixing of up to four textures together The general mix factors per texture are defined in the configuration A further 'per-pixel' mixing scalar can be defined using mixTexture

Declaration
IMixStage CreateMixStage()
Returns
Type Description
IMixStage

CreateStyleEffectsStage()

A RenderStage that applies stylised effects to a texture source and render to a target Effects are: Pixellate, Edge Detection, Static Noise, Cathode Ray Tube and Old Movie Reel, A combination of all the effects can be applied together

Declaration
IStyleEffectsStage CreateStyleEffectsStage()
Returns
Type Description
IStyleEffectsStage

CreateSurfaceCopyDataStage(UInt32, UInt32, Action<TextureData>, Boolean)

Declaration
ISurfaceCopyStage CreateSurfaceCopyDataStage(uint initialStagingTextureWidth, uint initialStagingTextureHeight, Action<TextureData> callback, bool useFloat32PixelFormat = false)
Parameters
Type Name Description
System.UInt32 initialStagingTextureWidth
System.UInt32 initialStagingTextureHeight
Action<TextureData> callback
System.Boolean useFloat32PixelFormat
Returns
Type Description
ISurfaceCopyStage

CreateViewport(UInt32, UInt32, UInt32, UInt32)

A viewport defines an area of a render surface used as a drawing area The topleft corner of a render surface is defined as the origin (0,0)

Declaration
IViewport CreateViewport(uint minx, uint miny, uint width, uint height)
Parameters
Type Name Description
System.UInt32 minx

Left edge of viewport in pixels

System.UInt32 miny

Top edge of viewport in pixels

System.UInt32 width

Width of viewport in pixels

System.UInt32 height

Height of viewport in pixels

Returns
Type Description
IViewport

DestroyAllStages()

Destroy all render stages

Declaration
void DestroyAllStages()

DestroyAllViewports()

Destroy all user created viewport object data

Declaration
void DestroyAllViewports()

DestroyStage(UInt64)

Destroy a render stage

Declaration
void DestroyStage(ulong stage)
Parameters
Type Name Description
System.UInt64 stage

The stage id to destroy

DestroyStage(IRenderStage)

Destroy a render stage

Declaration
void DestroyStage(IRenderStage stage)
Parameters
Type Name Description
IRenderStage stage

The stage reference to destroy

DestroyViewport(UInt64)

Declaration
void DestroyViewport(ulong viewport)
Parameters
Type Name Description
System.UInt64 viewport

DestroyViewport(IViewport)

Declaration
void DestroyViewport(IViewport viewport)
Parameters
Type Name Description
IViewport viewport

SetBloomConfig(UInt64, BloomEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBloomConfig(ulong stage, BloomEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

BloomEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetBloomConfig(IBloomStage, BloomEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBloomConfig(IBloomStage stage, BloomEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IBloomStage stage

The stage reference

BloomEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetBlur1DConfig(UInt64, Blur1DEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBlur1DConfig(ulong stage, Blur1DEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

Blur1DEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetBlur1DConfig(IBlur1DStage, Blur1DEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBlur1DConfig(IBlur1DStage stage, Blur1DEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IBlur1DStage stage

The stage reference

Blur1DEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetBlurConfig(UInt64, BlurEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBlurConfig(ulong stage, BlurEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

BlurEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetBlurConfig(IBlurStage, BlurEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetBlurConfig(IBlurStage stage, BlurEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IBlurStage stage

The stage reference

BlurEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetColourEffectsConfig(UInt64, ColourEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetColourEffectsConfig(ulong stage, ColourEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

ColourEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetColourEffectsConfig(IColourEffectsStage, ColourEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetColourEffectsConfig(IColourEffectsStage stage, ColourEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IColourEffectsStage stage

The stage reference

ColourEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetCustomShaderUniformValues<T>(UInt64, String, T)

Update user defined custom shader uniforms - Single value

Declaration
void SetCustomShaderUniformValues<T>(ulong stage, string uniformName, T data)
    where T : struct
Parameters
Type Name Description
System.UInt64 stage

The stage id

System.String uniformName

The string name reference of the uniform

T data

The struct containing the uniform data

Type Parameters
Name Description
T

SetCustomShaderUniformValues<T>(UInt64, String, T[])

Update user defined custom shader uniforms - Array of values

Declaration
void SetCustomShaderUniformValues<T>(ulong stage, string uniformName, T[] dataArray)
    where T : struct
Parameters
Type Name Description
System.UInt64 stage

The stage id

System.String uniformName

The string name reference of the uniform

T[] dataArray

The array of structs containing the uniform data

Type Parameters
Name Description
T

SetCustomShaderUniformValues<T>(ICustomShaderStage, String, T)

Update user defined custom shader uniforms - Single value

Declaration
void SetCustomShaderUniformValues<T>(ICustomShaderStage stage, string uniformName, T data)
    where T : struct
Parameters
Type Name Description
ICustomShaderStage stage

The stage reference

System.String uniformName

The string name reference of the uniform

T data

The struct containing the uniform data

Type Parameters
Name Description
T

SetCustomShaderUniformValues<T>(ICustomShaderStage, String, T[])

Update user defined custom shader uniforms - Array of values

Declaration
void SetCustomShaderUniformValues<T>(ICustomShaderStage stage, string uniformName, T[] dataArray)
    where T : struct
Parameters
Type Name Description
ICustomShaderStage stage

The stage reference

System.String uniformName

The string name reference of the uniform

T[] dataArray

The array of structs containing the uniform data

Type Parameters
Name Description
T

SetDistortionConfig(UInt64, DistortionEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetDistortionConfig(ulong stage, DistortionEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

DistortionEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetDistortionConfig(IDistortionStage, DistortionEffectConfiguration, Single)

Update Render Stage Configuration

Declaration
void SetDistortionConfig(IDistortionStage stage, DistortionEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IDistortionStage stage

The stage reference

DistortionEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetMeshRenderLightingProperties(UInt64, MeshRenderLightingPropertiesConfiguration, Single)

Update Mesh Render Overall Light Properties - Number of lights, specular colour, shininess

Declaration
void SetMeshRenderLightingProperties(ulong stage, MeshRenderLightingPropertiesConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

MeshRenderLightingPropertiesConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetMeshRenderLightingProperties(IMeshRenderStage, MeshRenderLightingPropertiesConfiguration, Single)

Update Mesh Render Overall Light Properties - Number of lights, specular colour, shininess

Declaration
void SetMeshRenderLightingProperties(IMeshRenderStage stage, MeshRenderLightingPropertiesConfiguration configuration, float transitionSeconds = 0F)
Parameters
Type Name Description
IMeshRenderStage stage

The stage reference

MeshRenderLightingPropertiesConfiguration configuration
System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetMeshRenderLights(UInt64, MeshRenderLightConfiguration[], Single)

Update Mesh Render Per Light Properties

Declaration
void SetMeshRenderLights(ulong stage, MeshRenderLightConfiguration[] lightConfigurations, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

MeshRenderLightConfiguration[] lightConfigurations

Array of target light configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetMeshRenderLights(IMeshRenderStage, MeshRenderLightConfiguration[], Single)

Update Mesh Render Per Light Properties

Declaration
void SetMeshRenderLights(IMeshRenderStage stage, MeshRenderLightConfiguration[] lightConfigurations, float transitionSeconds = 0F)
Parameters
Type Name Description
IMeshRenderStage stage

The stage reference

MeshRenderLightConfiguration[] lightConfigurations

Array of target light configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetMeshRenderMesh(UInt64, Vertex3D[])

Update Mesh Render - The Mesh

Declaration
void SetMeshRenderMesh(ulong stage, Vertex3D[] mesh)
Parameters
Type Name Description
System.UInt64 stage

The stage id

Vertex3D[] mesh

Array of target light configuration

SetMeshRenderMesh(IMeshRenderStage, Vertex3D[])

Update Mesh Render - The Mesh

Declaration
void SetMeshRenderMesh(IMeshRenderStage stage, Vertex3D[] mesh)
Parameters
Type Name Description
IMeshRenderStage stage

The stage reference

Vertex3D[] mesh

Array of target light configuration

SetMixStageProperties(UInt64, Vector4, Single, Boolean)

Update Render Stage Configuration

Declaration
void SetMixStageProperties(ulong stage, Vector4 amounts, float transitionSeconds = 0F, bool normalise = false)
Parameters
Type Name Description
System.UInt64 stage

The stage id

Vector4 amounts

The target 4-component scalar mix amounts

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

System.Boolean normalise

Clamp mix values to 1.0

SetMixStageProperties(IMixStage, Vector4, Single, Boolean)

Update Render Stage Configuration

Declaration
void SetMixStageProperties(IMixStage stage, Vector4 amounts, float transitionSeconds = 0F, bool normalise = false)
Parameters
Type Name Description
IMixStage stage

The stage reference

Vector4 amounts

The target 4-component scalar mix amounts

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

System.Boolean normalise

Clamp mix values to 1.0

SetStyleEffectsCrtConfig(UInt64, CrtEffectConfiguration, Single)

Update StyleEffects Configuration - Cathode Ray Tube

Declaration
void SetStyleEffectsCrtConfig(ulong stage, CrtEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

CrtEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsCrtConfig(IStyleEffectsStage, CrtEffectConfiguration, Single)

Update StyleEffects Configuration - Cathode Ray Tube

Declaration
void SetStyleEffectsCrtConfig(IStyleEffectsStage stage, CrtEffectConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

CrtEffectConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsEdgeDetectionConfig(UInt64, EdgeDetectionConfiguration, Single)

Update StyleEffects Configuration - Edge Detection

Declaration
void SetStyleEffectsEdgeDetectionConfig(ulong stage, EdgeDetectionConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

EdgeDetectionConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsEdgeDetectionConfig(IStyleEffectsStage, EdgeDetectionConfiguration, Single)

Update StyleEffects Configuration - Edge Detection

Declaration
void SetStyleEffectsEdgeDetectionConfig(IStyleEffectsStage stage, EdgeDetectionConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

EdgeDetectionConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsGroupConfig(UInt64, StyleEffectGroupConfiguration, Single)

Update StyleEffects Configuration - All effects at once

Declaration
void SetStyleEffectsGroupConfig(ulong stage, StyleEffectGroupConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

StyleEffectGroupConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsGroupConfig(IStyleEffectsStage, StyleEffectGroupConfiguration, Single)

Update StyleEffects Configuration - All effects at once

Declaration
void SetStyleEffectsGroupConfig(IStyleEffectsStage stage, StyleEffectGroupConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

StyleEffectGroupConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsOldMovieConfig(UInt64, OldMovieConfiguration, Single)

Update StyleEffects Configuration - Old Movie Reel

Declaration
void SetStyleEffectsOldMovieConfig(ulong stage, OldMovieConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

OldMovieConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsOldMovieConfig(IStyleEffectsStage, OldMovieConfiguration, Single)

Update StyleEffects Configuration - Old Movie Reel

Declaration
void SetStyleEffectsOldMovieConfig(IStyleEffectsStage stage, OldMovieConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

OldMovieConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsPixellateConfig(UInt64, PixellateConfiguration, Single)

Update StyleEffects Configuration - Pixellate

Declaration
void SetStyleEffectsPixellateConfig(ulong stage, PixellateConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

PixellateConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsPixellateConfig(IStyleEffectsStage, PixellateConfiguration, Single)

Update StyleEffects Configuration - Pixellate

Declaration
void SetStyleEffectsPixellateConfig(IStyleEffectsStage stage, PixellateConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

PixellateConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsStaticConfig(UInt64, StaticConfiguration, Single)

Update StyleEffects Configuration - Static

Declaration
void SetStyleEffectsStaticConfig(ulong stage, StaticConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
System.UInt64 stage

The stage id

StaticConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetStyleEffectsStaticConfig(IStyleEffectsStage, StaticConfiguration, Single)

Update StyleEffects Configuration - Static

Declaration
void SetStyleEffectsStaticConfig(IStyleEffectsStage stage, StaticConfiguration config, float transitionSeconds = 0F)
Parameters
Type Name Description
IStyleEffectsStage stage

The stage reference

StaticConfiguration config

The target stage configuration

System.Single transitionSeconds

Time in seconds over which to interpolate the current configuration to the target configuration

SetSurfaceCopyDataStageCallback(UInt64, Action<TextureData>)

Update user defined callback for GPU to CPU surface pixel data transfer on rendering completion

Declaration
void SetSurfaceCopyDataStageCallback(ulong stage, Action<TextureData> callback)
Parameters
Type Name Description
System.UInt64 stage

The stage id

Action<TextureData> callback

User delegate called once rendering complete to provide user the results data. Rendering may happen asynchronously hence the use of callbacks to avoid multithreaded issues

SetSurfaceCopyDataStageCallback(ISurfaceCopyStage, Action<TextureData>)

Update user defined callback for GPU to CPU surface pixel data transfer on rendering completion

Declaration
void SetSurfaceCopyDataStageCallback(ISurfaceCopyStage stage, Action<TextureData> callback)
Parameters
Type Name Description
ISurfaceCopyStage stage

The stage reference

Action<TextureData> callback

User delegate called once rendering complete to provide user the results data. Rendering may happen asynchronously hence the use of callbacks to avoid multithreaded issues

In This Article
Back to top yak2D - Alex Paterson