Exemplo n.º 1
0
 public OpenGLPipeline(OpenGLGraphicsDevice gd, ref ComputePipelineDescription description)
 {
     _gd = gd;
     IsComputePipeline  = true;
     ComputeDescription = description;
     VertexStrides      = Array.Empty <int>();
 }
Exemplo n.º 2
0
 public OpenGLPipeline(OpenGLGraphicsDevice gd, ref ComputePipelineDescription description)
     : base(ref description)
 {
     _gd = gd;
     IsComputePipeline = true;
     ComputeShader     = description.ComputeShader;
     VertexStrides     = Array.Empty <int>();
     ResourceLayouts   = Util.ShallowClone(description.ResourceLayouts);
 }
Exemplo n.º 3
0
        public OpenGLPipeline(OpenGLGraphicsDevice gd, ref GraphicsPipelineDescription description)
        {
            _gd = gd;
            GraphicsDescription = description;

            int numVertexBuffers = description.ShaderSet.VertexLayouts.Length;

            VertexStrides = new int[numVertexBuffers];
            for (int i = 0; i < numVertexBuffers; i++)
            {
                VertexStrides[i] = (int)description.ShaderSet.VertexLayouts[i].Stride;
            }
        }
Exemplo n.º 4
0
        public OpenGLPipeline(OpenGLGraphicsDevice gd, ref GraphicsPipelineDescription description)
            : base(ref description)
        {
            _gd               = gd;
            GraphicsShaders   = Util.ShallowClone(description.ShaderSet.Shaders);
            VertexLayouts     = Util.ShallowClone(description.ShaderSet.VertexLayouts);
            BlendState        = description.BlendState.ShallowClone();
            DepthStencilState = description.DepthStencilState;
            RasterizerState   = description.RasterizerState;
            PrimitiveTopology = description.PrimitiveTopology;

            int numVertexBuffers = description.ShaderSet.VertexLayouts.Length;

            VertexStrides = new int[numVertexBuffers];
            for (int i = 0; i < numVertexBuffers; i++)
            {
                VertexStrides[i] = (int)description.ShaderSet.VertexLayouts[i].Stride;
            }

            ResourceLayouts = Util.ShallowClone(description.ResourceLayouts);
        }
Exemplo n.º 5
0
 public OpenGLCommandList(OpenGLGraphicsDevice gd, ref CommandListDescription description)
     : base(ref description, gd.Features, gd.UniformBufferMinOffsetAlignment, gd.StructuredBufferMinOffsetAlignment)
 {
     _gd = gd;
 }
Exemplo n.º 6
0
 public unsafe OpenGLResourceFactory(OpenGLGraphicsDevice gd)
 {
     _gd = gd;
 }
Exemplo n.º 7
0
 public OpenGLCommandList(OpenGLGraphicsDevice gd, ref CommandListDescription description)
     : base(ref description, gd.Features)
 {
     _gd = gd;
 }
Exemplo n.º 8
0
 public unsafe OpenGLResourceFactory(OpenGLGraphicsDevice gd)
     : base(gd.Features)
 {
     _gd   = gd;
     _pool = gd.StagingMemoryPool;
 }
 public unsafe OpenGLResourceFactory(OpenGLGraphicsDevice gd)
     : base(gd.Features)
 {
     _gd = gd;
 }