internal void BindToGraphicsDevice(GraphicsDevice device)
{
if (_defaultStateObject)
throw new InvalidOperationException("You cannot bind a default state object.");
if (GraphicsDevice != null && GraphicsDevice != device)
throw new InvalidOperationException("This rasterizer state is already bound to a different graphics device.");
GraphicsDevice = device;
}