Commit graph

507 commits

Author SHA1 Message Date
Yotam Mann
9049857b80 fire-and-forget buffer player 2016-02-08 13:44:49 -05:00
Yotam Mann
de37b6798d adding Master as a dependency
Addresses #112
2016-01-31 12:20:55 -05:00
Yotam Mann
61caca5054 volume change proportional to the number of oscillators 2016-01-18 00:27:46 -05:00
Yotam Mann
5a772466ae 3 new oscillator types
and combined them into the OmniOscillator
2016-01-17 22:43:44 -05:00
Yotam Mann
9d3b5947fd Reverting to non-signal playbackRate
because Safari isn’t there yet with signal-rate playbackRate
2015-12-06 13:14:36 -05:00
Yotam Mann
74110715f5 Revert "playbackRate is now a signal"
This reverts commit f889a77f0f.
2015-12-06 13:14:36 -05:00
Yotam Mann
f6a95f2f49 default partials value 2015-11-25 21:46:54 -05:00
Yotam Mann
33dbdeff41 can set partials in constructor 2015-11-25 21:46:47 -05:00
Yotam Mann
fe5d6ac94e getting partials (correctly) for other Oscillator types 2015-11-23 23:51:36 -05:00
Yotam Mann
ac693eac4b doc'ing 2015-11-17 23:21:55 -05:00
Yotam Mann
4c3cf0d8fc handling partials member for other oscillator types 2015-11-17 22:51:10 -05:00
Yotam Mann
22ab61fb09 noise has playbackRate which adjusts the "frequency" 2015-11-10 23:47:10 -05:00
Yotam Mann
f889a77f0f playbackRate is now a signal 2015-11-10 23:46:47 -05:00
Yotam Mann
f1be71c0c2 updating to new Volume API 2015-11-02 20:08:53 -05:00
Yotam Mann
1c00c650db updating to new Volume API 2015-10-21 10:33:13 -04:00
Yotam Mann
8a7195e962 canGetUserMedia -> supported
also handling MediaStream.stop deprecation
2015-09-30 13:47:42 -04:00
Yotam Mann
971c6ddfe1 updated mic docs 2015-09-18 17:19:09 -07:00
Yotam Mann
14a780c1ca bug fixes and compatibility tests 2015-09-18 17:18:44 -07:00
Yotam Mann
2d5d4d1dfe Merge pull request #89 from polyrhythmatic/externalinput
updated Microphone, added ExternalInput
2015-09-18 15:43:11 -07:00
Yotam Mann
813a665ac8 looped player passes no duration to start method 2015-09-11 17:06:57 -04:00
Yotam Mann
95f1f15a12 giving example of repeated start and stop methods 2015-09-05 15:15:47 -04:00
Yotam Mann
eccdb659c2 renamed Tone/core/Types -> Tone/core/Type 2015-09-04 16:48:21 -04:00
Yotam Mann
09a151ea2b light styling. 2015-09-03 10:32:00 -04:00
Yotam Mann
a68b1aecd6 cleaning up syncing. 2015-09-03 10:24:20 -04:00
Yotam Mann
7ff330cb96 schedules a stopped state if the source is not looped 2015-09-03 10:24:10 -04:00
Seth Kranzler
1f667411fe removes double checking, changes sourceList to sources 2015-09-02 11:11:42 -04:00
Yotam Mann
5e8c2c3777 source uses Tone.Volume as the output. 2015-08-31 16:55:47 -04:00
Yotam Mann
45b6988090 set custom partials array for Oscillator 2015-08-31 16:42:27 -04:00
Yotam Mann
b2283d640f syncing to the Transport through events 2015-08-31 15:13:43 -04:00
Yotam Mann
9f0935967b can compute the first value of the oscillator 2015-08-27 21:32:09 -04:00
Seth Kranzler
68a0dcf943 adds open/close methods with callback, removes onLoad 2015-08-26 15:40:14 -04:00
Yotam Mann
054662e033 accept phase in constructor 2015-08-21 17:04:29 -04:00
Yotam Mann
0eeaa402de player accepts a Tone.Buffer in the constructor 2015-08-21 17:04:15 -04:00
Yotam Mann
ec400401c7 Sources don't extend TimelineState 2015-08-21 15:01:22 -04:00
Yotam Mann
af5609ce2e Player takes AudioBuffer in constructor 2015-08-21 15:01:09 -04:00
Yotam Mann
d714e05bb3 more precise regexp 2015-08-21 15:00:52 -04:00
Yotam Mann
80c416e398 throws error with invalid noise type 2015-08-21 15:00:40 -04:00
Seth Kranzler
c7b04bae47 remove unused callback, name change, remove error 2015-08-20 15:04:48 -04:00
Seth Kranzler
8fc5de8677 updated Microphone, added ExternalInput 2015-08-19 21:28:47 -04:00
Yotam Mann
80abf87292 reflecting rename 2015-08-18 16:29:39 -04:00
Yotam Mann
79e0383ad6 connectSeries -> chain 2015-08-16 15:18:48 -04:00
Yotam Mann
21391f2a9d Source is schedulable state 2015-08-16 15:16:36 -04:00
Yotam Mann
50d34c0ade using Error instead of TypeError 2015-08-16 15:16:26 -04:00
Yotam Mann
d36af98c46 filter rolloff goes up to -96 now
because why not? Also accepts a string as the type. fixes #84.
2015-08-12 13:13:04 -04:00
Yotam Mann
17f5e8bb8e delays are offset only 1 block now. 2015-07-21 11:22:36 -04:00
Yotam Mann
01060f13db removing old API test 2015-07-18 14:59:18 -04:00
Yotam Mann
3ccc0683bf changing doc links to markdown style 2015-07-04 15:25:37 -04:00
Yotam Mann
caddec650f doc'ing sources
mergine @polyrhythmatic changes
2015-07-04 12:43:21 -04:00
Yotam Mann
8ffd6e538f fixed doc bugs 2015-06-22 01:21:25 -04:00
Yotam Mann
4e9cb3ce1e doc'ing 2015-06-20 15:50:57 -04:00
Yotam Mann
6306841779 doc'ing 2015-06-15 11:27:13 -04:00
Yotam Mann
80a28f8554 using noOp function for defaults 2015-06-14 01:54:36 -04:00
Yotam Mann
800ac13332 jsdoc'ing the sources 2015-06-13 22:30:33 -04:00
Yotam Mann
0877a4862c jsdoc'ing sources 2015-06-13 22:03:06 -04:00
Yotam Mann
23cc2408b2 changing link tag 2015-06-13 21:54:20 -04:00
Yotam Mann
a81ba071f3 changing the styling of this in return statements 2015-06-13 20:54:29 -04:00
Yotam Mann
571183bf27 removing Tone.Type prefix in docs 2015-06-13 20:20:36 -04:00
Yotam Mann
f2f838b630 using signal jsdoc 2015-06-13 19:50:39 -04:00
Yotam Mann
5cb915a332 removing notes on default 2015-06-13 19:29:35 -04:00
Yotam Mann
99c7067f54 sets initial volume of source 2015-06-07 14:05:59 -04:00
Yotam Mann
3bf65cddb3 type annotation 2015-06-07 12:09:08 -04:00
Yotam Mann
68a47a9d58 Normal->NormalRange & Number->Default 2015-05-24 09:45:15 -04:00
Yotam Mann
1f69151c5f renamed Tone.Frequency -> Tone.Type.Frequency 2015-05-23 19:07:28 -04:00
Yotam Mann
6ef3dd2f51 renamed Tone.Time -> Tone.Type.Time 2015-05-23 19:01:05 -04:00
Yotam Mann
f0bcd68812 renamed Tone.Signal.Units to Tone.Type
also renamed Tone.Source.State to Tone.State
2015-05-23 18:57:05 -04:00
Yotam Mann
3f3cbe5f04 detune value in cents 2015-05-21 13:51:40 -04:00
Yotam Mann
02ec3215df new oscillator types
sine[partialsCount] i.e. sine6, triangle2, square3, etc.
2015-05-12 23:49:03 -04:00
Yotam Mann
a2f4a3595b jsdoc'ing 2015-05-05 16:40:52 -04:00
Yotam Mann
4818c14faa fixes AudioSourceNode looping bug in Chrome 42
This should be addressed in Chrome 43.

