URL:
  <http://gna.org/bugs/?17573>

                 Summary: SDL_BlitSurface is duplicating the rightmost column
when scrolling right
                 Project: Battle for Wesnoth
            Submitted by: thonsew
            Submitted on: Tue 25 Jan 2011 03:59:46 PM GMT
                Category: Bug
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Graphics
                  Status: None
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 1.8.5
        Operating System: Fedora

    _______________________________________________________

Details:

Scrolling right with keys/mouse causes the rightmost column of the screen to
be duplicated across the entire screen.

The problem was described in this posting, but I don't think that a bug was
posted.

http://forum.wesnoth.org/posting.php?mode=reply&f=4&sid=28ba106f30ff2d4a532332dccb28b211&t=32423#preview

along with a picture.

http://img163.imageshack.us/i/wesnothbug.png/


 The problem is that SDL_BlitSurface is copying from one surface onto itself
and duplicating content from the right side of the screen.  The problem can be
fixed by making the  changes indicated in the diff below in the file
wesnoth-1.8.5/src/display.cpp.  This creates a copy of the screen and prevents
corruption.


diff display.cpp.old display.cpp
1425,1426d1424
<       surface screen(screen_.getSurface());
< 
1435,1436c1433,1437
<       if (!screen_.update_locked())
<               SDL_BlitSurface(screen,&srcrect,screen,&dstrect);
---
>       if (!screen_.update_locked()){
>           surface screen(screen_.getSurface());
>         surface screen_copy = make_neutral_surface(screen);
>               SDL_BlitSurface(screen_copy,&srcrect,screen,&dstrect);
>       }




thonsew




    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?17573>

_______________________________________________
  Message sent via/by Gna!
  http://gna.org/


_______________________________________________
Wesnoth-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-bugs

Reply via email to