{"id":905,"date":"2014-08-26T00:52:46","date_gmt":"2014-08-26T00:52:46","guid":{"rendered":"http:\/\/charlie-roberts.com\/gibber\/synth\/"},"modified":"2014-08-26T00:52:46","modified_gmt":"2014-08-26T00:52:46","slug":"synth","status":"publish","type":"page","link":"http:\/\/charlie-roberts.com\/gibber\/synth\/","title":{"rendered":"Synth"},"content":{"rendered":"<p>A selectable oscillator attached to an Attack \/ Decay envelope. The attack decay envelope modulates the amplitude of the oscillator.<br \/>\nInherits from Ugen.<\/p>\n<p>Example:<\/p>\n<pre>a = Synth({ maxVoices:4, waveform:'PWM', attack:ms(1), decay:ms(1000) })\n\na.play( [440, 880, 1320], 1\/4 )<\/pre>\n<h2 id=\"properties\">Properties<\/h2>\n<ul>\n<li><em>frequency<\/em> : Hz. default range { 50, 3200 }. default value 440.<\/li>\n<li><em>amp<\/em> : Float. default range { 0, 1 }. default value: .25.<\/li>\n<li><em>pulsewidth<\/em> : Float. default range { 0, 1 }. default value: .5<\/li>\n<li><em>attack<\/em> : Int. Default range { 23, 44100 }. default value: 22050. Measured in samples.<\/li>\n<li><em>decay<\/em> : Int. Default range { 23, 44100 }. default value: 22050. Measured in samples.<\/li>\n<li><em>maxVoices<\/em>: Int. Default value: 1. The maximum number of frequencies the synthesizer can play simultaneously. This value can <em>only be set during initialization<\/em>.<\/li>\n<li><em>glide<\/em>: Float. Default range { 0, 1 }. Default value: .15. This property creates glissandi as the synthesizer moves from one note to the next. The closer the value is to one the longer the glissandi will be. <\/li>\n<li><em>pan<\/em>: Float. Default range { -1, 1 }. Default value: 0. The position in the stereo spectrum of the Synth output.<\/li>\n<li><em>waveform<\/em> : String. The name of an oscillator for the synth to use.<\/li>\n<\/ul>\n<h2 id=\"methods\">Methods<\/h2>\n<ul>\n<li><em>chord<\/em>( Array:frequencies, Float:amp(optional) ) : Playback multiple notes at a provided amplitude. The maxVoices property have been set to a value higher than 1 during intialization for this function to work.<\/li>\n<li><em>note<\/em>( Float:frequency, Float:amp(optional) ) : This method tells the synthesizer to play a single note at a particular volume.<\/li>\n<li><em>play<\/em>( Array:frequencies, Array:durations ) : This method accepts arrays of frequencies and durations as arguments to create and start a sequencer targeting the oscillator.<\/li>\n<li><em>stop<\/em>() : This method stops the sequencer that is built into the oscillator if it has been started.<\/li>\n<li><em>kill<\/em>() : Disconnect the oscillator from whatever bus it is connected to. <\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>A selectable oscillator attached to an Attack \/ Decay envelope. The attack decay envelope modulates the amplitude of the oscillator. Inherits from Ugen. Example: a = Synth({ maxVoices:4, waveform:&#8217;PWM&#8217;, attack:ms(1), decay:ms(1000) }) a.play( [440, 880, 1320], 1\/4 ) Properties frequency : Hz. default range { 50, 3200 }. default value 440. amp : Float. default [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/pages\/905"}],"collection":[{"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/comments?post=905"}],"version-history":[{"count":0,"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/pages\/905\/revisions"}],"wp:attachment":[{"href":"http:\/\/charlie-roberts.com\/gibber\/wp-json\/wp\/v2\/media?parent=905"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}