Fixes #64
2015-04-28 22:12:59 -04:00
Yotam Mann
15ebac4c37 Player autostart
Plays as soon as the buffer is loaded.
2015-04-28 16:17:54 -04:00
Yotam Mann
c7ff31caf9 sources are explicitly stereo
makes it easier to go through stereo effects.
2015-04-28 14:33:59 -04:00
Yotam Mann
a85b72727f setting read/write as an array 2015-04-05 14:53:27 -04:00
Yotam Mann
81670122d3 completely disposing readOnly properties
need to set them writable first
2015-04-05 14:41:43 -04:00
Yotam Mann
3a93d52ee1 making source's signal attributes readOnly
this helps avoid a common error which is overwriting a signal property
instead of setting the .value attribute
2015-04-05 14:00:52 -04:00
Yotam Mann
e6602d561d fixing bug when updating phase
previously wouldn’t update because the type was still the same. thanks
@mindofmatthew
2015-04-05 10:38:17 -04:00
Yotam Mann
33bedd3fbe applying @mindofmatthew patch 2015-03-27 09:42:20 -04:00
Yotam Mann
a572df7a88 Merge pull request #61 from mindofmatthew/phase-patch
Phase patch
2015-03-27 09:32:59 -04:00
Matthew Kaney
5576c3db22 Fix phase bug for complex waveforms
Fix bug where phase is applied to partials relative to the partial,
rather than the fundamental, frequency
2015-03-26 13:18:41 -04:00
Yotam Mann
ec2bd15ee1 can reverse buffer playback 2015-03-26 10:51:44 -04:00
Yotam Mann
470e8063e3 fix unused playback rate in Noise 2015-03-24 16:28:48 -04:00
Luke Phillips
237202c049 updated typescript definitions and fixed a few type errors 2015-03-07 19:17:16 +00:00
Luke Phillips
e706e0ad5e remove getOversample 2015-03-07 19:04:40 +00:00
Luke Phillips
f4fc005a57 new typescript definitions 2015-03-07 18:45:11 +00:00
Luke Phillips
db5c6eb865 remove old get and set functions 2015-03-07 18:41:10 +00:00
Luke Phillips
17df3dc4bb es5 getters and setters used in multiband eq 2015-03-07 18:26:08 +00:00
Luke Phillips
d2755e10de Merge Tone r4 2015-03-05 16:06:27 +00:00
Yotam Mann
d8a13d6dea setting initial oscillator type 2015-02-28 19:35:27 -05:00
Yotam Mann
3211347fef test if setting "type" is necessary before doing it 2015-02-28 18:06:25 -05:00
Yotam Mann
4e77c61638 JSDoc'ing sources 2015-02-27 11:19:45 -05:00
Yotam Mann
8f0fbe2de8 changing _onended callback 2015-02-23 00:29:49 -05:00
Yotam Mann
219eeaa537 source uses scheduled values to determine state 2015-02-23 00:29:07 -05:00
Yotam Mann
3e358536dd methods return this 2015-02-21 14:06:58 -05:00
Yotam Mann
f8b2261b3a new signal syncing API 2015-02-21 14:06:27 -05:00
Yotam Mann
26d0bcd10e pulseoscillator width gate 2015-02-20 00:53:03 -05:00
Luke Phillips
b545692c09 Noise can setPlayback 2015-02-17 19:58:47 +00:00
Yotam Mann
f61eff011b incorporating playbackRate into player
can’t be an Tone.Signal yet because of a Blink bug
2015-02-10 11:37:11 -05:00
Yotam Mann
26ff8d756e clean up source on dispose 2015-02-10 11:36:36 -05:00
Yotam Mann
50917ac49f migrating signals to ES5 getter/setters 2015-02-06 17:47:26 -05:00
Yotam Mann
66f524eae6 frequency signal units 2015-02-04 10:15:25 -05:00
Yotam Mann
88bb77ba69 getter/setter on playbackRate
for now playbackRate will be just a number until i can get the signal
connection of playbackRate to work across browser.
2015-02-04 10:15:06 -05:00
Yotam Mann
2dbacd3310 added decibels volume control to sources 2015-02-04 10:11:10 -05:00
Yotam Mann
b0b572f113 Using ES5 getter/setter 2015-02-04 10:10:34 -05:00
Yotam Mann
914123b9d1 using only ES5 getter/setters
replacing old getThing and setThing starting with Oscillators
2015-02-03 23:48:47 -05:00
Yotam Mann
fe93152920 signal value setters/getters 2015-02-02 12:50:18 -05:00
Yotam Mann
362afb32eb returning to public dispose method 2015-02-01 22:05:24 -05:00
Yotam Mann
7d30c7784b moving state management to Source 2015-02-01 21:32:07 -05:00
Yotam Mann
e96fb08c44 moved onended in Tone.Source 2015-02-01 20:38:06 -05:00
Yotam Mann
650458fafd new dispose and get/set api
integrated new API on sources
2015-02-01 20:02:13 -05:00
Yotam Mann
9070b13c89 ES5 add getter/setter method 2015-02-01 15:48:20 -05:00
Yotam Mann
251a1e02a5 phase get/set for each of the extended oscillators 2015-02-01 15:47:31 -05:00
Yotam Mann
9eee63459a all sources return this
good for chaining methods
2015-02-01 14:40:47 -05:00
Yotam Mann
db0250e054 set loop boundaries after started
Fixes #49
2015-02-01 13:42:51 -05:00
Yotam Mann
b6875955e4 add type getter/setter 2015-02-01 13:32:39 -05:00
Luke Phillips
b40ce6ba8c getters for player.js 2015-01-25 18:45:19 +00:00
Luke Phillips
a7e4e316c1 Source getter functions 2015-01-20 13:48:54 +00:00
Luke Phillips
b11f86be7c Oscillator getter functions 2015-01-20 12:33:07 +00:00
Yotam Mann
49883947de putting the onload callback back in player
at least for now…
2015-01-05 21:55:57 -05:00
Yotam Mann
22d29c42e3 removing onload callbacks
fits better into the Tone.Buffer.onload scheme
2015-01-05 21:49:21 -05:00
Yotam Mann
080b8f5854 updated Player and Convolver with new Buffer 2015-01-04 21:46:10 -05:00
Yotam Mann
f1cbd96f98 sync/unsync the frequency 2014-12-19 16:39:50 -05:00
Yotam Mann
6ddf1b372f single 'setVolume' definition in Master 2014-12-19 16:27:50 -05:00
Yotam Mann
9e140a7605 Fixing/testing microphone dispose method
Fixes #46
2014-12-19 12:20:26 -05:00
Luke Phillips
e6caa81479 don't crash if user deny's microphone stream 2014-12-16 17:55:08 +00:00
Luke Phillips
8fafb3d20b microphone disconnect error 2014-12-15 17:08:14 +00:00
Yotam Mann
de707f1838 volume gets set right away 2014-12-08 11:03:47 -05:00
Yotam Mann
f7a14f2b37 all frequency values accept a note name as well 2014-12-06 16:48:36 -05:00
Yotam Mann
cd31d02048 jsdoc'ing 2014-12-03 21:38:24 -05:00
Yotam Mann
1b9cc1483b jsdoc'ing 2014-12-03 17:20:23 -05:00
Yotam Mann
2d0bcffc9f adding defaults to jsdocs 2014-12-02 01:42:08 -05:00
Yotam Mann
25496dea77 switched to updated chain method 2014-11-30 21:32:09 -05:00
Yotam Mann
cf2cb263b2 chain -> connectSeries, fan -> connectParallel 2014-11-30 17:37:29 -05:00
Yotam Mann
310231dbd1 using Tone.WaveShaper instead of native node 2014-11-30 13:20:35 -05:00
Yotam Mann
2b22bfac31 updating dependencies 2014-11-24 18:51:35 -05:00
Yotam Mann
0a442a2608 oscillator accepts Tone.Time as frequency 2014-11-09 10:57:14 -05:00
Yotam Mann
dcfac108eb using Tone constructor in signal classes 2014-11-04 01:21:42 -05:00
Yotam Mann
0bea209d68 simplify buffer constructor 2014-10-22 22:27:21 -04:00
Yotam Mann
3b10b93eca Merge pull request #39 from indefinit/unicode-fix
Unicode fix
2014-10-22 21:55:21 -04:00
Kevin Siwoff
054d5ff2e8 fixes buffer initialization in Player.js 2014-10-22 18:24:58 -04:00
Kevin Siwoff
b45c983152 updates player class and build for Buffer 2014-10-21 14:55:29 -04:00
Yotam Mann
9f827a8dad short delay to avoid clicks on change OmniOsc type 2014-10-16 14:52:08 -04:00
Kevin Siwoff
f784f5585f adds Buffer class, refactors Player class to use new Buffer member 2014-10-16 14:48:23 -04:00
Yotam Mann
a4cc79cfde stopped state doesn't wait for on ended event
the oneneded event is inconsistent when the source is not connected
directly to Master (such as in the case of an LFO).

