Automatic Device Resets During a Resize

Anyone who's ever written a Direct3D application in C++ or DirectX for Visual Basic understands that normally, when the window of your application is resized, the device needs to be reset; otherwise, Direct3D will continue to render the scene at the same resolution as when the device was created, and the resulting image will be copied (and stretched to fit) onto the newly sized window. Managed DirectX is smart enough to realize when you've created your device with a Windows Form control, and can automatically reset the device for you when this control is resized. Naturally, you can revert back to the normal behavior and handle device resets yourself quite easily. There is an event attached to the device ...

Get Managed DirectX® 9 Kick Start: Graphics and Game Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.