[AD] Successives calls to fixup_datafile()

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


Hello,


Are successive calls to fixup_datafile() on a same datafile
supposed to be working?

I have problems in my application, using true-color graphics
loaded from a datafile. My application allows switching video
mode dynamically, one of the common point being to allow to
switch from fullscreen to windowed driver using ALT-ENTER.

Without using fixup_datafile(), I'm getting BGR colors on a RGB
display (B and R components being reversed).

Calling fixup_datafile() after each video mode change, the
first video mode for which its called works, other doesn't.
I can confirm this if I switch back and forth.

eg:
  Start with DIRECTX driver, call fixup_datafile()
  Colors ok
  Switch to DIRECTX_WIN driver, call fixup_datafile()
  Colors reversed
  Switch back to DIRECTX driver, call fixup_datafile()
  Colors ok

Other way:
  Start with DIRECTX_WIN driver, call fixup_datafile()
  Colors ok
  Switch to DIRECTX driver, call fixup_datafile()
  Colors reversed
  Switch back to DIRECTX_WIN driver, call fixup_datafile()
  Colors ok

Running Windows Allegro WIP 4.1.18.

Any idea? I had a quick look at the code and did not find any
"obvious" return due to multiple call. Conversion is always processed,
but with all those pointer table replacement it is a bit confusing to
follow.


Thanks,
Omar






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