Fixes #34
2014-10-08 11:59:31 -04:00
Yotam Mann
7972f0db34 Pulse, PWM, and Omni extend Oscillator 2014-10-03 16:07:30 -04:00
Yotam Mann
a8e156fcaf made Oscillator.oscillator _private 2014-10-03 16:06:42 -04:00
Yotam Mann
2daa8c64ad Oscillators inherit Tone.Oscillator setFrequency 2014-10-03 15:16:32 -04:00
Yotam Mann
e2c0e47f2f Noise getType method 2014-10-03 14:54:09 -04:00
Yotam Mann
1ed4f5288c allowing for loopEnd to be a Tone.Time 2014-10-03 01:00:48 -04:00
Yotam Mann
02c21fed73 switches types without a pop 2014-10-03 01:00:37 -04:00
Yotam Mann
35bdca0568 default Player loop is still the end of the file 2014-10-02 18:58:24 -04:00
Yotam Mann
7d26a67910 loop attributes can be passed in options object
also attributes can remain tempo relative. #27
2014-10-02 13:21:22 -04:00
Yotam Mann
d3f9834ca0 typo in Noise 2014-10-01 00:55:31 -04:00
Yotam Mann
452983920f using OmniOscType enum type 2014-09-30 22:48:21 -04:00
Yotam Mann
14d254fd97 altering default values 2014-09-30 22:48:00 -04:00
Yotam Mann
18bab7da59 setters and options objects for Sources
Fixes #27
2014-09-30 00:28:48 -04:00
Yotam Mann
1e7f46ff61 jsdoc addition 'const' 2014-09-29 23:45:31 -04:00
Yotam Mann
23128469ca combination oscillator class 2014-09-29 23:44:59 -04:00
Yotam Mann
014c5e5db2 new PWMOscillator class 2014-09-29 23:44:43 -04:00
Yotam Mann
c67468cab6 PulseOscillator setters 2014-09-29 23:44:35 -04:00
Yotam Mann
1dcaccdb4c defaults to loopStart offset if offset is not given 2014-09-29 23:44:15 -04:00
Yotam Mann
71af6ca206 testing dispose methods for all classes.
a few classes were not being disposed correctly and leaving some
garbage attached.
2014-09-06 18:55:11 -04:00
Yotam Mann
818797712c made the sawtooth private in pulse oscillator 2014-09-06 15:56:41 -04:00
Yotam Mann
af85ae7e19 Added "use strict" to all classes
Fixes #17
2014-09-04 00:41:40 -04:00
Yotam Mann
39c7da2ab1 styling examples 2014-09-04 00:06:01 -04:00
Yotam Mann
9adbcc3c4d getType 2014-09-02 00:25:20 -04:00
Yotam Mann
c88826e979 setPhase method on Oscillator
This method uses not DelayNode so sample accurate start/stop are
maintained.

