Re: [AD] [WIN] pageflip needs fixing before 4.0

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


To Robin: Argh !!! You're going to frighten everyone with your title ;-)

> Some gfx drivers have problems with the current windows bodge of
> allocating 3 video pages that causes pageflip to flicker. This is fixed
> by only allocating 2 buffers, which is currently not possible as it is
> unknown if the programme will use triple buffering.

More detailed informations: the problem seems to originate in 3.9.35 WIP but
surfaced only recently. Moreover I think it's a little untimely to say that
it is only fixed by allocating 2 buffers: afaik all the proposed fixes have
not been tested yet and we have already a first workaround. I'm relatively
confident that we'll find a fix.

> I am posting this here for thoughts on the best solution:

Only for post 5.0 if we follow Peter's original versioning.

> 1) Do nothing, and update the docs to explain this problem and that
> programmes should always offer triple buffer (which always works) too.

Not very nice.

> 2) Add a var or set_video_pages (int numpages); function (like
> set_color_depth) to be called before set_gfx_mode.

Too much Windows specific.

> 3) Use a scheme like the older allegro virtualpage pageflip:
> set_gfx_mode (GFX_AUTODETECT, 640, 480, 0, 0);

Maybe the way to go: extending the syntax of set_gfx_mode() to pass some
hints about the number of video pages.

> 4) Allocate 2 pages (1 backbuffer) so pageflip works on call to
> set_gfx_mode, then release DD and re-init DD with 2 backbuffers if it
> turns out a 2nd is needed for triple buffer

Worse than a nightmare ;-)

--
Eric Botcazou
ebotcazou@xxxxxxxxxx



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/