public SlimDXRenderWindow(IntPtr windowHandle)
{
mWindowHandle = windowHandle;
try
{
// the debug mode requires the sdk to be installed otherwise an exception is thrown
mDevice = new Device(DeviceCreationFlags.Debug);
}
catch (Direct3D10Exception)
{
mDevice = new Device(DeviceCreationFlags.None);
}
if (mIsWindowed)
{
mHeight = HEIGHT;
mWidth = WIDTH;
}
else
{
mWidth = 1280;
mHeight = 1024;
}
CreateSwapChainRenderTargetAndViewport();
SetRasterizeStateDescription();
}