#11922 NORM 12.1.0: pygame drawing artifact in xo-1.75

Zarro Boogs per Child bugtracker at laptop.org
Tue Jul 17 03:49:38 EDT 2012


#11922: pygame drawing artifact in xo-1.75
------------------------------------+---------------------------------------
           Reporter:  godiard       |       Owner:  jnettleton   
               Type:  defect        |      Status:  new          
           Priority:  normal        |   Milestone:  12.1.0       
          Component:  not assigned  |     Version:  not specified
         Resolution:                |    Keywords:               
        Next_action:  diagnose      |    Verified:  0            
Deployment_affected:                |   Blockedby:               
           Blocking:                |  
------------------------------------+---------------------------------------
Changes (by jnettlet):

 * cc: garycmartin (added)


Comment:

 It seems as if double buffering is not working properly if you draw
 directly to a screen object in pygame.  A simple solution to this is to
 create a background or canvas and blit all your drawing to that and then
 blit that to the screen before we flip the buffer.

 I have a feeling this has to do with the fact that ARM SOC's typically
 have no video memory, so we don't have to go through the step of drawing
 to offscreen memory, uploading that to video ram and then blitting that to
 the screen.  We can blit directly from system memory to the framebuffer if
 the pixbuf in memory matches the framebuffer.  That is my assumptions from
 what I have seen at least.

 I was also thinking that possibly setting the display to the fullscreen
 and the surface to the screen size subtracting the toolbar height might
 help with the mouse transition jumping.  Something like this.

 {{{

     screen = pygame.display.set_mode((x, y), pygame.DOUBLEBUF)
     background = pygame.Surface((x, y - toolbarheight - tabheight))


 }}}

 Don't know if this is a solution but it is something to explore further.

-- 
Ticket URL: <http://dev.laptop.org/ticket/11922#comment:1>
One Laptop Per Child <http://laptop.org/>
OLPC bug tracking system


More information about the Bugs mailing list