Exemple #1
0
		public Replayer(TracefileFrame frame, TracefileEvent lastEvent, 
			ISwapChainPresenter swapChainPresenter, 
            int? renderTargetViewID = null, int? renderTargetArrayIndex = null,
            int? pixelX = null, int? pixelY = null)
		{
			_frame = frame;
			_lastEvent = lastEvent;
		    _swapChainPresenter = swapChainPresenter;
		    _device = new Device();
		    _deviceContext = _device.ImmediateContext;
            _logger = new TracefileBuilder(_device, 
                renderTargetViewID, renderTargetArrayIndex, 
                pixelX, pixelY);
		}
Exemple #2
0
 public Replayer(TracefileFrame frame, TracefileEvent lastEvent,
                 ISwapChainPresenter swapChainPresenter,
                 int?renderTargetViewID = null, int?renderTargetArrayIndex = null,
                 int?pixelX             = null, int?pixelY = null)
 {
     _frame              = frame;
     _lastEvent          = lastEvent;
     _swapChainPresenter = swapChainPresenter;
     _device             = new Device();
     _deviceContext      = _device.ImmediateContext;
     _logger             = new TracefileBuilder(_device,
                                                renderTargetViewID, renderTargetArrayIndex,
                                                pixelX, pixelY);
 }
Exemple #3
0
        internal SwapChain(Device device, SwapChainDescription description, ISwapChainPresenter presenter)
            : base(device)
        {
            _description = description;

            presenter.Initialize(description.Width, description.Height);
            _presenter = presenter;

            _backBuffer = new Texture2D(device, new Texture2DDescription
            {
                Width     = description.Width,
                Height    = description.Height,
                MipLevels = 1,
                ArraySize = 1
            });
        }
Exemple #4
0
		internal SwapChain(Device device, SwapChainDescription description, ISwapChainPresenter presenter)
            : base(device)
		{
			_description = description;

            presenter.Initialize(description.Width, description.Height);
		    _presenter = presenter;

		    _backBuffer = new Texture2D(device, new Texture2DDescription
			{
				Width = description.Width,
				Height = description.Height,
				MipLevels = 1,
				ArraySize = 1
			});
		}
Exemple #5
0
 public SwapChain CreateSwapChain(int width, int height, ISwapChainPresenter presenter)
 {
     return(CreateSwapChain(new SwapChainDescription(width, height), presenter));
 }
Exemple #6
0
 public SwapChain CreateSwapChain(SwapChainDescription description, ISwapChainPresenter presenter)
 {
     DiagnosticUtilities.RaiseEvent(this, CreatingSwapChain, description);
     return(new SwapChain(this, description, presenter));
 }