🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Can you explain more detail about the front buffer?

Started by
4 comments, last by MJP 3 years, 3 months ago

Hi.

In the Direct3D, the front buffer what exactly means?

If window mode, the front buffer means window screen?

When I draw something in the back buffer and I try swap chain, the back buffer's data will be copied to the front buffer.

Then just we can see the something in the window?

I want to know more detail path of the data before we can see the drawing data in the screen.

like this.

back buffer → (swap chain) → front buffer → video memory??? → window???

Advertisement

Front buffer is sampled by display driver to show and present actual data. By writing to it, you immediately update data to present. You can present a front buffer to any whnd object to display it in the window of the handle.

eu5 said:
In the Direct3D, the front buffer what exactly means?

have a look here: https://docs.microsoft.com/en-us/windows/win32/direct3d9/flipping-surfaces

it should be clearer;

eu5 said:
If window mode, the front buffer means window screen?

Better to say “in window mode, the window displays the front buffer AND in fullscreen mode, the monitor displays the front buffer” - got it?

note: the entire swap chain is a series of buffers, it is entirely created in GPU VRAM, but the only one buffer you see onscreen (or your window) is the contents of the Front buffer

have fun ?

Thank you guys!

The front buffer registered in the video memory, and we register the handle of the window as an output window.

So we can think the front buffer(videos memory)'s data will be display in the output window.

The situation with swap chains is actually pretty complicated in Windows 10, since you have things like desktop composition in the mix. There's a pretty good overview here:

This topic is closed to new replies.

Advertisement