示例#1
0
        private CompilationResult CompileOrGet(string shaderFile, string shaderFunction, string profile)
        {
            var key = $"{shaderFile}::{shaderFunction}::{profile}";

            return(s_compilationCache.GetOrAdd(key, k => ShaderBytecode.Compile(DirectXHelper.ReadResource(shaderFile), shaderFunction, profile, ShaderFlags.None)));
        }