<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/1.5.2" -->
<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/"
>

<channel>
	<title>bunnytech</title>
	<link>http://bunnyherolabs.com/tech</link>
	<description>bunnyhero gets technical</description>
	<pubDate>Mon, 02 Oct 2006 21:48:54 +0000</pubDate>
	<generator>http://wordpress.org/?v=1.5.2</generator>
	<language>en</language>

		<item>
		<title>hitTest()</title>
		<link>http://bunnyherolabs.com/tech/?p=48</link>
		<comments>http://bunnyherolabs.com/tech/?p=48#comments</comments>
		<pubDate>Mon, 02 Oct 2006 21:48:14 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>flash</category>
		<guid>http://bunnyherolabs.com/tech/?p=48</guid>
		<description><![CDATA[	interesting note to self: MovieClip.hitTest() is not affected by a clip&#039;s _visible property!
	useful for using invisible movieclips for manual mouse testing.

]]></description>
			<content:encoded><![CDATA[	<p>interesting note to self: <code>MovieClip.hitTest()</code> is not affected by a clip&#039;s <code>_visible</code> property!</p>
	<p>useful for using invisible movieclips for manual mouse testing.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=48</wfw:commentRSS>
	</item>
		<item>
		<title>getting serious</title>
		<link>http://bunnyherolabs.com/tech/?p=45</link>
		<comments>http://bunnyherolabs.com/tech/?p=45#comments</comments>
		<pubDate>Fri, 01 Sep 2006 22:24:25 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>uncategorized</category>
		<guid>http://bunnyherolabs.com/tech/?p=45</guid>
		<description><![CDATA[	i want to get serious about blogging about technical matters again. to that end, i&#039;ve removed the flash banner ads and popups from the tech pages, and i may give the look of this section an overhaul. or perhaps i will move all this code-y stuff to a different domain.
	we&#039;ll see!

]]></description>
			<content:encoded><![CDATA[	<p>i want to get serious about blogging about technical matters again. to that end, i&#039;ve removed the flash banner ads and popups from the tech pages, and i may give the look of this section an overhaul. or perhaps i will move all this code-y stuff to a different domain.</p>
	<p>we&#039;ll see!
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=45</wfw:commentRSS>
	</item>
		<item>
		<title>fun with microphones and flash</title>
		<link>http://bunnyherolabs.com/tech/?p=44</link>
		<comments>http://bunnyherolabs.com/tech/?p=44#comments</comments>
		<pubDate>Wed, 12 Jul 2006 23:21:41 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>flash</category>
		<guid>http://bunnyherolabs.com/tech/?p=44</guid>
		<description><![CDATA[	this simple little project is just me playing with the Microphone class in flash.
	
	if you have a microphone connected to your computer, click the &#034;turn mic on&#034; button. you will get a security warning asking if you want to allow bunnyherolabs.com to access your webcam and microphone (don&#039;t worry, i&#039;m not using the cam, and [...]]]></description>
			<content:encoded><![CDATA[	<p>this simple little project is just me playing with the <a href = "http://www.adobe.com/support/flash/action_scripts/actionscript_dictionary/actionscript_dictionary479.html" ><code>Microphone</code></a> class in flash.</p>
	<p></p>
	<p>if you have a microphone connected to your computer, click the &#034;turn mic on&#034; button. you will get a security warning asking if you want to allow bunnyherolabs.com to access your webcam and microphone (don&#039;t worry, i&#039;m not using the cam, and not recording the audio anywhere!). then you may have to set the recording level (&#034;gain&#034;) with the slider. as you talk (or otherwise make sounds into the microphone), the face&#039;s mouth should wag open and closed.</p>
	<p>yes it&#039;s a very crude drawing, but it&#039;s just a fun test!</p>
	<p><b>UPDATE!</b> if you want to embed this into your website or myspace, use this code:</p>
	<form><textarea rows="5" cols="65" style="font: 0.8em Verdana,sans-serif; width: 80%; background: #ffffdd" readonly="1" onclick="this.focus(); this.select()">&lt;div style=&#034;width: 300px; padding: 0; text-align: center&#034;&gt;&lt;embed src=&#034;http://petswf.bunnyherolabs.com/tech/static/mictest.swf&#034; quality=&#034;high&#034; bgcolor=&#034;cccccc&#034; width=&#034;300&#034; height=&#034;160&#034; name=&#034;mictest&#034; align=&#034;middle&#034; type=&#034;application/x-shockwave-flash&#034; pluginspage=&#034;http://www.macromedia.com/go/getflashplayer&#034; &gt;&lt;/embed&gt;&lt;a href=&#034;http://bunnyherolabs.com/tech/?p=44&#034;&gt;from bunnyhero labs&lt;/a&gt;&lt;/div&gt;</textarea></form>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=44</wfw:commentRSS>
	</item>
		<item>
		<title>verlet test for you</title>
		<link>http://bunnyherolabs.com/tech/?p=43</link>
		<comments>http://bunnyherolabs.com/tech/?p=43#comments</comments>
		<pubDate>Wed, 24 May 2006 08:35:04 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>flash</category>
		<guid>http://bunnyherolabs.com/tech/?p=43</guid>
		<description><![CDATA[	a few of you have asked for code to embed my verlet demo into your websites. here it is:
	&#60;embed src=&#034;http://petswf.bunnyherolabs.com/tech/static/verlettest1.swf&#034; quality=&#034;high&#034; bgcolor=&#034;ffffff&#034; width=&#034;235&#034; height=&#034;200&#034; name=&#034;verlettest1&#034; align=&#034;middle&#034; type=&#034;application/x-shockwave-flash&#034; pluginspage=&#034;http://www.macromedia.com/go/getflashplayer&#034; &#62;&#60;/embed&#62;
	have fun!

]]></description>
			<content:encoded><![CDATA[	<p>a few of you have asked for code to embed my verlet demo into your websites. here it is:</p>
	<form><textarea rows="5" cols="65" style="font: 0.8em Verdana,sans-serif; width: 80%; background: #ffffdd" readonly="1" onclick="this.focus(); this.select()">&lt;embed src=&#034;http://petswf.bunnyherolabs.com/tech/static/verlettest1.swf&#034; quality=&#034;high&#034; bgcolor=&#034;ffffff&#034; width=&#034;235&#034; height=&#034;200&#034; name=&#034;verlettest1&#034; align=&#034;middle&#034; type=&#034;application/x-shockwave-flash&#034; pluginspage=&#034;http://www.macromedia.com/go/getflashplayer&#034; &gt;&lt;/embed&gt;</textarea></form>
	<p>have fun!
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=43</wfw:commentRSS>
	</item>
		<item>
		<title>verlet test</title>
		<link>http://bunnyherolabs.com/tech/?p=41</link>
		<comments>http://bunnyherolabs.com/tech/?p=41#comments</comments>
		<pubDate>Thu, 04 May 2006 04:05:30 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>flash</category>
		<guid>http://bunnyherolabs.com/tech/?p=41</guid>
		<description><![CDATA[	i think every flash coder ends up writing some kind of verlet integration demo. here&#039;s mine:
	
	the code is based on the article advanced character physics (by Thomas Jakobsen) which was presented at the 2001 game developers conference.
	i plan to use this for the monkey pet as he swings around.
	what, no source code? sorry, the code [...]]]></description>
			<content:encoded><![CDATA[	<p>i think every flash coder ends up writing some kind of verlet integration demo. here&#039;s mine:</p>
	<p><iframe src="/tech/static/verlettest.swf" width="350" height="300" frameborder="0" style="border: 1px solid black"></iframe></p>
	<p>the code is based on the article <a href="http://www.teknikus.dk/tj/gdc2001.htm"><em>advanced character physics</em></a> (by <a href="http://www.teknikus.dk/tj/">Thomas Jakobsen</a>) which was presented at the 2001 <a href="http://www.gdconf.com/">game developers conference</a>.</p>
	<p>i plan to use this for the monkey pet as he swings around.</p>
	<p>what, no source code? sorry, the code is such a mess that it&#039;s embarrassing!</p>
	<p>(i am also aware of <a href="http://www.cove.org/flade/">flade, the flash dynamics engine</a>, but (a) i thought i&#039;d learn more doing this myself, (b) flade is actionscript 2.0 and my pets are still written in actionscript 1 (although i may upgrade the pet code someday) and (c) i don&#039;t need all of flade&#039;s features &#8212; the only physics i really need is gravity. i haven&#039;t looked at any of the code in flade&#8230;)</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=41</wfw:commentRSS>
	</item>
		<item>
		<title>ie7 wtf</title>
		<link>http://bunnyherolabs.com/tech/?p=39</link>
		<comments>http://bunnyherolabs.com/tech/?p=39#comments</comments>
		<pubDate>Mon, 06 Feb 2006 20:30:26 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>browsers</category>
		<guid>http://bunnyherolabs.com/tech/?p=39</guid>
		<description><![CDATA[	the microsoft IE7 team continues to make bizarre changes to the UI. now the menu bar is hidden by default!? and a new icontastic &#034;command bar&#034; has been added to replace it, on the right hand side of the window. way to go. i look at the screenshots and feel completely lost, as a user. [...]]]></description>
			<content:encoded><![CDATA[	<p><a href="http://blogs.msdn.com/ie/archive/2006/02/01/522737.aspx">the microsoft IE7 team continues to make bizarre changes to the UI.</a> now the menu bar is hidden by default!? and a new icontastic &#034;command bar&#034; has been added to replace it, on the right hand side of the window. way to go. i look at the screenshots and feel completely lost, as a user. of course you can bring the menu bar back (not sure how easy it is to find the option), but it&#039;s still stuck <em>under</em> the address bar.</p>
	<p>i have not yet installed the ie7 beta&#8230; i suppose i should at some point, for testing purposes, although i don&#039;t want to replace ie6, and i&#039;ve heard reports of systems becoming unstable or messed up when installing an unofficial standalone version of ie7 beta (i currently use standalone versions of older versions of IE without trouble, though). i should look at that more closely. i wonder if it&#039;d work better if ie7 was installed as the default system ie and ie6 was run as the standalone. hmmm.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=39</wfw:commentRSS>
	</item>
		<item>
		<title>akismet rules</title>
		<link>http://bunnyherolabs.com/tech/?p=38</link>
		<comments>http://bunnyherolabs.com/tech/?p=38#comments</comments>
		<pubDate>Fri, 30 Dec 2005 17:41:11 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>server misc</category>
		<guid>http://bunnyherolabs.com/tech/?p=38</guid>
		<description><![CDATA[	i installed the akismet anti-comment-spam plugin for wordpress a few days ago. so far it is working GREAT. i was getting pretty sick of tagging every spam entry in my moderation queue (there were a LOT), all while keeping an eye on legitimate comments.
	highly recommended!

]]></description>
			<content:encoded><![CDATA[	<p>i installed the <a href="http://akismet.com/">akismet</a> anti-comment-spam plugin for wordpress a few days ago. so far it is working GREAT. i was getting pretty sick of tagging every spam entry in my moderation queue (there were a LOT), all while keeping an eye on legitimate comments.</p>
	<p>highly recommended!
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=38</wfw:commentRSS>
	</item>
		<item>
		<title>load problem solved?</title>
		<link>http://bunnyherolabs.com/tech/?p=37</link>
		<comments>http://bunnyherolabs.com/tech/?p=37#comments</comments>
		<pubDate>Wed, 21 Dec 2005 18:32:12 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>httpd</category>
	<category>server misc</category>
		<guid>http://bunnyherolabs.com/tech/?p=37</guid>
		<description><![CDATA[	i spent most of tuesday messing around with various freeBSD and lighttpd settings. even though netstat -m didn&#039;t report insufficient buffers, i was getting no buffer space errors in my log files. so, i upped kern.ipc.nmbclusters from 6000-ish to 16000 and rebooted.
	the errors continued. however, netstat -an counted more connections before dying than before. hmmm&#8230;
	netstat [...]]]></description>
			<content:encoded><![CDATA[	<p>i spent most of tuesday messing around with various <a href="http://www.freebsd.org/">freeBSD</a> and <a href="http://www.lighttpd.net">lighttpd</a> settings. even though <code>netstat -m</code> didn&#039;t report insufficient buffers, i was getting <code>no buffer space</code> errors in my log files. so, i upped <code>kern.ipc.nmbclusters</code> from 6000-ish to 16000 and rebooted.</p>
	<p>the errors continued. however, <code>netstat -an</code> counted more connections before dying than before. hmmm&#8230;</p>
	<p>netstat also revealed that many, many, many of those connections were hanging around in the <code>TIME_WAIT</code> state. i googled that and found some articles about MSL and socket connections&#8230; to be honest i didn&#039;t understand it all, but it seemed that it was possible to reduce the amount of time that sockets remained in the TIME_WAIT state by changing the value of <code>net.inet.tcp.msl</code>. on freeBSD 4.10 the default value is 30000 (30 seconds), so i reduced it to 7500 (7.5 seconds). i understand that lowering it too much can have other consequences, like having old data from an old connection getting mixed up in a current stream?? i admit i am a TCP/IP newbie.</p>
	<p>anyway, i changed that value, and restarted the server. so far so good&#8230; the server seems to be handling the load quite nicely now, with no connection failed/buffer space errors. i don&#039;t know if increasing nmbclusters was necessary, but since things are working ok now i am just going to leave it there for now <img src='http://bunnyherolabs.com/tech/wp-images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=37</wfw:commentRSS>
	</item>
		<item>
		<title>lighttpd + fastCGI + freeBSD under high load?</title>
		<link>http://bunnyherolabs.com/tech/?p=36</link>
		<comments>http://bunnyherolabs.com/tech/?p=36#comments</comments>
		<pubDate>Mon, 19 Dec 2005 17:16:56 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>httpd</category>
	<category>server misc</category>
		<guid>http://bunnyherolabs.com/tech/?p=36</guid>
		<description><![CDATA[	lighttpd is great (serves a lot, quickly), but under very heavy load it seems to act rather erratically. i&#039;m not sure where the fault lies, though: in lighttpd, in fast-CGI (which is how lighttpd runs PHP), or in freeBSD, or some combination.
	the symptoms are error messages like this:
	2005-12-19 10:11:52: (mod_fastcgi.c.1561) connect failed: 242 Connection refused [...]]]></description>
			<content:encoded><![CDATA[	<p><a href="http://www.lighttpd.net/">lighttpd</a> is great (serves a lot, quickly), but under very heavy load it seems to act rather erratically. i&#039;m not sure where the fault lies, though: in lighttpd, in fast-CGI (which is how lighttpd runs PHP), or in freeBSD, or some combination.</p>
	<p>the symptoms are error messages like this:</p>
	<p><code>2005-12-19 10:11:52: (mod_fastcgi.c.1561) connect failed: 242 Connection refused 61 0 /tmp/php-fastcgi.socket-0<br />
2005-12-19 10:11:52: (mod_fastcgi.c.2663) socket failed: No buffer space available 263 4086<br />
2005-12-19 10:11:52: (mod_fastcgi.c.2663) socket failed: No buffer space available 263 4086<br />
2005-12-19 10:11:52: (mod_fastcgi.c.2663) socket failed: No buffer space available 263 4086</code></p>
	<p>&#034;no buffer space available&#034; is supposed to suggest that the system is running out of network buffers. running <code>netstat -m</code> should reveal that buffer memory was exhausted, but the results of netstat show:</p>
	<p><code>158/1552/18176 mbufs in use (current/peak/max):<br />
        127 mbufs allocated to data<br />
        31 mbufs allocated to packet headers<br />
74/496/4544 mbuf clusters in use (current/peak/max)<br />
1380 Kbytes allocated to network (10% of mb_map in use)<br />
0 requests for memory denied<br />
0 requests for memory delayed<br />
0 calls to protocol drain routines</code></p>
	<p>which says that there&#039;s plenty of buffer space&#8230;</p>
	<p>then there&#039;s <a href="http://trac.lighttpd.net/trac/ticket/369">this ticket</a> on the lighttpd bug tracker&#8230; the bug is old, since lighttpd no longer consumes 100% cpu, but it still becomes unresponsive and hangs under the same conditions.</p>
	<p>all in all i probably just need to add another server. i need to compile some statistics on exactly how many pets etc i serve up, but i stopped running a stats package on the image/swf servers because the log files were too large to analyze with the amount of RAM i&#039;ve got. i guess i can just grep -c something appropriate, or heck, even just count the # of lines with wc -l.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=36</wfw:commentRSS>
	</item>
		<item>
		<title>animated GIFs in PHP</title>
		<link>http://bunnyherolabs.com/tech/?p=35</link>
		<comments>http://bunnyherolabs.com/tech/?p=35#comments</comments>
		<pubDate>Mon, 05 Dec 2005 03:24:12 +0000</pubDate>
		<dc:creator>bunnyhero</dc:creator>
		
	<category>php</category>
		<guid>http://bunnyherolabs.com/tech/?p=35</guid>
		<description><![CDATA[	i&#039;ve started to look at imagemagick and the magickwand API for PHP. the docs are a little bit opaque, IMHO, but i did find the sample/demo PHP file, which is supposed to be included with the magickwand PHP distribution, but isn&#039;t.
	in any case, the demo file helps a lot.
	i&#039;m surprised i don&#039;t see more animated-GIF [...]]]></description>
			<content:encoded><![CDATA[	<p>i&#039;ve started to look at <a href="http://www.imagemagick.org/">imagemagick</a> and the magickwand API for PHP. the docs are a little bit opaque, IMHO, but i did find the <a href="http://www.imagestamper.com/magickwand/code.html">sample/demo PHP file</a>, which is supposed to be included with the magickwand PHP distribution, but isn&#039;t.</p>
	<p>in any case, the demo file helps a lot.</p>
	<p>i&#039;m surprised i don&#039;t see more animated-GIF generators online (maybe i&#039;m just not looking hard enough?). i may start generating animated GIFs instead of SWF files for things that don&#039;t require interaction&#8230; for example, the non-interactive versions of the pets, for sites that don&#039;t allow you to embed flash.</p>
	<p>[UPDATED: 2006-05-09: the link to the sample code is gone now. grr! and the README file in the magickwand for PHP archive refers to sample directories that don&#039;t exist. anyway, i have found <a href="http://www.php-editors.com/contest/resource/2/82-read.html">another location of the sample code</a>. i think i should make a local copy available here for future reference, in case that disappears too&#8230;]
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bunnyherolabs.com/tech/?feed=rss2&amp;p=35</wfw:commentRSS>
	</item>
	</channel>
</rss>
