Commit graph

2540 commits

Author SHA1 Message Date
Corwin Kuiper
67e20b1e72 square rooting and magnitudes 2021-06-12 11:13:40 +01:00
Corwin Kuiper
682bbc9a50 change everything to explicitly use u32 2021-06-11 20:47:46 +01:00
Corwin Kuiper
b08e8d24be from tuple accepts anything that is convertable 2021-06-11 20:38:06 +01:00
Corwin
f57a250c1c
Delete iwillnotletyouletmedown.gba 2021-06-08 20:13:49 +01:00
Corwin
1357e1254f
Merge pull request #66 from corwinkuiper/number-methods
Number methods
2021-06-08 19:16:01 +01:00
Corwin Kuiper
8b206ba40c changed to use rotation directly
as was previously written, this would not do anything as integer rotation is an identity.
2021-06-08 19:12:25 +01:00
Corwin Kuiper
a5f4673806 set position with vector 2021-06-08 19:08:45 +01:00
Corwin
8e50dc8bd8
Merge pull request #65 from corwinkuiper/optimisation-of-backgrounds
Optimisation of backgrounds
2021-06-08 17:24:15 +01:00
Corwin Kuiper
4f21b40cfc make multiply and divide more generic 2021-06-08 17:18:44 +01:00
Corwin Kuiper
301a22d93a add type for making unit vector from angle 2021-06-08 17:10:27 +01:00
Corwin Kuiper
1ac9e54296 fix sin implementation 2021-06-08 17:08:05 +01:00
Corwin Kuiper
81db1b861c multiplication and division by constant 2021-06-08 16:46:13 +01:00
Corwin Kuiper
0ea0f1df3f implement base changing 2021-06-08 15:54:25 +01:00
Corwin Kuiper
527729f5ba I am aware this uses too many arguments, but it's private so I don't care too much 2021-06-08 12:34:24 +01:00
Corwin Kuiper
4aa2a18058 remove unused imports 2021-06-08 12:32:51 +01:00
Corwin Kuiper
9952771bd4 use new tuple implementation 2021-06-08 12:32:23 +01:00
Corwin Kuiper
d6eff37b8a add from for tuple 2021-06-08 12:31:27 +01:00
Corwin Kuiper
2163a3b490 fix examples 2021-06-08 12:31:20 +01:00
Corwin Kuiper
df954505bf update tiled functions to use new vector2d 2021-06-08 12:31:06 +01:00
Corwin Kuiper
77f6512ba9 give access to underlying coordinates 2021-06-08 12:25:10 +01:00
Corwin Kuiper
161a429320 should not be public 2021-06-08 12:23:13 +01:00
Corwin Kuiper
0283790185 a vector implementation 2021-06-08 12:22:25 +01:00
Corwin Kuiper
b0329bdcea fix examples and tests 2021-06-07 13:38:18 +01:00
Corwin Kuiper
c106efa8b9 change to system where drawing must provide the map 2021-06-07 13:38:11 +01:00
Corwin Kuiper
86d5c7ca35 optimise getting reference and allow for updating a specific area 2021-06-06 23:27:40 +01:00
Corwin Kuiper
6b725e90ad stop using references 2021-06-06 18:30:42 +01:00
Corwin Kuiper
900b594039 use easily optimisable division for truncate 2021-06-06 18:27:15 +01:00
Corwin
eb212e7f91
Merge pull request #64 from corwinkuiper/map-as-refcell
let user decide whether to use slice or refcell
2021-06-06 16:50:37 +01:00
Corwin Kuiper
87bace3584 let user decide whether to use slice or refcell 2021-06-06 16:35:38 +01:00
Corwin
342aac005c
Merge pull request #63 from corwinkuiper/split-object
move object out of tiled0
2021-06-06 16:18:18 +01:00
Corwin
2a0192de51
Merge pull request #62 from gwilymk/allow-channels-to-loop
Allow channels to loop
2021-06-06 15:56:25 +01:00
Corwin Kuiper
7e837fc3e8 move object out of tiled0 2021-06-06 15:56:01 +01:00
Gwilym Kuiper
40f7975f46 Loop if requested 2021-06-06 15:48:52 +01:00
Gwilym Kuiper
86ba309377 Add ability to set that a channel should loop 2021-06-06 15:47:57 +01:00
Corwin
773e893421
Merge pull request #61 from gwilymk/allow-not-exactly-correct-length-sounds
Handle sounds of length not exactly a multiple of SOUND_BUFFER_SIZE
2021-06-06 14:52:25 +01:00
Gwilym Kuiper
0875e640de Handle sounds of length not exactly a multiple of SOUND_BUFFER_SIZE 2021-06-06 14:48:01 +01:00
Corwin
fd3fe32292
Merge pull request #60 from gwilymk/actual-sound-mixing
Actual sound mixing
2021-06-06 14:24:26 +01:00
Gwilym Kuiper
333797332e Fix the example after rebase 2021-06-06 14:21:03 +01:00
Gwilym Kuiper
3f3b34c250 Fix clippy warning 2021-06-06 14:17:08 +01:00
Gwilym Kuiper
e181f7a751 Refactor to make it a bit more obvious what the write buffer is 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
106e53f917 Use the new mixer in the example 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
f126c7f4f4 Make SoundChannel public 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
d7a8928955 Add should_loop option 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
46683e42c8 Probably too much in 1 commit 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
72dbf2ef9c Add simple double buffer 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
334472f749 Add a comment explaining where the frequency and buffer size come from 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
9d1aeea077 Make it easier for the user to provide sound samples 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
df7a72d618 Fix the sound frequency to 10512Hz 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
8d980697bb Add attribution for the music 2021-06-06 12:58:31 +01:00
Gwilym Kuiper
6ab61b6eb0 Add really basic sound mixer that can play simple tunes 2021-06-06 12:58:31 +01:00