<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>codehop &#187; loop</title>
	<atom:link href="http://codehop.com/tag/loop/feed/" rel="self" type="application/rss+xml" />
	<link>http://codehop.com</link>
	<description>#code #art #music</description>
	<lastBuildDate>Mon, 23 Apr 2012 18:37:35 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.2.38</generator>
	<item>
		<title>Deep Synth &#8212; Dynamically Generated Oscillators</title>
		<link>http://codehop.com/deep-synth-dynamically-generated-oscillators/</link>
		<comments>http://codehop.com/deep-synth-dynamically-generated-oscillators/#comments</comments>
		<pubDate>Tue, 24 Nov 2009 18:26:56 +0000</pubDate>
		<dc:creator><![CDATA[Jacob Joaquin]]></dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[compound instrument]]></category>
		<category><![CDATA[deep note]]></category>
		<category><![CDATA[dr. james a. moorer]]></category>
		<category><![CDATA[loop]]></category>
		<category><![CDATA[mp3]]></category>
		<category><![CDATA[oscillator]]></category>
		<category><![CDATA[supercollider]]></category>

		<guid isPermaLink="false">http://csound.noisepages.com/?p=154</guid>
		<description><![CDATA[The situation &#8212; You want an instrument that can play any number of oscillators, determined by a p-field value in the score. The problem &#8212; Unit generators cannot be dynamically created in an instrument with a simple loop. One possible &#8230; <a href="http://codehop.com/deep-synth-dynamically-generated-oscillators/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>The situation &#8212; You want an instrument that can play any number of oscillators, determined by a p-field value in the score. The problem &#8212; Unit generators cannot be dynamically created in an instrument with a simple loop. One possible solution &#8212; Multiple events can be generated in a loop, with each event triggering an oscillator-based instrument.</p>
<p><strong>Download:</strong> <a href="http://www.thumbuki.com/TheCsoundBlog/Deep_Synth.csd">Deep_Synth.csd</a><br />
<strong>Listen:</strong> <a href="http://www.thumbuki.com/TheCsoundBlog/Deep_Synth.mp3">Deep_Synth.mp3</a></p>
<p>The Csound file <a href="http://www.thumbuki.com/TheCsoundBlog/Deep_Synth.csd">Deep_Synth.csd</a> provides an example of how to dynamically generate oscillators using the compound instrument technique. A compound instrument is two or more instruments that operate as a single functioning unit. This particular compound instrument is built from two instruments: DeepSynth and SynthEngine. SynthEngine is, you guessed it, the synth engine, while DeepSynth is a player instrument that generates multiple events for SynthEngine using the opcodes <em>loop_lt</em> and <em>event_i</em>:</p>
<pre>
i_index = 0
loop_start:
    ...
    event_i "i", $SynthEngine, 0, idur, iamp, ipch, iattack, idecay, ipan,
            irange, icps_min, icps_max, ifn
loop_lt i_index, 1, ivoices, loop_start
</pre>
<p>
If you are wondering why we can&#8217;t just place a unit generator, such as <em>oscil</em>, inside of a loop, read Steven Yi&#8217;s articles Control Flow <a href="http://csounds.com/journal/2006spring/controlFlow.html">Pt I</a> and <a href="http://csounds.com/journal/2006summer/controlFlow_part2.html">Pt II</a>. Pay special attention to the section <em>IV. Recursion &#8211; Tecnical Explanation</em> near the end of Pt. II.  Not only does Mr. Yi do an excellent job explaining these technical reasons, but he also provides another applicable solution for creating multiple unit generator instances utilizing recursion and user-defined opcodes.</p>
<h4>Sound Design</h4>
<p>The instrument SynthEngine uses a single wavetable oscillator, an amplitude envelope and the jitter opcode to randomly modulate frequency. A single instance of DeepSynth can generate multiple instances of SynthEngine. DeepSynth can generate a single instance, or 10,000+. Users have control over the depth of frequency modulation, as well as the rate in which jitter ramps from one random value to the next. Panning between instances of SynthEngine is evenly distributed.</p>
<h4>&#8220;Turn it up!&#8221; &#8211; Abe Simpson</h4>
<p>The name DeepSynth is a homage to <a href="http://www.jamminpower.com/jam.html">Dr. James A. Moorer</a>&#8216;s piece <a href="http://en.wikipedia.org/wiki/Deep_Note">Deep Note</a>, also known as the infamous <a href="http://www.thx.com/">THX</a> Logo Theme. Very early in the design, it became evident that DeepSynth is capable of making very Deep Note like drones. This is due to the fact that it does utilize some of the defining techniques used in Dr. Moorer&#8217;s piece.</p>
<p>I highly recommend reading <a href="http://www.batuhanbozkurt.com/instruction/recreating-the-thx-deep-note">Recreating the THX Deep Note</a> by Batuhan Bozkurt at <a href="http://www.batuhanbozkurt.com/">EarSlap</a>. The author conveniently walks readers through each step of the process, providing both audio and <a href="http://www.audiosynth.com/">Supercollider</a> code examples. If you have ever yearned to create that amazing sound for yourself, here&#8217;s your opportunity.</p>
]]></content:encoded>
			<wfw:commentRss>http://codehop.com/deep-synth-dynamically-generated-oscillators/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://www.thumbuki.com/TheCsoundBlog/Deep_Synth.mp3" length="1083756" type="audio/mpeg" />
		</item>
		<item>
		<title>Splice and Stutter</title>
		<link>http://codehop.com/splice-and-stutter/</link>
		<comments>http://codehop.com/splice-and-stutter/#comments</comments>
		<pubDate>Fri, 23 Oct 2009 18:34:39 +0000</pubDate>
		<dc:creator><![CDATA[Jacob Joaquin]]></dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[bt]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[creativecommons]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[jean-luc sinclair]]></category>
		<category><![CDATA[loop]]></category>
		<category><![CDATA[sampler]]></category>

		<guid isPermaLink="false">http://csound.noisepages.com/?p=105</guid>
		<description><![CDATA[Today on The Csound Blog, we&#8217;re going to learn how to build a loop-based sampler out of common household ingredients. Listen: mp3 Download: splice_and_stutter.csd, BT Sample Pack (13.2 MB) Here&#8217;s a brief rundown of today&#8217;s example. A drum loop is loaded &#8230; <a href="http://codehop.com/splice-and-stutter/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-103" title="Splice and Stutter" src="http://codehop.com/wp-content/uploads/2009/10/SpliceAndStutterThumb.jpg" alt="Splice and Stutter" width="200" height="181" />Today on The Csound Blog, we&#8217;re going to learn how to build a loop-based sampler out of common household ingredients.</p>
<p>Listen: <a href="http://www.thumbuki.com/TheCsoundBlog/Splice_and_Stutter.mp3">mp3</a></p>
<p>Download: <a href="http://www.thumbuki.com/TheCsoundBlog/splice_and_stutter.csd">splice_and_stutter.csd</a>, <a href="http://www.archive.org/download/BT/BT44.zip">BT Sample Pack</a> (13.2 MB)</p>
<p>Here&#8217;s a brief rundown of today&#8217;s example. A drum loop is loaded into an f-table with the instrument <em>LoadSample</em>. The instrument <em>SampleEngine</em> plays back selective parts of the loop. Instruments <em>Basic</em>, <em>Stutter</em> and <em>Random</em> are interface instruments that simplify the process of triggering samples.</p>
<p>The <em>LoadSample</em> instrument loads a sample into an f-table, while storing information about the sample into an ad hoc data structure created from <strong>chn</strong> busses. Here isn&#8217;t the place to go into detail. I will say that it is akin to a C struct, and stores the file name, sample rate, length of file (in samples), the tempo, and the number of beats (quarter notes) in the loop. All the user-defined opcodes are support opcodes for the data structure.</p>
<p><em>SampleEngine</em> is the heart of this piece. It works by triggering discreet notes from within the loop, with the loop offset being determined by input it receives via p-field 7. The offset unit is in beats. Let&#8217;s say the loop is 16 beats long. A passed value of 0 plays the first quarter note. A value of 1 plays the second quarter note of the loop, etc.</p>
<p>This instrument is designed to be played by other instruments, rather than being triggered directly by a score i-event. That is&#8230;</p>
<p>Instead of having multiple samplers that do various things, I created a single complex sampler engine that is capable of a wider range of tricks. The problem with complex instruments in Csound is that writing score events can be cumbersome to write and certainly hard to read, especially when dealing with several parameters. This is where the interface instruments come into play.</p>
<p>The interface instruments <em>Basic</em>, <em>Stutter</em> and <em>Random</em> help us tame the complexity of <em>SampleEngine</em> by reducing the number of p-fields needed by the score, and by defining clear behaviors.  <em>Basic</em> is a no thrills controller that simply triggers part of the loop. <em>Stutter</em>, well, stutters. <em>Random</em> randomly picks a beat and plays it.</p>
<p>A greatly added benefit to this approach is that the score is much easier to read. Instead of trying to figure out if a particular i-event stutters or not by scanning a row of numbers, one can just casually look at the name of the instrument used. To put it another way, does this stutter?</p>
<pre>i 5 7 1 0.25 0.5 100 12 0.083 1 0</pre>
<p>How about this?</p>
<pre>i $Stutter 7 1 0.25 0.5 100 12 [1 / 12]</pre>
<p>There are a lots of ins and outs to today&#8217;s example. And I admit, I skipped over most of them. If there is a particular issue or issues you wish for me to expand on, comment below, and I&#8217;ll make it a priority to blog about it in the future.</p>
<p>This sampler is a derivitive work based on an instrument co-developed by <a href="http://www.jeanlucsinclair.com/">Jean-Luc Sinclair</a> (aka Jean-Luc Cohen) and myself back in 2006. The loop in today&#8217;s example is by <a href="http://www.btmusic.com/">BT</a> (aka Brian Transeau), released under a <a href="http://creativecommons.org/licenses/by/3.0/">Creative Commons attribution license</a>, and released as part of the <a href="http://wiki.laptop.org/go/Sound_samples">OLPC Sample Library</a>. You can obtain this sample and others <a href="http://www.archive.org/download/BT/BT44.zip">here</a>. (13.2 MB) You will need the loop &#8220;105 Blanketed Lama.wav&#8221; in order to run the csd file.</p>
<p><strong>Update:</strong> There is an issue with the CSD file not running on <span style="text-decoration: line-through;">Windows</span> Windows Me (or earlier). There is now a fix. Download the new <a href="http://www.thumbuki.com/TheCsoundBlog/splice_and_stutter.csd">splice_and_stutter.csd</a>, and see line 269 for details. This only applies to users of <span style="text-decoration: line-through;">Windows</span> Windows Me (or earlier versions).</p>
<p>Thanks to everyone on the <a href="http://www.nabble.com/CSD-error-bug-with-stutter-instrument-on-windows--tt26041900.html">Csound Mailing List</a> who helped straighten this out.</p>
]]></content:encoded>
			<wfw:commentRss>http://codehop.com/splice-and-stutter/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
