Jump to content
  • Advertisement
Sign in to follow this  
Say

resizing a backbuffer

This topic is 4826 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

So i've two windows where my scene is rendered, but indifferent view. i'm using swap chains in for manage the same scene. These windows can be resized, but when i resize the second one the mesh became blured. So i've tried to create a new presentParams for the second chain, but i don't get good results. Where i wrong?

		public void OnResetDevice(object sender, EventArgs e)
		{
			sc_0 = device.GetSwapChain(0);
			presentParams2.Windowed = true;
			presentParams2.SwapEffect = SwapEffect.Discard;
			DisplayMode mode = new DisplayMode();

			presentParams2.BackBufferFormat = mode.Format;
			presentParams2.BackBufferWidth = mode.Width;
			presentParams2.BackBufferHeight = mode.Height;
			presentParams2.EnableAutoDepthStencil = true;
			presentParams2.AutoDepthStencilFormat = DepthFormat.D16;
			sc_1 = new SwapChain(device, presentParams2);
			device.RenderState.ZBufferEnable = true;
			device.RenderState.Ambient = System.Drawing.Color.White;
		}

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!