Exemplo n.º 1
0
        public void Update(DxDevice device, int defaultvertexcount, int defaultinstancecount)
        {
            if (this.indbuffer != null)
            {
                this.indbuffer.Dispose();
            }

            DrawInstancedArgs args = new DrawInstancedArgs();

            args.InstanceCount         = defaultinstancecount;
            args.StartInstanceLocation = 0;
            args.StartVertexLocation   = 0;
            args.VertexCount           = defaultvertexcount;

            this.indbuffer = new InstancedIndirectBuffer(device, args);
        }
Exemplo n.º 2
0
        public void Update(DX11RenderContext context, int defaultinstancecount)
        {
            if (this.indbuffer != null)
            {
                this.indbuffer.Dispose();
            }

            DrawInstancedArgs args = new DrawInstancedArgs();

            args.InstanceCount         = defaultinstancecount;
            args.StartInstanceLocation = 0;
            args.StartVertexLocation   = 0;
            args.VertexCount           = this.geom.VerticesCount;

            this.indbuffer = new InstancedIndirectBuffer(context, args);
        }
Exemplo n.º 3
0
 public DX11NullIndirectDrawer(DxDevice device)
 {
     this.indbuffer = new InstancedIndirectBuffer(device);
 }