Ray Schamp
cd699dbc0f
Install and configure eslint-config-scratch
2017-04-17 11:52:12 -04:00
Ray Schamp
0610f8a6ce
Update packages, fix lint error
2017-04-17 11:11:06 -04:00
Eric Rosenbaum
c354189385
Merge pull request #33 from LLK/feature/loudness
...
Add mic input for loudness block
2017-04-07 14:02:22 -04:00
Paul Kaplan
6128309d93
Add jsdoc for decodeSound function
2017-03-31 12:09:07 -04:00
Paul Kaplan
cc454f2f72
Return the loader promise for chaining
2017-03-31 12:02:36 -04:00
Eric Rosenbaum
04467673b3
Add stub for loadSounds function with warning
...
… so that the gui can call it without breaking, until it is updated.
2017-03-31 10:50:21 -04:00
Eric Rosenbaum
b14852ab3c
If mic is not enabled, return -1
...
To match Scratch 2.0 behavior
2017-03-27 13:23:01 -04:00
Eric Rosenbaum
83afeb1916
Tidy up sound decoding
2017-03-27 11:51:01 -04:00
Eric Rosenbaum
3608a5947f
Decode sounds in audio engine
...
Remove logic for loading sounds, since that is handled by Scratch Storage
2017-03-22 18:09:42 -04:00
Eric Rosenbaum
c5daccef7c
Rename to ADPCMSoundDecoder, and only decode
...
Scratch Storage now handles asset loading, so this class is now just the decoder
2017-03-22 18:08:44 -04:00
Eric Rosenbaum
7d6adf5864
Add mic input for loudness block
2017-03-20 18:49:37 -04:00
Eric Rosenbaum
ce9766451f
Update jsdocs
2017-02-09 15:48:37 -05:00
Eric Rosenbaum
b91226f9e8
playnote uses volume from vm to set gain
2017-02-09 14:53:59 -05:00
Eric Rosenbaum
5e0e4e2e82
added a comma to a comment
2017-02-02 15:52:36 -05:00
Eric Rosenbaum
bea203e122
fix JSDoc comment
2017-02-02 15:48:26 -05:00
Eric Rosenbaum
7e671791b8
use an enum for audio effect names
2017-02-02 15:41:16 -05:00
Eric Rosenbaum
de99228cd8
check for own property in for (var _ in _ )
2017-02-02 15:25:36 -05:00
Eric Rosenbaum
1c4709e5b9
bind to set isPlaying flag on ended
2017-02-02 15:25:26 -05:00
Eric Rosenbaum
b68c84af02
check for own property in for (var _ in _ )
2017-02-02 15:10:10 -05:00
Eric Rosenbaum
1a26fecca1
Comment all the things!
2017-02-02 14:53:17 -05:00
Eric Rosenbaum
cdc49def15
create empty object for use as a map
2017-02-02 14:51:02 -05:00
Eric Rosenbaum
a1baa94d3c
initialization
2017-02-02 14:49:17 -05:00
Eric Rosenbaum
7483cbdb2f
JSDoc comments
2017-02-01 18:02:04 -05:00
Eric Rosenbaum
dcdc2c0831
check for non-existent sound
2017-01-31 18:36:29 -05:00
Eric Rosenbaum
08a81af9e5
volume state handled in vm sound blocks
2017-01-31 18:35:37 -05:00
Eric Rosenbaum
b70607d659
comments
2017-01-31 18:35:06 -05:00
Eric Rosenbaum
c564ca5b90
remove unused function
2017-01-31 18:34:56 -05:00
Eric Rosenbaum
088efdeb0e
sounds track playing state
2017-01-30 18:13:18 -05:00
Eric Rosenbaum
7f741a509c
sounds stop and restart when played again
2017-01-30 18:12:52 -05:00
Eric Rosenbaum
0742e8e0b0
update comments
2017-01-30 11:27:05 -05:00
Eric Rosenbaum
bee8210764
use promise on playback finished
2017-01-30 11:26:55 -05:00
Eric Rosenbaum
002a378d97
soundplayers are explicitly connected to output node when created
2017-01-30 11:25:43 -05:00
Eric Rosenbaum
42f231858a
effects are managed by vm target and audio engine
2017-01-30 11:24:55 -05:00
Eric Rosenbaum
263f614ef8
pitch effect is applied to active sound players array
2017-01-30 11:18:28 -05:00
Eric Rosenbaum
c9029396c6
state of effects, volume and instrument managed by target in vm
2017-01-30 11:17:18 -05:00
Eric Rosenbaum
7b07d150da
set instrument moved to target in vm
2017-01-30 11:14:07 -05:00
Eric Rosenbaum
8557c4a7ab
audio engine manages play note and beat timing
2017-01-30 11:13:34 -05:00
Eric Rosenbaum
e1d478244d
audioengine loads sounds indexed by md5
...
audioplayers store list of their own active sound players indexed by md5 of the sound. sound players are created when the sound is played, deleted when it ends, and removed from the list of active sound players. the pitch effect uses this list of active sound players to set their playback ratios.
2017-01-30 11:09:45 -05:00
Eric Rosenbaum
a150f018b5
comments
2017-01-30 10:59:03 -05:00
Eric Rosenbaum
b32ee9267b
properties for number of instruments and drums for use by vm
2017-01-11 11:40:35 -05:00
Eric Rosenbaum
3c520d6e10
converesion from one-indexing to zero-indexing happens in vm
2017-01-11 11:26:03 -05:00
Eric Rosenbaum
ad81e1d3de
load and play drum sounds from drumplayer
2017-01-10 18:05:29 -05:00
Eric Rosenbaum
ca8bc2b45d
move global tempo setting to audio engine
2017-01-10 18:04:54 -05:00
Eric Rosenbaum
b540c8ec7b
remove commented code
2017-01-10 18:04:13 -05:00
Eric Rosenbaum
e2255bbbbf
comments
2017-01-10 18:04:01 -05:00
Eric Rosenbaum
c54fc0f154
comments
2017-01-10 18:03:15 -05:00
Eric Rosenbaum
703502cfbb
add stopall function for instruments and drums
2017-01-10 18:02:45 -05:00
Eric Rosenbaum
193a9f181b
initial experiment with drumplayer (
2017-01-10 11:35:03 -05:00
Eric Rosenbaum
0a55312899
change function name to playNoteForSecWithInst
2017-01-10 11:01:36 -05:00
Eric Rosenbaum
a1c31c3f4b
send duration in sec to instrumentplayer
2017-01-10 11:00:22 -05:00
Eric Rosenbaum
03d78a203b
fix beatsToSec function (was getting millis)
2017-01-10 10:59:55 -05:00
Eric Rosenbaum
6948968a85
lint
2017-01-09 21:33:31 -05:00
Eric Rosenbaum
0bd84dd9a6
fix changeTempo to set global tempo
2017-01-09 21:30:23 -05:00
Eric Rosenbaum
d8ab835901
move play note functionality to InstrumentPlayer
2017-01-09 21:28:51 -05:00
Eric Rosenbaum
2058b2dd19
single tempo owned by audioengine
2017-01-09 15:56:59 -05:00
Eric Rosenbaum
9b3119c96e
comments
2017-01-09 15:54:21 -05:00
Eric Rosenbaum
2ca88c880e
play note and play drum return a promise to wait some number of beats
2017-01-08 18:57:51 -05:00
Eric Rosenbaum
4cefe6d2ad
set, change, and report volume
2017-01-08 18:57:10 -05:00
Eric Rosenbaum
a6bb22b90a
fix effect names
2017-01-08 18:56:10 -05:00
Eric Rosenbaum
082be2689d
comments
2017-01-08 18:55:37 -05:00
Eric Rosenbaum
3a9e6b8634
check if no sound at index before playing
2017-01-08 18:38:18 -05:00
Eric Rosenbaum
10cd3a2c31
separate out main audioengine from audioplayer for each clone
2017-01-04 18:34:11 -05:00
Eric Rosenbaum
b99b639cd2
set wet value for echo to 0.5
2017-01-04 15:30:20 -05:00
Eric Rosenbaum
792a7ca953
comments
2016-12-22 23:17:55 -05:00
Eric Rosenbaum
c71ccbb020
log
2016-12-05 14:22:15 -05:00
Eric Rosenbaum
645a080b89
lint
2016-11-30 11:29:00 -05:00
Eric Rosenbaum
9120c3d430
make objects for each effect
2016-11-29 18:33:09 -05:00
Eric Rosenbaum
f797ec80f3
cleanup
2016-11-21 18:27:50 -05:00
Eric Rosenbaum
b169ac8875
new robotic effect using comb filter, remove vocoder
2016-11-21 18:26:31 -05:00
Eric Rosenbaum
ec558d9821
use soundplayer object
2016-11-21 16:01:33 -05:00
Eric Rosenbaum
7aca02b89a
re-enable soundfont player
2016-11-21 16:00:59 -05:00
Eric Rosenbaum
27a7c545a1
re-enable soundfont player
2016-11-21 16:00:02 -05:00
Eric Rosenbaum
b5d513f2b2
add isplaying property, cleanup
2016-11-21 15:57:34 -05:00
Eric Rosenbaum
897fd68c90
wip on new soundplayer object
2016-11-21 12:40:35 -05:00
Eric Rosenbaum
1a088252e3
add effects ‘wobble’ and ‘telephone’
2016-11-19 14:19:31 -05:00
Eric Rosenbaum
19beacc5ce
load adpcm sounds
2016-11-19 14:18:42 -05:00
Eric Rosenbaum
d2eb771eea
cleanup and return a promise
2016-11-19 14:17:43 -05:00
Eric Rosenbaum
5fa9bdf1c9
lint
2016-11-16 17:11:15 -05:00
Eric Rosenbaum
85d8db5d14
wip on loading adpcm wav files
2016-11-16 17:06:34 -05:00
Eric Rosenbaum
d400de1b4c
wip on decoding adpcm wav files
2016-11-14 17:26:28 -05:00
Eric Rosenbaum
0c2548f6ba
comments
2016-11-10 18:04:49 -05:00
Eric Rosenbaum
cf80c9f9b8
replace follower with waveshaper
2016-11-10 14:39:22 -05:00
Eric Rosenbaum
4deff78059
simplified signal processing
2016-11-10 13:49:11 -05:00
Eric Rosenbaum
99bbdeb873
add comment and license
2016-11-09 11:38:40 -05:00
Eric Rosenbaum
7c7e6565aa
lint
2016-11-09 10:59:01 -05:00
Eric Rosenbaum
588adb8b72
experiment with using sprite’s sounds as instrument for play note block
2016-11-09 10:43:46 -05:00
Eric Rosenbaum
a4e18dc2f4
cleanup
2016-11-09 10:41:03 -05:00
Eric Rosenbaum
7a25ced256
clean up and convert webaudio nodes to tone js objects
2016-11-08 17:29:02 -05:00
Eric Rosenbaum
b0786e6dbf
add robotic effect, aka vocoder
2016-11-08 15:07:32 -05:00
Eric Rosenbaum
f7141fe97b
cleanup, WIP converting webaudio nodes to Tone objects
2016-11-08 15:06:29 -05:00
Eric Rosenbaum
28c9bffe4d
vocoder effect, because ROBOTS
2016-11-07 17:30:00 -05:00
Eric Rosenbaum
f43dd8d14c
increase distortion amount and call it “fuzz”
2016-11-02 14:22:34 -04:00
Eric Rosenbaum
d09c95118e
lint
2016-11-01 16:33:18 -04:00
Eric Rosenbaum
9763acb99a
use buffersource objects to play sounds, to fix #4
2016-11-01 16:00:43 -04:00
Eric Rosenbaum
173c243439
fixes to stop all
2016-10-27 15:28:49 -04:00
Eric Rosenbaum
a89ab4b25d
add minilog
2016-10-27 15:28:26 -04:00
Eric Rosenbaum
d9c879d4b7
add distortion effect
2016-10-26 16:53:23 -04:00
Eric Rosenbaum
2ae2200e08
work in progress on tempo blocks
2016-10-25 22:42:34 -04:00
Eric Rosenbaum
e3276c80d5
playsound returns promise for completion
2016-10-25 22:42:15 -04:00
Eric Rosenbaum
f8aaf553f8
set volume and change volume
2016-10-25 22:00:34 -04:00
Eric Rosenbaum
85c4c03076
pitch shift effect 10 units per semitone
2016-10-25 22:00:21 -04:00
Eric Rosenbaum
b30996997a
better handling for sounds that did not load
2016-10-25 16:43:03 -04:00
Eric Rosenbaum
cfabc507ae
slower retry rate for play sound
2016-10-25 10:23:06 -04:00
Eric Rosenbaum
5f8382d69e
pitchshift scaling
2016-10-24 16:59:14 -04:00
Eric Rosenbaum
c8d194b951
handle missing sounds
2016-10-24 16:01:43 -04:00
Eric Rosenbaum
73dc7a3d40
change Tone samplers to players
2016-10-24 13:57:47 -04:00
Eric Rosenbaum
66c865fe03
cleanup
2016-10-19 16:40:23 -04:00
Eric Rosenbaum
e45f6ed7d7
skip adpcm sounds
2016-10-19 16:40:00 -04:00
Eric Rosenbaum
a62b028834
complete instrument list to match scratch 2.0
2016-10-19 16:39:36 -04:00
Eric Rosenbaum
8715beaac7
play spooky note (theremin) and set instrument blocks
2016-10-19 13:13:56 -04:00
Eric Rosenbaum
c47957f421
effects cleanup and comments
2016-10-18 13:32:51 -04:00
Eric Rosenbaum
72733b6e7a
each clone has its own effects chain
2016-10-17 16:51:12 -04:00
Eric Rosenbaum
67d805909b
fix sound loading
2016-10-17 15:41:56 -04:00
Eric Rosenbaum
1f4ef3fd19
loading all sounds on project load
2016-10-14 10:26:08 -04:00
Eric Rosenbaum
b0cb3950fa
initial commit
2016-10-13 14:54:07 -04:00