<?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>Reanmachine.com</title>
	<atom:link href="http://www.reanmachine.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.reanmachine.com</link>
	<description>My own little world of nonsense</description>
	<lastBuildDate>Fri, 24 Oct 2008 11:15:55 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>CodeIgniter &amp; Some Plugs</title>
		<link>http://www.reanmachine.com/2008/10/24/codeigniter-some-plugs/</link>
		<comments>http://www.reanmachine.com/2008/10/24/codeigniter-some-plugs/#comments</comments>
		<pubDate>Fri, 24 Oct 2008 11:15:17 +0000</pubDate>
		<dc:creator>ReAn</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[codeigniter]]></category>
		<category><![CDATA[lanified]]></category>
		<category><![CDATA[missing the point]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[web development]]></category>

		<guid isPermaLink="false">http://www.reanmachine.com/2008/10/24/codeigniter-some-plugs/</guid>
		<description><![CDATA[CodeIgniter (Link) is a wonderfull Content Managment Framework developed as OSS by EllisLab. I stumbled upon this gem a couple years ago while looking for a set of libraries to begin the development of a website.
Recently I&#8217;ve published two websites LANified! &#38; Missing the Point using this framework and so far it&#8217;s not only aided [...]]]></description>
			<content:encoded><![CDATA[<p><strong>CodeIgniter</strong> <span style="font-size: 50%">(<a href="http://www.codeigniter.com/">Link</a>)</span> is a wonderfull <em>Content Managment Framework</em> developed as OSS by <a href="http://ellislab.com/">EllisLab</a>. I stumbled upon this gem a couple years ago while looking for a set of libraries to begin the development of a website.</p>
<p>Recently I&#8217;ve published two websites <a href="http://www.lanified.com/">LANified!</a> &amp; <a href="http://www.missing-point.com/">Missing the Point</a> using this framework and so far it&#8217;s not only aided in increasing the development speed, but has taught me a few things about web-development in the process.</p>
<p><span id="more-26"></span><br />
The most significant feature CodeIgniter (CI) offers over traditional php development is a robust MVC architecture. CI Splits the development of your site into Models (Data Access Objects), Views (Templates), and Controllers (Core Logic) which allows you to be very modular. You can easily access the code to display components of your site and change them without affecting how the data is gathered &#038; organized.</p>
<p>With this convention you can easily program logic &#038; data-access witha skeleton display and update it as your web-designer pushes new revisions of the site-design. Or if you&#8217;re doing it yourself, you can get a completely functional website before working on the design.</p>
<p>CI gives developers the tools to do what they need with tested standards and a flexible environment. You can write custom libraries &#038; plugins for the framework which expand it&#8217;s functionality greatly. This allows you to focus on the development of the site and not get stuck around that pesky SQL bug.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.reanmachine.com/2008/10/24/codeigniter-some-plugs/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Reanmachine.CommandLine Library Released!</title>
		<link>http://www.reanmachine.com/2008/05/26/reanmachinecommandline-library-released/</link>
		<comments>http://www.reanmachine.com/2008/05/26/reanmachinecommandline-library-released/#comments</comments>
		<pubDate>Tue, 27 May 2008 04:04:44 +0000</pubDate>
		<dc:creator>ReAn</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Reanmachine]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[gpl]]></category>
		<category><![CDATA[library]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.reanmachine.com/2008/05/26/reanmachinecommandline-library-released/</guid>
		<description><![CDATA[So today I&#8217;ve finally jumped through all the hoops I needed to actually push out my first little library. It&#8217;s rather small and simple at the moment, but this is just temporary. I decided I would do the ground work for software package releases on something small so I pushed this one out the door.
Check [...]]]></description>
			<content:encoded><![CDATA[<p>So today I&#8217;ve finally jumped through all the hoops I needed to actually push out my first little library. It&#8217;s rather small and simple at the moment, but this is just temporary. I decided I would do the ground work for software package releases on something small so I pushed this one out the door.</p>
<p>Check the project page out at:</p>
<p><a href="http://reanmachine.com/wiki/Software:Reanmachine.CommandLine">Project Page on Reanmachine.com Wiki</a></p>
<p>The wiki itself is still under development (and being used to write some of my class notes, heh) but most of the Software: Namespace is ready to roll.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.reanmachine.com/2008/05/26/reanmachinecommandline-library-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Memory Diagnostic &#8211; Getting errors?</title>
		<link>http://www.reanmachine.com/2008/03/24/memory-diagnostic-getting-errors/</link>
		<comments>http://www.reanmachine.com/2008/03/24/memory-diagnostic-getting-errors/#comments</comments>
		<pubDate>Mon, 24 Mar 2008 08:45:26 +0000</pubDate>
		<dc:creator>ReAn</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[diagnostics]]></category>
		<category><![CDATA[errors]]></category>
		<category><![CDATA[memory]]></category>

		<guid isPermaLink="false">http://www.reanmachine.com/?p=23</guid>
		<description><![CDATA[So I&#8217;ve been having some issues with my desktop machine as of late, been getting some elegant crashes (read: swift). Recently some of my apps have been catching thier crashes before they dump to the inevitable Dr. Watson, and complaining about memory errors: Pointers to unreferenced memory, inability to read from this memory, etc.
Anyway, unfortunately [...]]]></description>
			<content:encoded><![CDATA[<p>So I&#8217;ve been having some issues with my desktop machine as of late, been getting some elegant crashes (read: swift). Recently some of my apps have been catching thier crashes before they dump to the inevitable Dr. Watson, and complaining about memory errors: Pointers to unreferenced memory, inability to read from this memory, etc.</p>
<p>Anyway, unfortunately for me, the problem wasn&#8217;t in my memory, but this wonderfull excursion in computer diagnostic process has led me to a wonderfull tool which I&#8217;d love to share with the world.</p>
<p>It&#8217;s called Memtest86+</p>
<p><a href="http://www.memtest.org/">http://www.memtest.org/</a></p>
<p><span id="more-23"></span>Wonderfull little tool, you download a bootable image, comes in many formats including EXE for bootable USB Keys, and runs a full band of memory tests on your system memory, as well as dumping out some usefull metrics on your L1 and L2 cache.</p>
<p>Anyway, I suppose this post is more of a shout-out &#038; reccomendation for the software than anything else, so I will leave you all with this:</p>
<p>Memory problems? Getting errors? Get Memtest86+ !!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.reanmachine.com/2008/03/24/memory-diagnostic-getting-errors/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Depth of Field &#8211; Simplified</title>
		<link>http://www.reanmachine.com/2008/03/11/depth-of-field-simplified/</link>
		<comments>http://www.reanmachine.com/2008/03/11/depth-of-field-simplified/#comments</comments>
		<pubDate>Tue, 11 Mar 2008 19:03:04 +0000</pubDate>
		<dc:creator>ReAn</dc:creator>
				<category><![CDATA[Computers]]></category>
		<category><![CDATA[Graphics]]></category>
		<category><![CDATA[computer graphics]]></category>
		<category><![CDATA[depth of field]]></category>
		<category><![CDATA[multi-pass rendering]]></category>
		<category><![CDATA[opengl]]></category>
		<category><![CDATA[shaders]]></category>

		<guid isPermaLink="false">http://www.reanmachine.com/?p=21</guid>
		<description><![CDATA[What is depth of field? Depth of field is the simulation in 3D graphics of a lens-based camera. Conventional rendering techniques model a pinhole camera paradigm, this means that all aspects of the picture share the same level of focus (the entire picture is in focus). With a lens-based camera, the rendered image will have [...]]]></description>
			<content:encoded><![CDATA[<p>What is depth of field? Depth of field is the simulation in 3D graphics of a lens-based camera. Conventional rendering techniques model a pinhole camera paradigm, this means that all aspects of the picture share the same level of focus (the entire picture is in focus). With a lens-based camera, the rendered image will have varying levels of focus based on the &#8216;focus&#8217; of the lens. Since we&#8217;re not using a ray-tracing engine, it&#8217;s hard to approximate the effects of light bending through a lens in the projection phase of rendering so we can &#8216;fake&#8217; Depth of Field by breaking the problem down.<br />
<span id="more-21"></span><br />
<strong>The approach</strong></p>
<p>To simulate depth of field we will need to employ two advanced rendering techniques, the first is Vertex/Pixel Shaders, and the second is Multi-Pass Rendering. <strong>Vertex/Pixel (or Fragment) Shaders</strong> are small programs that run directly on the gpu over a specific set of data. A vertex shader is a program that&#8217;s run for every vertex it&#8217;s applied to. A Pixel (Fragment) shader is a program that runs for every &#8216;fragment&#8217; which is a visual body of pixels drawn to the buffer, this is usually interpolated accross every pixel. <strong>Multi-Pass Rendering</strong> is a technique in which we render the same scene multiple times per frame, with different effects and/or purposes and we merge the outputs in some fassion to provide the desired result.</p>
<p><strong>First Pass</strong></p>
<p>Firstly we need to render our scene, but this will be in pin-hole format, or completely in focus. We apply a Vertex/Fragment shader to all the objects in the scene, the purpose of this shader is to calculate the distance from the camera of each pixel and store the blurriness coefficient in the alpha channel of the scene. </p>
<p>The shader will need various inputs from the program, such as the camera location, the visual depth of the focus plane, the visual depth of the near focal plane, and the far focal plane. This will allow us to set up a gradient of blurriness between the focal plane and the far focal plane, likewise for the near focus plane.</p>
<p><code><br />
let fp = focal plane<br />
let ffp = far focal plane<br />
let nfp = near focal plane<br />
let d = distance from camera<br />
let b = blurriness</p>
<p>if (d > ffp OR d < nfp) { b = 1.0; }<br />
elseif (d > fp AND d < ffp)<br />
{<br />
  b = (d - fp) / (ffp - fp);<br />
}<br />
elseif (d < fp AND d > nfp)<br />
{<br />
  b = 1 - ( (d - nfp) / (fp - nfp) );<br />
}<br />
else<br />
{<br />
  b = 0;<br />
}<br />
</code></p>
<table border=0 cellspacing=0 cellpadding=2 align="center" width="100%">
<tr>
<td width="50%"><strong>Render Pass 1</strong></td>
<td width="50%"><strong>Render Pass 1 Alpha</strong></td>
</tr>
<tr>
<td><a href="http://www.reanmachine.com/content/img/dof/dof-pass1.jpg"><img src="http://www.reanmachine.com/content/img/dof/dof-pass1-tn.jpg" /></a></td>
<td><a href="http://www.reanmachine.com/content/img/dof/dof-pass1-alpha.jpg"><img src="http://www.reanmachine.com/content/img/dof/dof-pass1-alpha-tn.jpg" /></a></td>
</tr>
</table>
<p>After the pass is rendered, the framebuffer is copied into a texture while maintaining the alpha channel for use in pass 2.</p>
<p><strong>Second Pass</strong></p>
<p>The second pass we will render a single quad to the screen and apply the texture generated by the first pass with a second Vertex/Fragment Shader. We will only need to pass the texture and the max blurriness to this shader, the rest of the information is stored inside the texture.</p>
<p>For each pixel we construct a unit circle (1.0 pixels big) with a possion distrobution of a number of points. If you&#8217;re lazy you can use a fast-blur technique instead of gaussian by setting your unit points to:</p>
<p><em>(1, 0), (-1, 0), (0, 1), (0, -1), (0.4, 0.4), (-0.4, 0.4), (-0.4, -0.4), and (0.4, -0.4)</em>, this will give a good average 8-point sample.</p>
<p>We then take the texture coordinates of the pixel we&#8217;re looking at and for each sample in our list (possion or lazy) add sample-point * (blurriness * max_blurriness) to the texture coordinates and sample the texture @ the resulting pixel. The samples are all averaged and a resulting color pixel is generated and output at the original location.</p>
<p>This is a simple blurring technique. Where blurriness is 0, the sample unit circle is effectively multiplied by 0 and will yield the source pixel. Where blurriness is 1.0, the unit circle is multiplied by max_blurriness, and will expand the sample points to sample nearby pixels.</p>
<p>We run into one problem however, at the edge of a sharp foreground object, we will get bleed from the sharp object into the blurred background/foreground. To compete this, we test the blurriness of each sample point, if the blurriness difference between the source point and the sample point is greater than a set threshold, we discard the sample and replace it with a sample from the point we&#8217;re inspecting.</p>
<p><strong>2nd Pass:</strong><br />
<a href="http://www.reanmachine.com/content/img/dof/dof-pass2.jpg"><img src="http://www.reanmachine.com/content/img/dof/dof-pass2-tn.jpg" /></a></p>
<p>And there you have it, a 2-Pass Depth of Field technique.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.reanmachine.com/2008/03/11/depth-of-field-simplified/feed/</wfw:commentRss>
		<slash:comments>1509</slash:comments>
		</item>
	</channel>
</rss>
