void IFrameworkView.Initialize(CoreApplicationView applicationView) { applicationView.Activated += OnActivated; _device = game.Device as MetroGraphicsDevice; //_device = new MetroGraphicsDevice(); }
public Texture(MetroGraphicsDevice dev, int width, int height) { this.dev = dev; var format = new D3D11.Texture2DDescription { Format = DXGI.Format.R8G8B8A8_UNorm, Width = width, Height = height, ArraySize = 1, MipLevels = 1, BindFlags = D3D11.BindFlags.ShaderResource, SampleDescription = new DXGI.SampleDescription { Count = 1 } }; // Allocate a 2-D surface as the depth/stencil buffer. tex = new D3D11.Texture2D(dev._device, format); }
public static void Main(string[] args) { var device = new Ankh.Platform.Metro.MetroGraphicsDevice(); var game = new DefenetronGame(device); Direct3DCoreWindowMain.Run(game); }