Complex Surface creation - an offscreen flipping chain

Started by
1 comment, last by SteveC 24 years, 6 months ago
I want to make an offscreen flipping chain, in system memory, so I try using the following flags when creating the surface: ddsd2.dwFlags = DDSD_CAPS / DDSD_BACKBUFFERCOUNT; ddsd2.ddsCaps.dwCaps = DDSCAPS_SYSTEMMEMORY / DDSCAPS_COMPLEX / DDSCAPS_FLIP; ddsd2.dwBackBufferCount = 1; But I get DDERRR_INVALIDCAPS I''ve tried using the DD util app that lets you create surfaces using whatever flags you want. When I used that it gave me an error as well. So then I tried creating two surfaces, one specified as the FRONTBUFFER and another the BACKBUFFER and then doing an AddAttachedSurface, but again that didn''t seem to work ( got an invalid caps error, even though the DD util app said the combination of flags I used would create a surface ) Has anyone done this ? How can I get it to work? thanks - Steve
Advertisement
hello, i noticed that you are making your backbuffer in system memory. you can''t flip a surface if it''s in system memory because that''s done in hardware. just make a backbuffer without the flipping stuff and use BltFast to copy it to the primary buffer.
Matt Teiken
thanks for the info

This topic is closed to new replies.

Advertisement