Fixes #18
2014-08-31 16:35:02 -04:00
Yotam Mann
76ee2b5540 Tone.PulseOscillator first commit
fixes #25
2014-08-31 16:29:56 -04:00
Yotam Mann
7f7493105a added set method
#27

also fixed dispose method
2014-08-29 17:14:41 -04:00
Yotam Mann
42288c5942 setVolume in db now 2014-08-25 21:47:22 -04:00
Yotam Mann
3cd76459e5 link to parent's dispose method
Fixes #15
2014-08-24 16:24:16 -04:00
Yotam Mann
b2c85eaf44 signals inherit Signal.connect method
this is so that params and signals they connect to don’t need to be
manually zeroed out after connecting.

Fixed #11
2014-08-24 13:19:49 -04:00
Yotam Mann
3f40e26c14 fixed typo 2014-08-23 15:18:51 -04:00
Yotam Mann
be344b7963 unused argument 2014-08-21 14:20:55 -04:00
Yotam Mann
be9ad6ee5f fixed deps 2014-08-21 01:03:51 -04:00
Yotam Mann
9bb8df60a8 sync inherited from Tone.Source 2014-08-20 16:54:26 -04:00
Yotam Mann
d26147aa52 spacing and jsdoc 2014-08-20 16:51:02 -04:00
Yotam Mann
66bf461ebf sync -> syncSource 2014-07-30 15:12:47 -04:00
Yotam Mann
935161a31e can set context 2014-07-30 13:56:44 -04:00
Yotam Mann
18fca530c8 invalid constraint 2014-07-22 11:31:32 -04:00
Yotam Mann
e6bcb3b10c doc updates 2014-07-20 18:17:24 -04:00
Yotam Mann
ceb84b548f no echo cancellation on microphone 2014-06-28 22:13:35 -04:00
Yotam Mann
97e60e11cf updated looping API
removed “loop” method
2014-06-25 13:11:29 -04:00
Yotam Mann
0b4def6155 Tone.Sources can sync to the Transport 2014-06-25 12:47:47 -04:00
Yotam Mann
5ff3b1e4ee working on docs 2014-06-23 14:20:20 -04:00
Yotam Mann
4059c891e5 updated player api 2014-06-21 18:39:01 -04:00
Yotam Mann
ff5d967dc7 some updated to the microphone
still untested
2014-06-21 17:37:17 -04:00
Yotam Mann
736b3aa358 set volume can take a fade time 2014-06-21 15:55:12 -04:00
Yotam Mann
c9cbcaa3e5 fixed doc error 2014-06-20 01:46:39 -04:00
Yotam Mann
ec39ce3985 fixed error in setting frequency detune 2014-06-20 01:46:29 -04:00
Yotam Mann
d48849bd11 jsdoc on DryWet 2014-06-20 01:12:15 -04:00
Yotam Mann
e859706ef9 more disposing 2014-06-20 00:58:02 -04:00
Yotam Mann
c40531f0d4 better dispose method 2014-06-20 00:25:10 -04:00
Yotam Mann
a3abf8e979 better noise! with test and example 2014-06-20 00:25:00 -04:00
Yotam Mann
4b319a0690 new docs. 2014-06-19 21:48:16 -04:00
Yotam Mann
5c7b3b5c18 uniform API for sources 2014-06-19 01:40:16 -04:00
Yotam Mann
410814505c Merge branch 'master' of https://github.com/TONEnoTONE/Tone.js
Conflicts:
	Tone/source/Player.js