<enclosure url="http://www.thumbuki.com/TheCsoundBlog/Splice_and_Stutter.mp3" length="314163" type="audio/mpeg" />
		</item>
		<item>
		<title>Wii Loop Machine</title>
		<link>http://codehop.com/wii-loop-machine/</link>
		<comments>http://codehop.com/wii-loop-machine/#comments</comments>
		<pubDate>Thu, 22 Mar 2007 15:10:22 +0000</pubDate>
		<dc:creator><![CDATA[Jacob Joaquin]]></dc:creator>
				<category><![CDATA[the cosmos]]></category>
		<category><![CDATA[controller]]></category>
		<category><![CDATA[drums]]></category>
		<category><![CDATA[joystiq]]></category>
		<category><![CDATA[loop]]></category>
		<category><![CDATA[maxmsp]]></category>
		<category><![CDATA[nintendo]]></category>
		<category><![CDATA[theamazingrolo]]></category>
		<category><![CDATA[video]]></category>
		<category><![CDATA[vimeo]]></category>
		<category><![CDATA[wii]]></category>
		<category><![CDATA[wiiloopmachine]]></category>

		<guid isPermaLink="false">http://www.thumbuki.com/20070322/wii-loop-machine.html</guid>
		<description><![CDATA[Wii Loop Machine Demo on Vimeo A demo of my Wii Loop Machine software, which uses a Nintendo Wii controller to wirelessly controller music on your computer. Download it at http://www.theamazingrolo.blogspot.com Video stolen from joystiq.com.]]></description>
				<content:encoded><![CDATA[<p><embed src="http://www.vimeo.com/moogaloop.swf?clip_id=155978" quality="best" scale="exactfit" width="400" height="300" type="application/x-shockwave-flash"></embed></p>
<p><a href="http://www.vimeo.com/clip:155978">Wii Loop Machine Demo</a> on <a href="http://www.vimeo.com/">Vimeo</a><br />
<blockquote>A demo of my Wii Loop Machine software, which uses a Nintendo Wii controller to wirelessly controller music on your computer. Download it at <a href="http://theamazingrolo.blogspot.com/2007/03/wii-loop-machine.html">http://www.theamazingrolo.blogspot.com</a></p></blockquote>
<p>Video stolen from <a href="http://www.joystiq.com/2007/03/22/drop-mad-beats-with-the-amazing-wii-loop-machine/">joystiq.com</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://codehop.com/wii-loop-machine/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
