public ShaderInfo(FileChunk fileChunk) { bytecode = new ShaderBytecode(fileChunk.CompiledShader); this.Name = fileChunk.Name; this.ConstantHandles = new List<EffectHandle>(); this.ConstantDescriptions = new List<ConstantDescription>(); int i = 0; ConstantTable cTable = bytecode.ConstantTable; if (cTable != null) { EffectHandle handle = bytecode.ConstantTable.GetConstant(null, 0); while (handle != null) { ConstantHandles.Add(handle); var desc = bytecode.ConstantTable.GetConstantDescription(handle); ConstantDescriptions.Add(desc); i++; handle = bytecode.ConstantTable.GetConstant(null, i); } } }
public VertexShaderInfo(FileChunk fileChunk) : base(fileChunk) { this.IsVertexShader = true; this.Shader = new VertexShader(GlobalRenderSettings.Instance.Device, bytecode); }
public PixelShaderInfo(FileChunk fileChunk) : base(fileChunk) { this.Shader = new PixelShader(GlobalRenderSettings.Instance.Device, bytecode); }