[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[sc-dev] SF.net SVN: supercollider:[8156] trunk/build/Help/ Extending and Customizing SC/Writing_Unit_Generators.html
Revision: 8156
http://supercollider.svn.sourceforge.net/supercollider/?rev=8156&view=rev
Author: jrhb
Date: 2008-12-16 00:15:50 +0000 (Tue, 16 Dec 2008)
Log Message:
-----------
improved helpfiles on how to write ugens, after going through it with a non-sc user
Modified Paths:
--------------
trunk/build/Help/Extending and Customizing SC/Writing_Unit_Generators.html
Modified: trunk/build/Help/Extending and Customizing SC/Writing_Unit_Generators.html
===================================================================
--- trunk/build/Help/Extending and Customizing SC/Writing_Unit_Generators.html 2008-12-16 00:14:48 UTC (rev 8155)
+++ trunk/build/Help/Extending and Customizing SC/Writing_Unit_Generators.html 2008-12-16 00:15:50 UTC (rev 8156)
@@ -5,14 +5,14 @@
<meta http-equiv="Content-Style-Type" content="text/css">
<title></title>
<meta name="Generator" content="Cocoa HTML Writer">
-<meta name="CocoaVersion" content="824.42">
+<meta name="CocoaVersion" content="949.35">
<style type="text/css">
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 21.0px Helvetica}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 15.0px Helvetica; min-height: 18.0px}
p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; font: 15.0px Helvetica}
-p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #ab1809}
-p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #0019b9}
-p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #ab1809; min-height: 16.0px}
+p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #9b1e10}
+p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #0025b4}
+p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #9b1e10; min-height: 16.0px}
p.p7 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco}
p.p8 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px}
p.p9 {margin: 0.0px 0.0px 0.0px 0.0px; font: 14.0px Monaco}
@@ -22,17 +22,18 @@
p.p13 {margin: 0.0px 0.0px 0.0px 0.0px}
p.p14 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Times; min-height: 14.0px}
p.p15 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #606060}
-p.p16 {margin: 0.0px 0.0px 0.0px 0.0px; font: 21.0px Helvetica; min-height: 25.0px}
+p.p16 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; color: #000000}
+p.p17 {margin: 0.0px 0.0px 0.0px 0.0px; font: 21.0px Helvetica; min-height: 25.0px}
span.s1 {color: #000000}
-span.s2 {color: #0019b9}
-span.s3 {font: 12.0px Monaco; color: #0019b9}
+span.s2 {color: #0025b4}
+span.s3 {font: 12.0px Monaco; color: #0025b4}
span.s4 {font: 14.0px Monaco}
span.s5 {font: 14.0px Courier}
span.s6 {font: 12.0px Helvetica}
span.s7 {color: #606060}
-span.s8 {color: #326f13}
+span.s8 {color: #416c1c}
span.s9 {font: 12.0px Monaco}
-span.s10 {color: #ab1809}
+span.s10 {color: #9b1e10}
span.Apple-tab-span {white-space:pre}
</style>
</head>
@@ -328,12 +329,26 @@
<p class="p7">}</p>
<p class="p2"><br></p>
<p class="p3">____________________________________________________________________</p>
+<p class="p3">After a recompilation of the class library (Menu: Lang > Complie Library), the UGen is</p>
+<p class="p3">ready to be used.</p>
<p class="p8"><br></p>
<p class="p4">// test it:</p>
<p class="p8"><br></p>
<p class="p7">{ <span class="s2">MySaw</span>.ar(200,0,0.1) }.play</p>
<p class="p8"><br></p>
-<p class="p3">____________________________________________________________________</p>
+<p class="p2"><br></p>
+<p class="p3">_________________________________________________________</p>
+<p class="p3"><b>Workflow</b></p>
+<p class="p2"><br></p>
+<p class="p3">When changing the C-sourcecode, after each rebuilding the project, there is no need to restart SuperCollider or recompile the library (unless you have changed the class definition)</p>
+<p class="p6"><br></p>
+<p class="p4">// just reboot the server.</p>
+<p class="p2"><br></p>
+<p class="p16">s.reboot;</p>
+<p class="p2"><br></p>
+<p class="p3">Note that if you want to use the internal server (e.g. for scoping), you do need to restart</p>
+<p class="p3">the SuperCollider application.</p>
+<p class="p3">_________________________________________________________</p>
<p class="p8"><br></p>
<p class="p3"><b>Useful macros</b></p>
<p class="p2"><br></p>
@@ -436,7 +451,7 @@
<p class="p3">____________________________________________________________________</p>
<p class="p2"><br></p>
<p class="p1">A Unit Generator that needs a Dtor</p>
-<p class="p16"><br></p>
+<p class="p17"><br></p>
<p class="p3">This is code for a simple fixed delay line.</p>
<p class="p2"><br></p>
<p class="p2"><br></p>
@@ -485,8 +500,10 @@
<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// allocate the buffer</p>
<p class="p7"><span class="Apple-tab-span"> </span>unit->mData = (float*)<span class="s2">RTAlloc</span>(unit->mWorld, unit->mDelayLength * sizeof(float));</p>
<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// RTAlloc allocates out of the real time memory pool of the server<span class="Apple-converted-space"> </span></p>
-<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// which is finite. The size of the real time memory pool is set using the</p>
-<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// -m command line argument of the server.</p>
+<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// which is finite. Note that this memory is not zeroed, so it may contain</p>
+<p class="p4"><span class="Apple-tab-span"> </span>// garbage. Make sure to write before read.</p>
+<p class="p4"><span class="Apple-tab-span"> </span>// The size of the real time memory pool is set using the</p>
+<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// -m command line argument of the server, or by ways of server.options.memSize</p>
<p class="p8"><span class="Apple-tab-span"> </span></p>
<p class="p4"><span class="s1"><span class="Apple-tab-span"> </span></span>// initialize the position</p>
<p class="p7"><span class="Apple-tab-span"> </span>unit->mPosition = 0;</p>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
_______________________________________________
sc-dev mailing list
info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/