I have a class that derives from XNA's GraphicsDevice, and i want to use it in my game. However, i can't quite figure out what i'm supposed to do to make this new graphics device replace the old one. Any suggestions?
A:
Check out the winforms sample to show how to manually create a graphics device and what settings you need to set: http://creators.xna.com/en-us/sample/winforms_series1
Joel Martinez
2009-06-10 00:59:52
Um, i dont think that helps. i want to know how i might go about creating an extended game class that replaces the graphics device with my extended one. Thanks anyway though
RCIX
2009-06-10 03:05:37
+1
A:
It looks like you can subclass the GraphicsDeviceManager class, which would give you access to the GraphicsDeviceManager's GraphicsDevice class, which is publicly get-only. Here's an example MSDN article about subclassing the GraphicsDeviceManager class:
jasonh
2009-06-10 03:10:40