Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Note
This method is available only when developing for Windows.
Compiles a shader from a string containing shader assembly code (ASM).
Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)
Syntax
public static CompiledShader AssembleFromSource (
string shaderSourceCode,
CompilerMacro[] preprocessorDefines,
CompilerIncludeHandler includeHandler,
CompilerOptions options,
TargetPlatform platform
)
Parameters
- shaderSourceCode
String that contains the shader data. - preprocessorDefines
Describes preprocessor definitions used by an effect object. - includeHandler
User-implemented interface to provide callbacks for #include directives during shader compilation. - options
Compilation optimization options. - platform
Target platform for compilation.
Return Value
The compiled shader.
See Also
Reference
ShaderCompiler Class
ShaderCompiler Members
Microsoft.Xna.Framework.Graphics Namespace
Platforms
Windows XP SP2, Windows Vista