Difference between pygame.display.update and pygame.display.flip

前端 未结 2 1683
逝去的感伤
逝去的感伤 2020-11-29 08:24

Just like the title implies, is there any difference? I was using pygame.display.flip and I saw on the Internet that instead of using flip they used

2条回答
  •  时光取名叫无心
    2020-11-29 09:01

    Flip will always update the entire screen. Update also update the entire screen, if you don't give argument. But if you give surface(s) as arguments, it will update only these surfaces. So it can be faster, depending on how many surfaces you give it and their width and height.

提交回复
热议问题