<?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>My development blog &#187; Raytracing</title>
	<atom:link href="http://www.guztech.nl/wordpress/index.php/tag/raytracing/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.guztech.nl/wordpress</link>
	<description>Drifting in virtual reality...</description>
	<lastBuildDate>Sun, 01 Jan 2012 00:46:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>CUDA Raytracer update, now comes with OpenGL flavour</title>
		<link>http://www.guztech.nl/wordpress/index.php/2010/03/cuda-raytracer-update-now-comes-with-opengl-flavour/</link>
		<comments>http://www.guztech.nl/wordpress/index.php/2010/03/cuda-raytracer-update-now-comes-with-opengl-flavour/#comments</comments>
		<pubDate>Tue, 23 Mar 2010 18:57:09 +0000</pubDate>
		<dc:creator>oguz286</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[C++]]></category>
		<category><![CDATA[Cuda]]></category>
		<category><![CDATA[Raytracing]]></category>

		<guid isPermaLink="false">http://www.guztech.nl/wordpress/?p=86</guid>
		<description><![CDATA[Well I&#8217;ve been busy with my raytracer again and this time I added OpenGL support and a camera. What I do is: make an OpenGL pixel buffer bind it to CUDA run the raytracer kernel which fills the buffer give it back to OpenGL generate a texture from the buffer set up orthogonal view render [...]]]></description>
			<content:encoded><![CDATA[<p>Well I&#8217;ve been busy with my raytracer again and this time I added OpenGL support and a camera. What I do is:</p>
<ol>
<li>make an OpenGL pixel buffer</li>
<li>bind it to CUDA</li>
<li>run the raytracer kernel which fills the buffer</li>
<li>give it back to OpenGL</li>
<li>generate a texture from the buffer</li>
<li>set up orthogonal view</li>
<li>render a quad with the texture on it</li>
</ol>
<p>The results:</p>
<p><a href="http://www.guztech.nl/wordpress/wp-content/uploads/2010/03/cudatracer1.png"><img class="aligncenter size-medium wp-image-87" title="Cudatracer 1" src="http://www.guztech.nl/wordpress/wp-content/uploads/2010/03/cudatracer1-300x234.png" alt="Suzanne raytraced" width="300" height="234" /></a>and to show that the camera works (somewhat):</p>
<p><a href="http://www.guztech.nl/wordpress/wp-content/uploads/2010/03/cudatracer2.png"><img class="aligncenter size-medium wp-image-88" title="Cudatracer 2" src="http://www.guztech.nl/wordpress/wp-content/uploads/2010/03/cudatracer2-300x234.png" alt="Suzanne from a different angle" width="300" height="234" /></a>For those who want to combine CUDA and OpenGL is highly recommend watching <a title="What Every CUDA Programmer Needs to Know about OpenGL" href="http://nvidia.fullviewmedia.com/GPU2009/1001-valley-1055.html" target="_blank">this video</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.guztech.nl/wordpress/index.php/2010/03/cuda-raytracer-update-now-comes-with-opengl-flavour/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OguTracer</title>
		<link>http://www.guztech.nl/wordpress/index.php/2009/12/ogutracer/</link>
		<comments>http://www.guztech.nl/wordpress/index.php/2009/12/ogutracer/#comments</comments>
		<pubDate>Fri, 18 Dec 2009 19:20:29 +0000</pubDate>
		<dc:creator>oguz286</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[C++]]></category>
		<category><![CDATA[Cuda]]></category>
		<category><![CDATA[Raytracing]]></category>

		<guid isPermaLink="false">http://www.guztech.nl/wordpress/?p=8</guid>
		<description><![CDATA[My raytracer so far is very simple. It uses no acceleration structures and the scene is static. Earlier versions ran on the CPU, but now I use Cuda to use the enormous floating point processing power of my GPU which shortened my rendering times a lot. The raytracer loads a mesh from a 3DS Max [...]]]></description>
			<content:encoded><![CDATA[<p>My raytracer so far is very simple. It uses no acceleration structures and the scene is static. Earlier versions ran on the CPU, but now I use <a title="nVidia Cuda" href="http://www.nvidia.com/object/cuda_home.html" target="_blank">Cuda</a> to use the enormous floating point processing power of my GPU which shortened my rendering times a lot.</p>
<p>The raytracer loads a mesh from a 3DS Max  file, puts a &#8216;room&#8217; around it and renders the scene using only primary rays. Here is an example:</p>
<div id="attachment_9" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.guztech.nl/wordpress/wp-content/uploads/2009/12/output.jpg"><img class="size-medium wp-image-9" title="Raytracer output" src="http://www.guztech.nl/wordpress/wp-content/uploads/2009/12/output-300x225.jpg" alt="Raytracer output" width="300" height="225" /></a><p class="wp-caption-text">Raytracer output</p></div>
<p style="text-align: center;">
<p>The scene above consists of 1034 triangles and renders in 0.693 seconds on my Geforce 8600GT. My CPU needs around 10 seconds to render the same scene with the same detail so using the GPU is much faster.</p>
<p>Right now I&#8217;m in the process of implementing a BHV acceleration structure to make rendering faster. What it basically does is, it puts a bounding box around the mesh and then divides the mesh into two smaller bounding boxes. This process is repeated until some conditions are met (i.e. maximum depth reached) or when each bounding box contains a single traingle. This speeds up rendering because now the rays are checked against the bounding boxes instead of the triangles, and the bounding boxes that do not intersect with the ray don&#8217;t have to be checked.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.guztech.nl/wordpress/index.php/2009/12/ogutracer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

