MfxInputDef#

class MfxInputDef : public MfxBase#

An input definition is manipulated during the MfxEffect::Describe action to tell the host what is expected to flow through the input at cook time. It differs from MfxInput that is the input instance during the cooking, in particular the input definition does not contain any mesh.

Public Functions

MfxInputDef &Label(const char *label)#

Define the human readable label to display next to this input (in hosts supporting it).

MfxInputDef &RequestAttribute(MfxAttributeAttachment attachment, const char *name, int componentCount, MfxAttributeType type, MfxAttributeSemantic semantic, bool mandatory)#

Notify the host that the effect requires (if mandatory is true) or would make good use of a given attribute. If the attribute is mandatory, it is ensured to be present with at least componentCount components of the requested type. If not mandatory, it is the responsibility of this effect to check at cook time whether the attribute exist or not and whether it has enough components and the right type.

The semantics can be used to tell the intended use of the of the attribute to help the host suggest some attributes to send to the effect to the user. Possible values are kOfxMeshAttribSemanticTextureCoordinate, kOfxMeshAttribSemanticNormal, kOfxMeshAttribSemanticColor or kOfxMeshAttribSemanticWeight. It may also just be null.

MfxInputDef &RequestPointAttribute(const char *name, int componentCount, MfxAttributeType type, MfxAttributeSemantic semantic, bool mandatory)#
MfxInputDef &RequestCornerAttribute(const char *name, int componentCount, MfxAttributeType type, MfxAttributeSemantic semantic, bool mandatory)#
MfxInputDef &RequestFaceAttribute(const char *name, int componentCount, MfxAttributeType type, MfxAttributeSemantic semantic, bool mandatory)#
MfxInputDef &RequestMeshAttribute(const char *name, int componentCount, MfxAttributeType type, MfxAttributeSemantic semantic, bool mandatory)#
MfxInputDef &RequestIOMap(bool request = true)#
MfxInputDef &RequestGeometry(bool request = true)#

Set the geometry matrix dependency flag of this input. By default, an input does depend on its geometry, but this may be turned off when the input is used solely for its transform (which must be signaled with RequestTransform).

MfxInputDef &RequestTransform(bool request = true)#

Set the transform matrix dependency flag of this input. By default, an input does not depend on the transform matrix and hence the effect will not have access to the transform matrix, and not be recooked when the transform changes.