Skip to content

Commit e08d9d4

Browse files
Update README.md
1 parent 46ef151 commit e08d9d4

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,17 @@ statically link and use in non-free / proprietary / commercial projects!
151151

152152
# Performance
153153

154-
For fastest performance use Pypy rather than standard Python.
154+
If you need more performance, do in this order:
155155

156-
Every call to C is costly, so it's slightly faster if you use Python data structures and functions when calculating
156+
1. Use Pypy rather than standard CPython. It is much, much faster and will make more difference than any other optimisations you might do.
157+
158+
2. Every call to C is costly, so it's slightly faster if you use Python data structures and functions when calculating
157159
in your update loop
158160
and then only convert them to C data structures when you have to call the C functions for drawing.
159161

162+
3. The raylib.* functions are potentially 1.5x faster than the pyray.* equivalents, so if you need a tiny bit more performance
163+
you can switch your inner loop functions to these.
164+
160165
## Bunnymark
161166

162167

@@ -184,4 +189,4 @@ You can create a standalone binary using the Nuitka compiler. For example, here
184189
[RetroWar: 8-bit Party Battle](https://store.steampowered.com/app/664240/RetroWar_8bit_Party_Battle/?git) is out now. Defeat up to 15 of your friends in a tournament of 80s-inspired retro mini games.
185190

186191
[Coding Games With Pygame Zero & Python](https://github.com/electronstudio/pygame-zero-book) is
187-
a book for Python beginners.
192+
a book for Python beginners.

0 commit comments

Comments
 (0)