NAME
cgCreateParameter - creates a parameter
SYNOPSIS
#include <Cg/cg.h> CGparameter cgCreateParameter(CGcontext ctx, CGtype type);PARAMETERS
- ctx
Specifies the context that the new parameter will be added to.
- type
The type of the new parameter.
DESCRIPTION
cgCreateParameter creates context level shared parameters. These parameters are primarily used by connecting them to one or more program parameters with cgConnectParameter.
RETURN VALUES
Returns the handle to the new parameter.
EXAMPLES
CGcontext Context = cgCreateContext(); CGparameter MySharedFloatParam = cgCreateParameter(Context, CG_FLOAT);ERRORS
CG_INVALID_VALUE_TYPE_ERROR is generated if type is invalid.
CG_INVALID_CONTEXT_HANDLE_ERROR if ctx is invalid.
SEE ALSO
cgCreateParameterArray, cgCreateParameterMultiDimArray, and cgDestroyParameter