ID2D1EffectContext interface

Provides factory methods and other state management for effect and transform authors.

When to implement

Custom implementations are not supported.

Members

The ID2D1EffectContext interface inherits from the IUnknown interface. ID2D1EffectContext also has these types of members:

Methods

The ID2D1EffectContext interface has these methods.

MethodDescription
CheckFeatureSupport

This indicates whether an optional capability is supported by the D3D device.

CreateBlendTransform

This creates a blend transform that can be inserted into a transform graph.

CreateBorderTransform

Creates a transform that extends its input infinitely in every direction based on the passed in extend mode.

CreateBoundsAdjustmentTransform

Creates and returns a bounds adjustment transform.

CreateColorContext

Creates a color context from a color space.

CreateColorContextFromFilename

Creates a color context by loading it from the specified filename. The profile bytes are the contents of the file specified by filename.

CreateColorContextFromWicColorContext

Creates a color context from an IWICColorContext. The D2D1ColorContext space of the resulting context varies, see Remarks for more info.

CreateEffect

Creates a Direct2D effect from a class ID.

CreateOffsetTransform

Creates and returns an offset transform.

CreateResourceTexture

Creates or finds the given resource texture, depending on whether a resource id is specified.

CreateTransformNodeFromEffect

Wraps an effect graph into a single transform node and then inserted into a transform graph. This allows an effect to aggregate other effects.

CreateVertexBuffer

Creates a vertex buffer or finds a standard vertex buffer and optionally initializes it with vertices.

FindResourceTexture

Finds the given resource texture if it has already been created with ID2D1EffectContext::CreateResourceTexture with the same GUID.

FindVertexBuffer

This finds the given vertex buffer if it has already been created with ID2D1EffectContext::CreateVertexBuffer with the same GUID.

GetDpi

Gets the unit mapping that an effect will use for properties that could be in either dots per inch (dpi) or pixels.

GetMaximumSupportedFeatureLevel

This indicates the maximum feature level from the provided list which is supported by the device.

IsBufferPrecisionSupported

Indicates whether the buffer precision is supported by the underlying Direct2D device.

IsShaderLoaded

This tests to see if the given shader is loaded.

LoadComputeShader

Loads the given shader by its unique ID.

LoadPixelShader

Loads the given shader by its unique ID.

LoadVertexShader

Loads the given shader by its unique ID.

 

Remarks

This interface is passed to an effect implementation through the ID2D1EffectImpl::Initialize method. In order to prevent applications casually gaining access to this interface, and to separate reference counts between the public and private interfaces, it is not possible to call QueryInterface between the ID2D1DeviceContext and the ID2D1EffectContext.

Each call to ID2D1Effect::Initialize will be provided a different ID2D1EffectContext interface. This interface tracks resource allocations for the effect. When the effect is released, the corresponding allocations will also be released.

Requirements

Minimum supported client

Windows 8 and Platform Update for Windows 7 [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2012 and Platform Update for Windows Server 2008 R2 [desktop apps | Windows Store apps]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Header

D2D1EffectAuthor.h

Library

D2D1.lib

See also

ID2D1Factory::RegisterEffect
ID2D1EffectImpl

 

 

Community Additions

ADD
Show:
© 2014 Microsoft