2014-06-18 17:04:59 -04:00
Yotam Mann
2b1899792d some docs on Player 2014-06-18 17:01:39 -04:00
Jason Sigal
24c8d2babe added documentation for Player.js and tests for Sources.js 2014-06-18 15:42:08 -04:00
Yotam Mann
7602ad162a doc update 2014-06-18 01:36:40 -04:00
Yotam Mann
92d3c7a238 doc'ing 2014-06-17 12:15:10 -04:00
Yotam Mann
4c3d60f6a4 updated the Source base class 2014-06-16 19:38:46 -04:00
Yotam Mann
9902b2a574 base class for sources 2014-06-15 21:00:22 -04:00
Yotam Mann
6f6cadce4b Sync. JSDoc. JSHint 2014-06-15 17:36:52 -04:00
Yotam Mann
481b728d18 added named buses. 2014-04-16 00:23:58 -04:00
Yotam Mann
e37052fdfa removed require & jquery dependency from examples 2014-04-15 20:05:11 -04:00
Yotam Mann
85e0201371 integrated Transport and musical timing for all methods that take times 2014-04-11 19:17:01 -04:00
Yotam Mann
cf86342a45 updated method names. fixed LFO 2014-04-06 20:12:40 -04:00
Yotam Mann
7fe5c47b8a major rename. sorry again. 2014-04-06 16:51:30 -04:00