public void Merge(ShaderOutputContext other) { Structures.AddRange(other.Structures); ConstantBuffers.AddRange(other.ConstantBuffers); Textures.AddRange(other.Textures); Samplers.AddRange(other.Samplers); UniformConstants.AddRange(other.UniformConstants); if (VertLayout != null && other.VertLayout != null) { throw new DuplicateBindpointException("Vertex layout is defined twice"); } if (VertLayout == null) { VertLayout = other.VertLayout; } if (ShaderBinding != null && other.ShaderBinding != null) { throw new DuplicateBindpointException("Shader bindings are defined twice"); } if (ShaderBinding == null) { ShaderBinding = other.ShaderBinding; } }