Table of Contents

Class ShaderPass

Namespace
HelixToolkit.SharpDX.Shaders
Assembly
HelixToolkit.SharpDX.dll

Shader Pass

public sealed class ShaderPass : DisposeObject, IDisposable
Inheritance
ShaderPass
Implements
Inherited Members

Constructors

ShaderPass(ShaderPassDescription, IEffectsManager?)

public ShaderPass(ShaderPassDescription passDescription, IEffectsManager? manager)

Parameters

passDescription ShaderPassDescription
manager IEffectsManager

Fields

NullPass

public static readonly ShaderPass NullPass

Field Value

ShaderPass

Properties

BlendFactor

Gets or sets the blend factor.

public Color4 BlendFactor { get; }

Property Value

Color4

The blend factor.

BlendState

public BlendStateProxy BlendState { get; }

Property Value

BlendStateProxy

ComputeShader

public ComputeShader ComputeShader { get; }

Property Value

ComputeShader

DepthStencilState

public DepthStencilStateProxy DepthStencilState { get; }

Property Value

DepthStencilStateProxy

DomainShader

public DomainShader DomainShader { get; }

Property Value

DomainShader

GeometryShader

public GeometryShader GeometryShader { get; }

Property Value

GeometryShader

HullShader

public HullShader HullShader { get; }

Property Value

HullShader

IsNULL

public bool IsNULL { get; }

Property Value

bool

Layout

Gets or sets the input layout. This is customized layout used for this ShaderPass only. If this is not set, default is using Layout from InputLayoutDescription

public InputLayoutProxy? Layout { get; }

Property Value

InputLayoutProxy

The input layout.

Name

public string Name { get; }

Property Value

string

PixelShader

public PixelShader PixelShader { get; }

Property Value

PixelShader

RasterState

public RasterizerStateProxy RasterState { get; }

Property Value

RasterizerStateProxy

SampleMask

Gets or sets the sample mask.

public int SampleMask { get; }

Property Value

int

The sample mask.

StencilRef

Gets or sets the stencil reference.

public int StencilRef { get; }

Property Value

int

The stencil reference.

Topology

Gets or sets the topology.

public PrimitiveTopology Topology { get; set; }

Property Value

PrimitiveTopology

The topology.

VertexShader

public VertexShader VertexShader { get; }

Property Value

VertexShader

Methods

BindShader(DeviceContextProxy, bool)

Bind shaders and its constant buffer for this technique

public void BindShader(DeviceContextProxy context, bool bindConstantBuffer = true)

Parameters

context DeviceContextProxy
bindConstantBuffer bool

BindStates(DeviceContextProxy, StateType)

Binds the states.

public void BindStates(DeviceContextProxy context, StateType type)

Parameters

context DeviceContextProxy

The context.

type StateType

The type.

GetShader(ComputeShaderType)

Gets the shader.

public ComputeShader GetShader(ComputeShaderType type)

Parameters

type ComputeShaderType

The type.

Returns

ComputeShader

GetShader(DomainShaderType)

Gets the shader.

public DomainShader GetShader(DomainShaderType type)

Parameters

type DomainShaderType

The type.

Returns

DomainShader

GetShader(GeometryShaderType)

Gets the shader.

public GeometryShader GetShader(GeometryShaderType type)

Parameters

type GeometryShaderType

The type.

Returns

GeometryShader

GetShader(HullShaderType)

Gets the shader.

public HullShader GetShader(HullShaderType type)

Parameters

type HullShaderType

The type.

Returns

HullShader

GetShader(PixelShaderType)

Gets the shader.

public PixelShader GetShader(PixelShaderType type)

Parameters

type PixelShaderType

The type.

Returns

PixelShader

GetShader(ShaderStage)

public ShaderBase? GetShader(ShaderStage type)

Parameters

type ShaderStage

Returns

ShaderBase

GetShader(VertexShaderType)

Gets the shader.

public VertexShader GetShader(VertexShaderType type)

Parameters

type VertexShaderType

The type.

Returns

VertexShader

OnDispose(bool)

Disposes of object resources.

protected override void OnDispose(bool disposeManagedResources)

Parameters

disposeManagedResources bool

If true, managed resources should be disposed of in addition to unmanaged resources.

SetShader(ShaderBase)

Sets the shader.

public void SetShader(ShaderBase shader)

Parameters

shader ShaderBase

The shader.

SetState(BlendStateDescription?)

Sets the state.

public void SetState(BlendStateDescription? blendStateDesc)

Parameters

blendStateDesc BlendStateDescription?

The blend state desc.

SetState(DepthStencilStateDescription?)

Sets the state.

public void SetState(DepthStencilStateDescription? depthStencilStateDesc)

Parameters

depthStencilStateDesc DepthStencilStateDescription?

The depth stencil state desc.

SetState(RasterizerStateDescription?)

Sets the state.

public void SetState(RasterizerStateDescription? rasterizerStateDesc)

Parameters

rasterizerStateDesc RasterizerStateDescription?

The rasterizer state desc.