> # NAME

> cgSetCompilerIncludeFile - add shader source file to context

> # SYNOPSIS

>       #include <Cg/cg.h>

>       void cgSetCompilerIncludeFile( CGcontext context, const char *name, const char *filename );

> # PARAMETERS

> context

>   The context in which to add the source code for inclusion by the compiler.

> name

>   The virtual file system name of the shader source.

> filename

>   System file system name of shader source file.

> # RETURN VALUES

> None.

> # DESCRIPTION

> Each Cg runtime context maintains a virtual filesystem of shader source code for inclusion by the compiler. cgSetCompilerIncludeFile populates source code into the virtual filesystem from a file. A name is removed from the virtual filesystem by using NULL for the filename. The virtual filesystem is completely cleared by using NULL for the name.

> # EXAMPLES

> # ERRORS

> CG_INVALID_CONTEXT_HANDLE_ERROR is generated if context is not a valid context.

> CG_FILE_READ_ERROR is generated if the file filename can not be opened for input.

> # HISTORY

> cgSetCompilerIncludeFile was introduced in Cg 2.1.

> # SEE ALSO

> cgSetCompilerIncludeString, cgGetCompilerIncludeCallback, cgSetCompilerIncludeCallback