public static void LoadContent(GraphicsDevice graphicsDevice) { _graphicsDevice = graphicsDevice; _viewPortSize = new Point(_graphicsDevice.Viewport.Width, _graphicsDevice.Viewport.Height); _spriteBatch = new SpriteBatch(graphicsDevice); _primitiveBatch = new PrimitiveBatch(graphicsDevice); #if !XNATOUCH _pixelTexture = new Texture2D(graphicsDevice, 1, 1, 0, TextureUsage.None, SurfaceFormat.Color); Color[] pixelColor = new Color[1]; pixelColor[0] = Color.White; _pixelTexture.SetData <Color>(pixelColor); _renderTargetManager = new RenderTargetManager(graphicsDevice); _renderTargetManager.LoadContent(); #else _pixelTexture = Texture2D.FromFile(DrawingManager.GraphicsDevice, "Content/pixel.png"); #endif LoadEmbeddedIceEffects(); }
public static void LoadContent(GraphicsDevice graphicsDevice) { _graphicsDevice = graphicsDevice; _viewPortSize = new Point(_graphicsDevice.Viewport.Width, _graphicsDevice.Viewport.Height); _spriteBatch = new SpriteBatch(graphicsDevice); _primitiveBatch = new PrimitiveBatch(graphicsDevice); #if !XNATOUCH _pixelTexture = new Texture2D(graphicsDevice, 1, 1, 0, TextureUsage.None, SurfaceFormat.Color); Color[] pixelColor = new Color[1]; pixelColor[0] = Color.White; _pixelTexture.SetData<Color>(pixelColor); _renderTargetManager = new RenderTargetManager(graphicsDevice); _renderTargetManager.LoadContent(); #else _pixelTexture = Texture2D.FromFile(DrawingManager.GraphicsDevice, "Content/pixel.png"); #endif LoadEmbeddedIceEffects(); }