Esempio n. 1
0
 public override void Begin()
 {
     DeviceCommandList?.Dispose();
     DeviceCommandList = null;
     ClearState();
     _begun = true;
 }
Esempio n. 2
0
        public override void End()
        {
            if (DeviceCommandList != null)
            {
                throw new VeldridException("Invalid use of End().");
            }

            DeviceCommandList = _context.FinishCommandList(false);
            ResetManagedState();
            _begun = false;
        }
Esempio n. 3
0
        public void Reset()
        {
            if (DeviceCommandList != null)
            {
                DeviceCommandList.Dispose();
                DeviceCommandList = null;
            }
            else if (_begun)
            {
                _context.ClearState();
                SharpDX.Direct3D11.CommandList cl = _context.FinishCommandList(false);
                cl.Dispose();
            }

            ResetManagedState();
        }