EffectCompiler.FromStream Method |
Language: |
Creates an effect compiler from an ASCII or binary effect description in a stream.
Visual Basic Public Shared Function FromStream( _
ByVal sourceData As Stream, _
ByVal preprocessorDefines() As Macro, _
ByVal includeFile As Include, _
ByVal flags As ShaderFlags, _
ByRef compilationErrors As String _
) As EffectCompilerC# public static EffectCompiler FromStream(
Stream sourceData,
Macro[] preprocessorDefines,
Include includeFile,
ShaderFlags flags,
out string compilationErrors
);C++ public:
static EffectCompiler^ FromStream(
Stream^ sourceData,
array<Macro>^ preprocessorDefines,
Include^ includeFile,
ShaderFlags flags,
[Out] String^% compilationErrors
);JScript public static function FromStream(
sourceData : Stream,
preprocessorDefines : Macro[],
includeFile : Include,
flags : ShaderFlags,
compilationErrors : String
) : EffectCompiler;
sourceData System.IO.Stream
A Stream object that contains the data used to create the EffectCompiler.preprocessorDefines Microsoft.DirectX.Direct3D.Macro[]
Optional array of preprocessor macro definitions. For more information, see Macro.includeFile Microsoft.DirectX.Direct3D.Include
Optional Include object to use for handling #include directives. If this value is null, #include directives are either honored when compiling from a file, or cause an error when compiled from a resource or memory.flags Microsoft.DirectX.Direct3D.ShaderFlags
One or more compile options identified by the ShaderFlags enumeration.compilationErrors System.String
String that contains a listing of compilation errors.
Microsoft.DirectX.Direct3D.EffectCompiler
An EffectCompiler that represents the effect compiler.
Exceptions
InvalidCallException The method call is invalid. For example, a method's parameter might contain an invalid value. InvalidDataException The data is invalid. OutOfMemoryException Microsoft Direct3D could not allocate sufficient memory to complete the call.
Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center