mirror of
https://github.com/raysan5/raylib.git
synced 2025-12-25 10:22:33 -05:00
Updated raylib data structures (markdown)
@ -49,9 +49,9 @@ Those structures are quite common in most of the engines out there.
|
||||
|
||||
// Audio related data
|
||||
struct Wave; [20 bytes] [+4 bytes] // Wave data pointer (RAM) and data parameters
|
||||
struct AudioStream; [12 bytes] [+4 bytes] // Audio buffer pointer (private) and parameters
|
||||
struct Sound; [16 bytes] [+8 bytes] // Audio stream and samples count
|
||||
struct Music; [18 bytes] [+12 bytes] // Audio stream and music data pointer for streaming
|
||||
struct AudioStream; [16 bytes] [+8 bytes] // Audio buffer pointer (private) and parameters
|
||||
struct Sound; [20 bytes] [+12 bytes] // Audio stream and samples count
|
||||
struct Music; [32 bytes] [+16 bytes] // Audio stream and music data pointer for streaming
|
||||
```
|
||||
|
||||
raylib abuses the data pass-by-value on most of its functions, actually, only around 10% of the functions require dealing with data pointers. For this reason, I tried to keep data structures as small as possible, usually under 64 bytes size, and use internal pointers when data requires modification by some function (usually Load/Update/Unload functions).
|
||||
|
||||
Reference in New Issue
Block a user