cgGetParameterResourceSize(3)

NAME
cgGetParameterResourceSize - get size of resource associated with a parameter

SYNOPSIS
  #include <Cg/cg.h>
  long cgGetParameterResourceSize( CGparameter param );

PARAMETERS
The parameter for which the associated resource size will be retrieved.

RETURN VALUES
Returns the size on the GPU of the resource associated with param.

Returns -1 if an error occurs.

DESCRIPTION
cgGetParameterResourceSize returns the size in bytes of the resource corresponding to a parameter if the parameter belongs to a Cg buffer resource.

The size of sampler parameters is zero because they have no actual data storage.

The size of an array parameter is the size of an array element parameter times the length of the array.

The size of a structure parameter is the sum of the size of all the members of the structure plus zero or more bytes of profile-dependent padding.

EXAMPLES
to-be-written

ERRORS
CG_INVALID_PARAM_HANDLE_ERROR is generated if param is not a valid parameter.

HISTORY
cgGetParameterResourceSize was introduced in Cg 2.0.

SEE ALSO
cgGetParameterBufferOffset, cgGetParameterBufferIndex