Render result seems partially flipped on miyoo mini

171 Views Asked by At

I'm trying to port game Freedink https://savannah.gnu.org/git/?group=freedink to Miyoo mini handheld. At the first run I saw this

  1. Splash screen is ok
  2. In da house: stats is ok but homies are flipped.
  3. The house collapsed

After some investigations I assumed that the problem is in SDL_BlitSurface function. After I changed this code

      {
    /* Copy splash to the background buffer so that D-Mod can
       start an effect from it (e.g. Pilgrim Quest's burning
       splash screen effect) */

    SDL_BlitSurface(splash, NULL, GFX_lpDDSTwo, NULL);
    SDL_FreeSurface(splash);
      }

    /* Copy splash screen (again) to the screen during loading time */
    SDL_BlitSurface(GFX_lpDDSTwo, NULL, GFX_lpDDSBack, NULL);

    flip_it();
  }

to this:

      {
    /* Copy splash to the background buffer so that D-Mod can
       start an effect from it (e.g. Pilgrim Quest's burning
       splash screen effect) */

    SDL_BlitSurface(splash, NULL, GFX_lpDDSThird, NULL);        //First copy to GFX_lpDDSThird
    SDL_BlitSurface(GFX_lpDDSThird, NULL, GFX_lpDDSTwo, NULL);  //And only then to GFX_lpDDSTwo
    SDL_FreeSurface(splash);
      }

    /* Copy splash screen (again) to the screen during loading time */
    SDL_BlitSurface(GFX_lpDDSTwo, NULL, GFX_lpDDSBack, NULL);

    flip_it();
  }

splash screen also become flipped. My question is simple: is this behavior known and how to fix this?

0

There are 0 best solutions below