<?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>Game Rendering &#187; DirectX</title>
	<atom:link href="http://www.gamerendering.com/tag/directx/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gamerendering.com</link>
	<description></description>
	<lastBuildDate>Thu, 21 Jan 2010 01:32:12 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Great free graphics programming books!</title>
		<link>http://www.gamerendering.com/2009/12/10/great-free-graphics-programming-books/</link>
		<comments>http://www.gamerendering.com/2009/12/10/great-free-graphics-programming-books/#comments</comments>
		<pubDate>Thu, 10 Dec 2009 12:25:18 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Books]]></category>
		<category><![CDATA[DirectX]]></category>
		<category><![CDATA[Geometry Shader]]></category>
		<category><![CDATA[GPU]]></category>
		<category><![CDATA[OpenGL]]></category>
		<category><![CDATA[Pixel Shader]]></category>
		<category><![CDATA[Shaders]]></category>
		<category><![CDATA[Vertex Shader]]></category>

		<guid isPermaLink="false">http://www.gamerendering.com/?p=769</guid>
		<description><![CDATA[Here is a list of good books that all graphics programmer&#8217;s should read. They are a little dated now, but FREE!
     

       

     

    


Feel free to mention in the comments if you know other free books online.



Please share:


	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	


]]></description>
			<content:encoded><![CDATA[<p>Here is a list of good books that all graphics programmer&#8217;s should read. They are a little dated now, but <strong>FREE</strong>!</p>
<p><a href="http://wiki.gamedev.net/index.php/D3DBook:Book_Cover"></a><a href="http://wiki.gamedev.net/index.php/D3DBook:Book_Cover"><img class="alignnone size-medium wp-image-785" title="Programming Vertex, Geometry, and Pixel Shaders" src="http://www.gamerendering.com/wp-content/uploads/programmingVGPS2-317x400.jpg" alt="Programming Vertex, Geometry, and Pixel Shaders" width="222" height="280" /></a>     <a href="http://tog.acm.org/resources/shaderx/Direct3D.ShaderX.Vertex.and.Pixel.Shader.Tips.and.Tricks_Wolfgang.F.Engel_Wordware.Pub_2002.pdf"><img class="size-medium wp-image-770" title="ShaderX1" src="http://www.gamerendering.com/wp-content/uploads/ShaderX1-320x400.jpg" alt="ShaderX1" width="205" height="256" /></a></p>
<div class="mceTemp"><a href="http://tog.acm.org/resources/shaderx/Direct3D.ShaderX.Vertex.and.Pixel.Shader.Tips.and.Tricks_Wolfgang.F.Engel_Wordware.Pub_2002.pdf"></a></div>
<div class="mceTemp"><a href="http://tog.acm.org/resources/shaderx/Introductions_and_Tutorials_with_DirectX_9.pdf"><img class="size-medium wp-image-771" title="ShaderX2" src="http://www.gamerendering.com/wp-content/uploads/ShaderX2-264x400.jpg" alt="ShaderX2" width="214" height="324" /></a>       <a href="http://tog.acm.org/resources/shaderx/Tips_and_Tricks_with_DirectX_9.pdf"><img class="alignnone size-full wp-image-772" title="ShaderX2" src="http://www.gamerendering.com/wp-content/uploads/ShaderX2b.jpg" alt="ShaderX2" width="200" height="301" /></a></div>
<div class="mceTemp"><a href="http://tog.acm.org/resources/shaderx/Tips_and_Tricks_with_DirectX_9.pdf"></a></div>
<div class="mceTemp"><a href="http://http.developer.nvidia.com/CgTutorial/cg_tutorial_chapter01.html"><img class="alignnone size-medium wp-image-777" title="CgTutorial" src="http://www.gamerendering.com/wp-content/uploads/CgTutorial-319x400.jpg" alt="CgTutorial" width="230" height="288" /></a>     <a href="http://http.developer.nvidia.com/GPUGems/gpugems_part01.html"><img class="alignnone size-medium wp-image-778" title="GPU Gems" src="http://www.gamerendering.com/wp-content/uploads/GPUGems1-319x400.jpg" alt="GPU Gems" width="223" height="280" /></a></div>
<div class="mceTemp"><a href="http://http.developer.nvidia.com/GPUGems/gpugems_part01.html"></a></div>
<div class="mceTemp"><a href="http://http.developer.nvidia.com/GPUGems2/gpugems2_part01.html"><img class="alignnone size-medium wp-image-779" title="GPU Gems 2" src="http://www.gamerendering.com/wp-content/uploads/GPUGems2-313x400.jpg" alt="GPU Gems 2" width="200" height="256" /></a>    <a href="http://http.developer.nvidia.com/GPUGems3/gpugems3_part01.html"><img class="alignnone size-medium wp-image-780" title="GPU Gems 3" src="http://www.gamerendering.com/wp-content/uploads/GPUGems3-317x400.jpg" alt="GPU Gems 3" width="222" height="280" /></a></div>
<div class="mceTemp"><a href="http://http.developer.nvidia.com/GPUGems3/gpugems3_part01.html"></a></div>
<div class="mceTemp"><a href="http://www.glprogramming.com/red/"></a></div>
<div class="mceTemp"><em>Feel free to mention in the comments if you know other free books online.</em></div>

<div class="sociable">
<div class="sociable_tagline">
<strong>Please share:</strong>
</div>
<ul>
	<li class="sociablefirst"><a rel="nofollow" id="print" href="javascript:window.location='http%3A%2F%2Fwww.printfriendly.com%2Fprint%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Bpartner%3Dsociable';" title="Print this article!"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/printfriendly.png" title="Print this article!" alt="Print this article!" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="digg" href="javascript:window.location='http%3A%2F%2Fdigg.com%2Fsubmit%3Fphase%3D2%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26amp%3Bbodytext%3DHere%2520is%2520a%2520list%2520of%2520good%2520books%2520that%2520all%2520graphics%2520programmer%2527s%2520should%2520read.%2520They%2520are%2520a%2520little%2520dated%2520now%252C%2520but%2520FREE%2521%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%250D%250AFeel%2520free%2520to%2520mention%2520in%2520the%2520comments%2520if%2520you%2520know%2520other%2520free%2520books%2520online.';" title="Digg"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="sphinn" href="javascript:window.location='http%3A%2F%2Fsphinn.com%2Findex.php%3Fc%3Dpost%26m%3Dsubmit%26link%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F';" title="Sphinn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="del.icio.us" href="javascript:window.location='http%3A%2F%2Fdelicious.com%2Fpost%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26amp%3Bnotes%3DHere%2520is%2520a%2520list%2520of%2520good%2520books%2520that%2520all%2520graphics%2520programmer%2527s%2520should%2520read.%2520They%2520are%2520a%2520little%2520dated%2520now%252C%2520but%2520FREE%2521%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%250D%250AFeel%2520free%2520to%2520mention%2520in%2520the%2520comments%2520if%2520you%2520know%2520other%2520free%2520books%2520online.';" title="del.icio.us"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="facebook" href="javascript:window.location='http%3A%2F%2Fwww.facebook.com%2Fshare.php%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Bt%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="Facebook"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="mixx" href="javascript:window.location='http%3A%2F%2Fwww.mixx.com%2Fsubmit%3Fpage_url%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="Mixx"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="google" href="javascript:window.location='http%3A%2F%2Fwww.google.com%2Fbookmarks%2Fmark%3Fop%3Dedit%26amp%3Bbkmk%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26amp%3Bannotation%3DHere%2520is%2520a%2520list%2520of%2520good%2520books%2520that%2520all%2520graphics%2520programmer%2527s%2520should%2520read.%2520They%2520are%2520a%2520little%2520dated%2520now%252C%2520but%2520FREE%2521%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%250D%250AFeel%2520free%2520to%2520mention%2520in%2520the%2520comments%2520if%2520you%2520know%2520other%2520free%2520books%2520online.';" title="Google Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="current" href="javascript:window.location='http%3A%2F%2Fcurrent.com%2Fclipper.htm%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="Current"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/current.png" title="Current" alt="Current" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="linkedin" href="javascript:window.location='http%3A%2F%2Fwww.linkedin.com%2FshareArticle%3Fmini%3Dtrue%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26amp%3Bsource%3DGame%2BRendering%2B%26amp%3Bsummary%3DHere%2520is%2520a%2520list%2520of%2520good%2520books%2520that%2520all%2520graphics%2520programmer%2527s%2520should%2520read.%2520They%2520are%2520a%2520little%2520dated%2520now%252C%2520but%2520FREE%2521%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%250D%250AFeel%2520free%2520to%2520mention%2520in%2520the%2520comments%2520if%2520you%2520know%2520other%2520free%2520books%2520online.';" title="LinkedIn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="live" href="javascript:window.location='https%3A%2F%2Ffavorites.live.com%2Fquickadd.aspx%3Fmarklet%3D1%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="Live"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="myspace" href="javascript:window.location='http%3A%2F%2Fwww.myspace.com%2FModules%2FPostTo%2FPages%2F%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Bt%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="MySpace"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/myspace.png" title="MySpace" alt="MySpace" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="netvibes" href="javascript:window.location='http%3A%2F%2Fwww.netvibes.com%2Fshare%3Ftitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F';" title="Netvibes"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="stumbleupon" href="javascript:window.location='http%3A%2F%2Fwww.stumbleupon.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="StumbleUpon"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="twitter" href="javascript:window.location='http%3A%2F%2Ftwitter.com%2Fhome%3Fstatus%3DGreat%2520free%2520graphics%2520programming%2520books%2521%2520-%2520http%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F';" title="Twitter"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="reddit" href="javascript:window.location='http%3A%2F%2Freddit.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Btitle%3DGreat%2520free%2520graphics%2520programming%2520books%2521';" title="Reddit"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="technorati" href="javascript:window.location='http%3A%2F%2Ftechnorati.com%2Ffaves%3Fadd%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F';" title="Technorati"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" class="sociable-hovers" /></a></li>
	<li class="sociablelast"><a rel="nofollow" id="yahoo! bookmarks" href="javascript:window.location='http%3A%2F%2Fbookmarks.yahoo.com%2Ftoolbar%2Fsavebm%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F10%252Fgreat-free-graphics-programming-books%252F%26amp%3Bt%3DGreat%2520free%2520graphics%2520programming%2520books%2521%26opener%3Dbm%26amp%3Bei%3DUTF-8%26amp%3Bd%3DHere%2520is%2520a%2520list%2520of%2520good%2520books%2520that%2520all%2520graphics%2520programmer%2527s%2520should%2520read.%2520They%2520are%2520a%2520little%2520dated%2520now%252C%2520but%2520FREE%2521%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%25C2%25A0%25C2%25A0%25C2%25A0%2520%250D%250A%250D%250A%250D%250AFeel%2520free%2520to%2520mention%2520in%2520the%2520comments%2520if%2520you%2520know%2520other%2520free%2520books%2520online.';" title="Yahoo! Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/yahoomyweb.png" title="Yahoo! Bookmarks" alt="Yahoo! Bookmarks" class="sociable-hovers" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerendering.com/2009/12/10/great-free-graphics-programming-books/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>VPOS</title>
		<link>http://www.gamerendering.com/2009/12/07/vpos/</link>
		<comments>http://www.gamerendering.com/2009/12/07/vpos/#comments</comments>
		<pubDate>Mon, 07 Dec 2009 15:35:38 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Shaders]]></category>
		<category><![CDATA[DirectX]]></category>
		<category><![CDATA[Game]]></category>
		<category><![CDATA[Pixel Shader]]></category>
		<category><![CDATA[Render-to-Texture]]></category>
		<category><![CDATA[Rendering]]></category>
		<category><![CDATA[SM3]]></category>
		<category><![CDATA[VPOS]]></category>

		<guid isPermaLink="false">http://www.gamerendering.com/?p=735</guid>
		<description><![CDATA[Starting with DirectX Pixel Shader Model 3.0 there exist an input type called VPOS. It&#8217;s the current pixels position on the screen and it&#8217;s automatically generated. This can be useful when sampling from a previously rendered texture when rendering an arbitrarily shaped mesh to the screen. To do this, we need uv-coords that represents where [...]]]></description>
			<content:encoded><![CDATA[<p>Starting with DirectX Pixel Shader Model 3.0 there exist an input type called VPOS. It&#8217;s the current pixels position on the screen and it&#8217;s automatically generated. This can be useful when sampling from a previously rendered texture when rendering an arbitrarily shaped mesh to the screen. To do this, we need uv-coords that represents where to sample on the texture. These coordinates can be gained by simply dividing VPOS with the screen dimensions.<br />
When working with older hardware, that doesn&#8217;t support shader model 3.0, there is a need to manually create the VPOS in the vertex shader and pass it to the fragment shader as a TEXCOORD. This is the way to do so ( including the scaling to uv-range which manually has to be done for VPOS if you&#8217;re using it).</p>
<p><strong>Vertex Shader:</strong></p>

<div class="wp_codebox"><table width="100%" ><tr id="p7355"><td class="code" id="p735code5"><pre class="c" style="font-family:monospace;">float4x4 matWorldViewProjection<span style="color: #339933;">;</span>
float2 fInverseViewportDimensions<span style="color: #339933;">;</span>
<span style="color: #993333;">struct</span> VS_INPUT
<span style="color: #009900;">&#123;</span>
   float4 Position <span style="color: #339933;">:</span> POSITION0<span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
<span style="color: #993333;">struct</span> VS_OUTPUT
<span style="color: #009900;">&#123;</span>
   float4 Position <span style="color: #339933;">:</span> POSITION0<span style="color: #339933;">;</span>
   float4 calculatedVPos <span style="color: #339933;">:</span> TEXCOORD0<span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
float4 ConvertToVPos<span style="color: #009900;">&#40;</span> float4 p <span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
   <span style="color: #b1b100;">return</span> float4<span style="color: #009900;">&#40;</span> <span style="color:#800080;">0.5</span><span style="color: #339933;">*</span><span style="color: #009900;">&#40;</span> float2<span style="color: #009900;">&#40;</span>p.<span style="color: #202020;">x</span> <span style="color: #339933;">+</span> p.<span style="color: #202020;">w</span><span style="color: #339933;">,</span> p.<span style="color: #202020;">w</span> <span style="color: #339933;">-</span> p.<span style="color: #202020;">y</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> p.<span style="color: #202020;">w</span><span style="color: #339933;">*</span>fInverseViewportDimensions.<span style="color: #202020;">xy</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> p.<span style="color: #202020;">zw</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
VS_OUTPUT vs_main<span style="color: #009900;">&#40;</span> VS_INPUT Input <span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
   VS_OUTPUT Output<span style="color: #339933;">;</span>
   Output.<span style="color: #202020;">Position</span> <span style="color: #339933;">=</span> mul<span style="color: #009900;">&#40;</span> Input.<span style="color: #202020;">Position</span><span style="color: #339933;">,</span> matWorldViewProjection <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
   Output.<span style="color: #202020;">calculatedVPos</span> <span style="color: #339933;">=</span> ConvertToVPos<span style="color: #009900;">&#40;</span>Output.<span style="color: #202020;">Position</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
   <span style="color: #b1b100;">return</span><span style="color: #009900;">&#40;</span> Output <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p><strong>Pixel Shader:<br />
</strong></p>

<div class="wp_codebox"><table width="100%" ><tr id="p7356"><td class="code" id="p735code6"><pre class="c" style="font-family:monospace;">float4 ps_main<span style="color: #009900;">&#40;</span>VS_OUTPUT Input<span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> COLOR0
<span style="color: #009900;">&#123;</span>
   Input.<span style="color: #202020;">calculatedVPos</span> <span style="color: #339933;">/=</span> Input.<span style="color: #202020;">calculatedVPos</span>.<span style="color: #202020;">w</span><span style="color: #339933;">;</span>
   <span style="color: #b1b100;">return</span> float4<span style="color: #009900;">&#40;</span>Input.<span style="color: #202020;">calculatedVPos</span>.<span style="color: #202020;">xy</span><span style="color: #339933;">,</span><span style="color: #0000dd;">0</span><span style="color: #339933;">,</span><span style="color: #0000dd;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// test render it to the screen</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>The image below shows an elephant model rendered with the shader above. As can be seen, the color (red and green channels) correctly represents the uv-coords for a fullscreen quad. Since 0,0,0 = black, 1,0,0 = red, 0,1,0 = green, 1, 1,0 = yellow.</p>
<div class="mceTemp"><a href="http://www.gamerendering.com/wp-content/uploads/vPosElephant.JPG"><img class="size-full wp-image-736" title="VPOS Elephant" src="http://www.gamerendering.com/wp-content/uploads/vPosElephant.JPG" alt="VPOS Elephant" width="177" height="162" /></a></div>
<div class="mceTemp">This is how the pixel shader would have looked like if VPOS were used instead (note: no special vertex shader needed in this case).</div>

<div class="wp_codebox"><table width="100%" ><tr id="p7357"><td class="code" id="p735code7"><pre class="c" style="font-family:monospace;"><span style="color: #993333;">struct</span> PS_INPUT
<span style="color: #009900;">&#123;</span>
   float2 vPos <span style="color: #339933;">:</span> VPOS<span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>


<div class="wp_codebox"><table width="100%" ><tr id="p7358"><td class="code" id="p735code8"><pre class="c" style="font-family:monospace;">float4 ps_main<span style="color: #009900;">&#40;</span>PS_INPUT Input<span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> COLOR0
<span style="color: #009900;">&#123;</span>
   <span style="color: #b1b100;">return</span> float4<span style="color: #009900;">&#40;</span>Input.<span style="color: #202020;">vPos</span><span style="color: #339933;">*</span>fInverseViewportDimensions <span style="color: #339933;">+</span> fInverseViewportDimensions<span style="color: #339933;">*</span><span style="color:#800080;">0.5</span><span style="color: #339933;">,</span><span style="color: #0000dd;">0</span><span style="color: #339933;">,</span><span style="color: #0000dd;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// test render it to the screen</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>The original code, more info and proof can be found here:<br />
<a href="http://www.gamedev.net/community/forums/topic.asp?topic_id=506573">http://www.gamedev.net/community/forums/topic.asp?topic_id=506573</a></p>

<div class="sociable">
<div class="sociable_tagline">
<strong>Please share:</strong>
</div>
<ul>
	<li class="sociablefirst"><a rel="nofollow" id="print" href="javascript:window.location='http%3A%2F%2Fwww.printfriendly.com%2Fprint%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Bpartner%3Dsociable';" title="Print this article!"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/printfriendly.png" title="Print this article!" alt="Print this article!" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="digg" href="javascript:window.location='http%3A%2F%2Fdigg.com%2Fsubmit%3Fphase%3D2%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS%26amp%3Bbodytext%3DStarting%2520with%2520DirectX%2520Pixel%2520Shader%2520Model%25203.0%2520there%2520exist%2520an%2520input%2520type%2520called%2520VPOS.%2520It%2527s%2520the%2520current%2520pixels%2520position%2520on%2520the%2520screen%2520and%2520it%2527s%2520automatically%2520generated.%2520This%2520can%2520be%2520useful%2520when%2520sampling%2520from%2520a%2520previously%2520rendered%2520texture%2520when%2520rendering%2520an';" title="Digg"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="sphinn" href="javascript:window.location='http%3A%2F%2Fsphinn.com%2Findex.php%3Fc%3Dpost%26m%3Dsubmit%26link%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F';" title="Sphinn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="del.icio.us" href="javascript:window.location='http%3A%2F%2Fdelicious.com%2Fpost%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS%26amp%3Bnotes%3DStarting%2520with%2520DirectX%2520Pixel%2520Shader%2520Model%25203.0%2520there%2520exist%2520an%2520input%2520type%2520called%2520VPOS.%2520It%2527s%2520the%2520current%2520pixels%2520position%2520on%2520the%2520screen%2520and%2520it%2527s%2520automatically%2520generated.%2520This%2520can%2520be%2520useful%2520when%2520sampling%2520from%2520a%2520previously%2520rendered%2520texture%2520when%2520rendering%2520an';" title="del.icio.us"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="facebook" href="javascript:window.location='http%3A%2F%2Fwww.facebook.com%2Fshare.php%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Bt%3DVPOS';" title="Facebook"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="mixx" href="javascript:window.location='http%3A%2F%2Fwww.mixx.com%2Fsubmit%3Fpage_url%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS';" title="Mixx"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="google" href="javascript:window.location='http%3A%2F%2Fwww.google.com%2Fbookmarks%2Fmark%3Fop%3Dedit%26amp%3Bbkmk%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS%26amp%3Bannotation%3DStarting%2520with%2520DirectX%2520Pixel%2520Shader%2520Model%25203.0%2520there%2520exist%2520an%2520input%2520type%2520called%2520VPOS.%2520It%2527s%2520the%2520current%2520pixels%2520position%2520on%2520the%2520screen%2520and%2520it%2527s%2520automatically%2520generated.%2520This%2520can%2520be%2520useful%2520when%2520sampling%2520from%2520a%2520previously%2520rendered%2520texture%2520when%2520rendering%2520an';" title="Google Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="current" href="javascript:window.location='http%3A%2F%2Fcurrent.com%2Fclipper.htm%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS';" title="Current"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/current.png" title="Current" alt="Current" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="linkedin" href="javascript:window.location='http%3A%2F%2Fwww.linkedin.com%2FshareArticle%3Fmini%3Dtrue%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS%26amp%3Bsource%3DGame%2BRendering%2B%26amp%3Bsummary%3DStarting%2520with%2520DirectX%2520Pixel%2520Shader%2520Model%25203.0%2520there%2520exist%2520an%2520input%2520type%2520called%2520VPOS.%2520It%2527s%2520the%2520current%2520pixels%2520position%2520on%2520the%2520screen%2520and%2520it%2527s%2520automatically%2520generated.%2520This%2520can%2520be%2520useful%2520when%2520sampling%2520from%2520a%2520previously%2520rendered%2520texture%2520when%2520rendering%2520an';" title="LinkedIn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="live" href="javascript:window.location='https%3A%2F%2Ffavorites.live.com%2Fquickadd.aspx%3Fmarklet%3D1%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS';" title="Live"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="myspace" href="javascript:window.location='http%3A%2F%2Fwww.myspace.com%2FModules%2FPostTo%2FPages%2F%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Bt%3DVPOS';" title="MySpace"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/myspace.png" title="MySpace" alt="MySpace" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="netvibes" href="javascript:window.location='http%3A%2F%2Fwww.netvibes.com%2Fshare%3Ftitle%3DVPOS%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F';" title="Netvibes"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="stumbleupon" href="javascript:window.location='http%3A%2F%2Fwww.stumbleupon.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS';" title="StumbleUpon"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="twitter" href="javascript:window.location='http%3A%2F%2Ftwitter.com%2Fhome%3Fstatus%3DVPOS%2520-%2520http%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F';" title="Twitter"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="reddit" href="javascript:window.location='http%3A%2F%2Freddit.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Btitle%3DVPOS';" title="Reddit"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="technorati" href="javascript:window.location='http%3A%2F%2Ftechnorati.com%2Ffaves%3Fadd%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F';" title="Technorati"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" class="sociable-hovers" /></a></li>
	<li class="sociablelast"><a rel="nofollow" id="yahoo! bookmarks" href="javascript:window.location='http%3A%2F%2Fbookmarks.yahoo.com%2Ftoolbar%2Fsavebm%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F12%252F07%252Fvpos%252F%26amp%3Bt%3DVPOS%26opener%3Dbm%26amp%3Bei%3DUTF-8%26amp%3Bd%3DStarting%2520with%2520DirectX%2520Pixel%2520Shader%2520Model%25203.0%2520there%2520exist%2520an%2520input%2520type%2520called%2520VPOS.%2520It%2527s%2520the%2520current%2520pixels%2520position%2520on%2520the%2520screen%2520and%2520it%2527s%2520automatically%2520generated.%2520This%2520can%2520be%2520useful%2520when%2520sampling%2520from%2520a%2520previously%2520rendered%2520texture%2520when%2520rendering%2520an';" title="Yahoo! Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/yahoomyweb.png" title="Yahoo! Bookmarks" alt="Yahoo! Bookmarks" class="sociable-hovers" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerendering.com/2009/12/07/vpos/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Soft Particles</title>
		<link>http://www.gamerendering.com/2009/09/16/soft-particles/</link>
		<comments>http://www.gamerendering.com/2009/09/16/soft-particles/#comments</comments>
		<pubDate>Wed, 16 Sep 2009 07:26:44 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Particle Systems]]></category>
		<category><![CDATA[3D Engine]]></category>
		<category><![CDATA[Depth map]]></category>
		<category><![CDATA[DirectX]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Nvidia]]></category>
		<category><![CDATA[Particle System]]></category>
		<category><![CDATA[Soft Particles]]></category>

		<guid isPermaLink="false">http://www.gamerendering.com/?p=686</guid>
		<description><![CDATA[
The aim with soft particles is to remove the ugly artifact that appears when the particle quad intersects the scene. There are a lot of different approaches to solve this, some more complicate than others. The simplest formula for soft particles is to just fade the particle if it&#8217;s getting to close to the scene. [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.gamerendering.com/wp-content/uploads/artifacts_visible.jpg"><img class="size-full wp-image-689" title="Normal particles on the left, soft particles on the right" src="http://www.gamerendering.com/wp-content/uploads/artifacts_visible.jpg" alt="Normal particles on the left, soft particles on the right" width="379" height="187" /></a></p>
<p>The aim with soft particles is to remove the ugly artifact that appears when the particle quad intersects the scene. There are a lot of different approaches to solve this, some more complicate than others. The simplest formula for soft particles is to just fade the particle if it&#8217;s getting to close to the scene. To do this, the scene without particles has to be rendered first and the depth saved in a texture. When drawing the particles, the depth of the particle will be compared to the scene depth. The alpha should be increased by a smooth fade by this depth difference. The formula below in HLSL is the simplest possible for soft particles, and works very well. Scene_depth is the sampled depth (in viewspace) of the scene in the direction of the current pixel. Particle_depth is the depth(in viewspace) of the current particle pixel. Scale is used to control the “softness” of the intersection between particles and scene:</p>
<p>fade = saturate((scene_depth – particle_depth) * scale);</p>
<p>NVIDIA [1] proposes a method that the following fade should be used instead of the linear one described above, to make the fade even smoother.</p>
<p>float Output = 0.5*pow(saturate(2*(( Input &gt; 0.5) ? 1-Input : Input)), ContrastPower);<br />
Output = ( Input &gt; 0.5) ? 1-Output : Output;</p>
<p>Umenhoffer [2] proposes a method called spherical billboards to deal with these problems. In this method, the volume is approximated by a sphere. This method also deals with the near clipplane problem that particles will instantly disappear if they get to close to the camera.</p>
<p>There is also an idea [3] that the alpha channel can be used to represent the density of the particles. Although this method has the drawback that the textures might need to be redone by the artists.</p>
<p>The method by Microsoft [4] uses a combination of spherical billboards and a texture representation of the volume. But instead of using the alpha channel, they ray march the sphere and sample the density and volume from a 3D noise texture. The result can be seen in the image below.</p>
<div class="mceTemp"><a href="http://www.gamerendering.com/wp-content/uploads/microsoft_soft_particles.jpg"><img class="size-medium wp-image-690" title="Volumetric Particles" src="http://www.gamerendering.com/wp-content/uploads/microsoft_soft_particles-400x290.jpg" alt="Volumetric Particles" width="400" height="290" /></a></div>
<p>The video below shows how soft shadows can increase realism in games using large particles. It&#8217;s originally an ad for Torque 3D engine.</p>
<div class="mceTemp"><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="400" height="225" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=3538630&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed type="application/x-shockwave-flash" width="400" height="225" src="http://vimeo.com/moogaloop.swf?clip_id=3538630&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" allowfullscreen="true" allowscriptaccess="always"></embed></object></div>
<p>[1] Soft Particles by NVIDIA<br />
<a href="http://developer.download.nvidia.com/whitepapers/2007/SDK10/SoftParticles_hi.pdf">http://developer.download.nvidia.com/whitepapers/2007/SDK10/SoftParticles_hi.pdf</a></p>
<p>[2] Spherical Billboards and their Application to Rendering Explosions<br />
<a href="http://www.iit.bme.hu/~szirmay/firesmoke.pdf">http://www.iit.bme.hu/~szirmay/firesmoke.pdf</a></p>
<p>[3] A Gamasutra article about soft particles<br />
<a href="http://www.gamasutra.com/view/feature/3680/a_more_accurate_volumetric_.php">http://www.gamasutra.com/view/feature/3680/a_more_accurate_volumetric_.php</a></p>
<p>[4] A DirectX 10 implementation of soft particles by Microsoft, called Volumetric Particles<br />
<a href="http://msdn.microsoft.com/en-us/library/bb172449(VS.85).aspx">http://msdn.microsoft.com/en-us/library/bb172449(VS.85).aspx</a></p>
<p>s683fcw9dj</p>

<div class="sociable">
<div class="sociable_tagline">
<strong>Please share:</strong>
</div>
<ul>
	<li class="sociablefirst"><a rel="nofollow" id="print" href="javascript:window.location='http%3A%2F%2Fwww.printfriendly.com%2Fprint%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Bpartner%3Dsociable';" title="Print this article!"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/printfriendly.png" title="Print this article!" alt="Print this article!" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="digg" href="javascript:window.location='http%3A%2F%2Fdigg.com%2Fsubmit%3Fphase%3D2%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles%26amp%3Bbodytext%3D%250D%250A%250D%250AThe%2520aim%2520with%2520soft%2520particles%2520is%2520to%2520remove%2520the%2520ugly%2520artifact%2520that%2520appears%2520when%2520the%2520particle%2520quad%2520intersects%2520the%2520scene.%2520There%2520are%2520a%2520lot%2520of%2520different%2520approaches%2520to%2520solve%2520this%252C%2520some%2520more%2520complicate%2520than%2520others.%2520The%2520simplest%2520formula%2520for%2520soft%2520particles%2520';" title="Digg"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="sphinn" href="javascript:window.location='http%3A%2F%2Fsphinn.com%2Findex.php%3Fc%3Dpost%26m%3Dsubmit%26link%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F';" title="Sphinn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="del.icio.us" href="javascript:window.location='http%3A%2F%2Fdelicious.com%2Fpost%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles%26amp%3Bnotes%3D%250D%250A%250D%250AThe%2520aim%2520with%2520soft%2520particles%2520is%2520to%2520remove%2520the%2520ugly%2520artifact%2520that%2520appears%2520when%2520the%2520particle%2520quad%2520intersects%2520the%2520scene.%2520There%2520are%2520a%2520lot%2520of%2520different%2520approaches%2520to%2520solve%2520this%252C%2520some%2520more%2520complicate%2520than%2520others.%2520The%2520simplest%2520formula%2520for%2520soft%2520particles%2520';" title="del.icio.us"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="facebook" href="javascript:window.location='http%3A%2F%2Fwww.facebook.com%2Fshare.php%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Bt%3DSoft%2520Particles';" title="Facebook"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="mixx" href="javascript:window.location='http%3A%2F%2Fwww.mixx.com%2Fsubmit%3Fpage_url%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles';" title="Mixx"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="google" href="javascript:window.location='http%3A%2F%2Fwww.google.com%2Fbookmarks%2Fmark%3Fop%3Dedit%26amp%3Bbkmk%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles%26amp%3Bannotation%3D%250D%250A%250D%250AThe%2520aim%2520with%2520soft%2520particles%2520is%2520to%2520remove%2520the%2520ugly%2520artifact%2520that%2520appears%2520when%2520the%2520particle%2520quad%2520intersects%2520the%2520scene.%2520There%2520are%2520a%2520lot%2520of%2520different%2520approaches%2520to%2520solve%2520this%252C%2520some%2520more%2520complicate%2520than%2520others.%2520The%2520simplest%2520formula%2520for%2520soft%2520particles%2520';" title="Google Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="current" href="javascript:window.location='http%3A%2F%2Fcurrent.com%2Fclipper.htm%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles';" title="Current"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/current.png" title="Current" alt="Current" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="linkedin" href="javascript:window.location='http%3A%2F%2Fwww.linkedin.com%2FshareArticle%3Fmini%3Dtrue%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles%26amp%3Bsource%3DGame%2BRendering%2B%26amp%3Bsummary%3D%250D%250A%250D%250AThe%2520aim%2520with%2520soft%2520particles%2520is%2520to%2520remove%2520the%2520ugly%2520artifact%2520that%2520appears%2520when%2520the%2520particle%2520quad%2520intersects%2520the%2520scene.%2520There%2520are%2520a%2520lot%2520of%2520different%2520approaches%2520to%2520solve%2520this%252C%2520some%2520more%2520complicate%2520than%2520others.%2520The%2520simplest%2520formula%2520for%2520soft%2520particles%2520';" title="LinkedIn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="live" href="javascript:window.location='https%3A%2F%2Ffavorites.live.com%2Fquickadd.aspx%3Fmarklet%3D1%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles';" title="Live"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="myspace" href="javascript:window.location='http%3A%2F%2Fwww.myspace.com%2FModules%2FPostTo%2FPages%2F%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Bt%3DSoft%2520Particles';" title="MySpace"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/myspace.png" title="MySpace" alt="MySpace" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="netvibes" href="javascript:window.location='http%3A%2F%2Fwww.netvibes.com%2Fshare%3Ftitle%3DSoft%2520Particles%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F';" title="Netvibes"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="stumbleupon" href="javascript:window.location='http%3A%2F%2Fwww.stumbleupon.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles';" title="StumbleUpon"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="twitter" href="javascript:window.location='http%3A%2F%2Ftwitter.com%2Fhome%3Fstatus%3DSoft%2520Particles%2520-%2520http%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F';" title="Twitter"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="reddit" href="javascript:window.location='http%3A%2F%2Freddit.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Btitle%3DSoft%2520Particles';" title="Reddit"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="technorati" href="javascript:window.location='http%3A%2F%2Ftechnorati.com%2Ffaves%3Fadd%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F';" title="Technorati"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" class="sociable-hovers" /></a></li>
	<li class="sociablelast"><a rel="nofollow" id="yahoo! bookmarks" href="javascript:window.location='http%3A%2F%2Fbookmarks.yahoo.com%2Ftoolbar%2Fsavebm%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2009%252F09%252F16%252Fsoft-particles%252F%26amp%3Bt%3DSoft%2520Particles%26opener%3Dbm%26amp%3Bei%3DUTF-8%26amp%3Bd%3D%250D%250A%250D%250AThe%2520aim%2520with%2520soft%2520particles%2520is%2520to%2520remove%2520the%2520ugly%2520artifact%2520that%2520appears%2520when%2520the%2520particle%2520quad%2520intersects%2520the%2520scene.%2520There%2520are%2520a%2520lot%2520of%2520different%2520approaches%2520to%2520solve%2520this%252C%2520some%2520more%2520complicate%2520than%2520others.%2520The%2520simplest%2520formula%2520for%2520soft%2520particles%2520';" title="Yahoo! Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/yahoomyweb.png" title="Yahoo! Bookmarks" alt="Yahoo! Bookmarks" class="sociable-hovers" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerendering.com/2009/09/16/soft-particles/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Deferred Lighting</title>
		<link>http://www.gamerendering.com/2008/11/01/deferred-lightning/</link>
		<comments>http://www.gamerendering.com/2008/11/01/deferred-lightning/#comments</comments>
		<pubDate>Fri, 31 Oct 2008 23:39:03 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Rendering Methods]]></category>
		<category><![CDATA[Deferred Lighting]]></category>
		<category><![CDATA[Deferred Lightning]]></category>
		<category><![CDATA[Deferred Rendering]]></category>
		<category><![CDATA[Deferred Shading]]></category>
		<category><![CDATA[DirectX]]></category>
		<category><![CDATA[Lighting]]></category>
		<category><![CDATA[Render-to-Texture]]></category>
		<category><![CDATA[Rendering]]></category>
		<category><![CDATA[Shading]]></category>
		<category><![CDATA[SSAO]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[XNA]]></category>

		<guid isPermaLink="false">http://www.gamerendering.com/?p=434</guid>
		<description><![CDATA[This is a lighting technique that lately has increased a lot in popularity. The normal way of shading is to perform the lighting calculations on a fragment when it is rasterized to the screen. This is often good but requires a lot of calculations if there are many lights. And the bad thing is that [...]]]></description>
			<content:encoded><![CDATA[<p>This is a lighting technique that lately has increased a lot in popularity. The normal way of shading is to perform the lighting calculations on a fragment when it is rasterized to the screen. This is often good but requires a lot of calculations if there are many lights. And the bad thing is that this fragment might later on be overwritten by some other fragment so the calculations might be a waste.</p>
<p>In deferred lighting (or deferred shading, or deferred rendering), you save the information about the fragment that is necessary to perform the shading (lighting) by rendering them to textures instead of doing the actual lighting calculation. When all geometry is rendered, the lighting will now be calculated only once per pixel on the screen. So no calculations will be wasted. You can perhaps say that it is some sort of a lazy evaluator.</p>
<p>The information saved per fragment is often:</p>
<ul>
<li>position ( or just depth )</li>
<li>albedo ( the diffuse texture )</li>
<li>normal</li>
<li>specular</li>
</ul>
<p>And these are sometimes also used:</p>
<ul>
<li>shininess</li>
<li>material ID (for selecting material behaviour)</li>
</ul>
<p>When all geometry has been rendered and it&#8217;s time to perform the lighting, the lights needs to be represented as something when sent to rasterization. Point lights can be drawn either as spheres or just square billboards. Directional light should be drawn as a full screen rectangle. And spotlights will be cones. Note that this shading technique allows for lights shaped in any form, not just these traditional ones.</p>
<p>The big reason for using deferred rendering is how well it scales with more lights. Another reason that it has increased in popularity lately is how nice it works with new rendering methods like SSAO and depth of field. The problem areas with deferred lighting is transparent objects and multisampling (antialiasing). If the original scene didn&#8217;t have per pixel lighting (but instead maybe vertex lightning) on the whole scene then the deferred rendering might be slower than traditional rendering.</p>
<div id="attachment_436" class="wp-caption alignnone" style="width: 314px"><a href="http://www.gamerendering.com/wp-content/uploads/1.jpg"><img class="size-medium wp-image-436" title="Deferred Lightning example" src="http://www.gamerendering.com/wp-content/uploads/1.jpg" alt="Deferred Lightning example" width="304" height="214" /></a><p class="wp-caption-text">Deferred Lighting example</p></div>
<p>Explanation of deferred lighting (and source code)<br />
<a href="http://www.beyond3d.com/content/articles/19/">http://www.beyond3d.com/content/articles/19/</a></p>
<div id="attachment_437" class="wp-caption alignnone" style="width: 338px"><a href="http://www.gamerendering.com/wp-content/uploads/3.jpg"><img class="size-medium wp-image-437" title="Deferred Rendering in S.T.A.L.K.E.R." src="http://www.gamerendering.com/wp-content/uploads/3.jpg" alt="Deferred Rendering in S.T.A.L.K.E.R." width="328" height="248" /></a><p class="wp-caption-text">Deferred Rendering in S.T.A.L.K.E.R.</p></div>
<p>Explanation of how deferred lighting was used in the game S.T.A.L.K.E.R.<br />
<a href="http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter09.html">http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter09.html</a> </p>
<div id="attachment_438" class="wp-caption alignnone" style="width: 324px"><a href="http://www.gamerendering.com/wp-content/uploads/4.jpg"><img class="size-medium wp-image-438" title="The result of the deferred rendering XNA tutorial" src="http://www.gamerendering.com/wp-content/uploads/4.jpg" alt="The result of the deferred rendering XNA tutorial" width="314" height="237" /></a><p class="wp-caption-text">The result of the deferred rendering XNA tutorial</p></div>
<p>A very good tutorial of how to implement deferred lighting in XNA 2.0. This is good reading even when you are rendering in an other API.<br />
<a href="http://www.ziggyware.com/readarticle.php?article_id=155">http://www.ziggyware.com/readarticle.php?article_id=155</a></p>
<p>A long discussion on the gamedev.net forum of pros and cons of using deferred rendering compared to traditional forward rendering.<br />
<a href="http://www.gamedev.net/community/forums/topic.asp?topic_id=424979">http://www.gamedev.net/community/forums/topic.asp?topic_id=424979</a></p>
<p>DirectX9 implementation if deferred shading, and some optimization talk<br />
<a href="http://www.gamedev.net/reference/programming/features/shaderx2/Tips_and_Tricks_with_DirectX_9.pdf">http://www.gamedev.net/reference/programming/features/shaderx2/Tips_and_Tricks_with_ DirectX_9.pdf</a></p>
<div id="attachment_435" class="wp-caption alignnone" style="width: 248px"><a href="http://www.gamerendering.com/wp-content/uploads/2.jpg"><img class="size-medium wp-image-435" title="Deferred Lightning in Leadwerk Engine" src="http://www.gamerendering.com/wp-content/uploads/2.jpg" alt="Deferred Lightning in Leadwerk Engine" width="238" height="180" /></a><p class="wp-caption-text">Deferred Lightning in Leadwerk Engine</p></div>
<p>Info about the implementation of deferred shading in the Leadwerks Engine.<br />
<a href="http://www.leadwerks.com/files/Deferred_Rendering_in_Leadwerks_Engine.pdf">http://www.leadwerks.com/files/Deferred_Rendering_in_Leadwerks_Engine.pdf</a></p>
<div id="attachment_483" class="wp-caption alignnone" style="width: 410px"><a href="http://www.gamerendering.com/wp-content/uploads/killzone.jpg"><img class="size-medium wp-image-483" title="Deferred Lighting in Killzone 2" src="http://www.gamerendering.com/wp-content/uploads/killzone-400x253.jpg" alt="Deferred Lighting in Killzone 2" width="400" height="253" /></a><p class="wp-caption-text">Deferred Lighting in Killzone 2</p></div>
<p>A presentation about deferred lighting in the game Killzone 2:<br />
<a href="http://www.guerrilla-games.com/publications/dr_kz2_rsx_dev07.pdf">http://www.guerrilla-games.com/publications/dr_kz2_rsx_dev07.pdf</a></p>

<div class="sociable">
<div class="sociable_tagline">
<strong>Please share:</strong>
</div>
<ul>
	<li class="sociablefirst"><a rel="nofollow" id="print" href="javascript:window.location='http%3A%2F%2Fwww.printfriendly.com%2Fprint%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Bpartner%3Dsociable';" title="Print this article!"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/printfriendly.png" title="Print this article!" alt="Print this article!" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="digg" href="javascript:window.location='http%3A%2F%2Fdigg.com%2Fsubmit%3Fphase%3D2%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting%26amp%3Bbodytext%3DThis%2520is%2520a%2520lighting%2520technique%2520that%2520lately%2520has%2520increased%2520a%2520lot%2520in%2520popularity.%2520The%2520normal%2520way%2520of%2520shading%2520is%2520to%2520perform%2520the%2520lighting%2520calculations%2520on%2520a%2520fragment%2520when%2520it%2520is%2520rasterized%2520to%2520the%2520screen.%2520This%2520is%2520often%2520good%2520but%2520requires%2520a%2520lot%2520of%2520calculations%2520if%2520';" title="Digg"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="sphinn" href="javascript:window.location='http%3A%2F%2Fsphinn.com%2Findex.php%3Fc%3Dpost%26m%3Dsubmit%26link%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F';" title="Sphinn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/sphinn.png" title="Sphinn" alt="Sphinn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="del.icio.us" href="javascript:window.location='http%3A%2F%2Fdelicious.com%2Fpost%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting%26amp%3Bnotes%3DThis%2520is%2520a%2520lighting%2520technique%2520that%2520lately%2520has%2520increased%2520a%2520lot%2520in%2520popularity.%2520The%2520normal%2520way%2520of%2520shading%2520is%2520to%2520perform%2520the%2520lighting%2520calculations%2520on%2520a%2520fragment%2520when%2520it%2520is%2520rasterized%2520to%2520the%2520screen.%2520This%2520is%2520often%2520good%2520but%2520requires%2520a%2520lot%2520of%2520calculations%2520if%2520';" title="del.icio.us"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/delicious.png" title="del.icio.us" alt="del.icio.us" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="facebook" href="javascript:window.location='http%3A%2F%2Fwww.facebook.com%2Fshare.php%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Bt%3DDeferred%2520Lighting';" title="Facebook"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="mixx" href="javascript:window.location='http%3A%2F%2Fwww.mixx.com%2Fsubmit%3Fpage_url%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting';" title="Mixx"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/mixx.png" title="Mixx" alt="Mixx" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="google" href="javascript:window.location='http%3A%2F%2Fwww.google.com%2Fbookmarks%2Fmark%3Fop%3Dedit%26amp%3Bbkmk%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting%26amp%3Bannotation%3DThis%2520is%2520a%2520lighting%2520technique%2520that%2520lately%2520has%2520increased%2520a%2520lot%2520in%2520popularity.%2520The%2520normal%2520way%2520of%2520shading%2520is%2520to%2520perform%2520the%2520lighting%2520calculations%2520on%2520a%2520fragment%2520when%2520it%2520is%2520rasterized%2520to%2520the%2520screen.%2520This%2520is%2520often%2520good%2520but%2520requires%2520a%2520lot%2520of%2520calculations%2520if%2520';" title="Google Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="current" href="javascript:window.location='http%3A%2F%2Fcurrent.com%2Fclipper.htm%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting';" title="Current"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/current.png" title="Current" alt="Current" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="linkedin" href="javascript:window.location='http%3A%2F%2Fwww.linkedin.com%2FshareArticle%3Fmini%3Dtrue%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting%26amp%3Bsource%3DGame%2BRendering%2B%26amp%3Bsummary%3DThis%2520is%2520a%2520lighting%2520technique%2520that%2520lately%2520has%2520increased%2520a%2520lot%2520in%2520popularity.%2520The%2520normal%2520way%2520of%2520shading%2520is%2520to%2520perform%2520the%2520lighting%2520calculations%2520on%2520a%2520fragment%2520when%2520it%2520is%2520rasterized%2520to%2520the%2520screen.%2520This%2520is%2520often%2520good%2520but%2520requires%2520a%2520lot%2520of%2520calculations%2520if%2520';" title="LinkedIn"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/linkedin.png" title="LinkedIn" alt="LinkedIn" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="live" href="javascript:window.location='https%3A%2F%2Ffavorites.live.com%2Fquickadd.aspx%3Fmarklet%3D1%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting';" title="Live"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="myspace" href="javascript:window.location='http%3A%2F%2Fwww.myspace.com%2FModules%2FPostTo%2FPages%2F%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Bt%3DDeferred%2520Lighting';" title="MySpace"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/myspace.png" title="MySpace" alt="MySpace" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="netvibes" href="javascript:window.location='http%3A%2F%2Fwww.netvibes.com%2Fshare%3Ftitle%3DDeferred%2520Lighting%26amp%3Burl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F';" title="Netvibes"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/netvibes.png" title="Netvibes" alt="Netvibes" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="stumbleupon" href="javascript:window.location='http%3A%2F%2Fwww.stumbleupon.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting';" title="StumbleUpon"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/stumbleupon.png" title="StumbleUpon" alt="StumbleUpon" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="twitter" href="javascript:window.location='http%3A%2F%2Ftwitter.com%2Fhome%3Fstatus%3DDeferred%2520Lighting%2520-%2520http%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F';" title="Twitter"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/twitter.png" title="Twitter" alt="Twitter" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="reddit" href="javascript:window.location='http%3A%2F%2Freddit.com%2Fsubmit%3Furl%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Btitle%3DDeferred%2520Lighting';" title="Reddit"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/reddit.png" title="Reddit" alt="Reddit" class="sociable-hovers" /></a></li>
	<li><a rel="nofollow" id="technorati" href="javascript:window.location='http%3A%2F%2Ftechnorati.com%2Ffaves%3Fadd%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F';" title="Technorati"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/technorati.png" title="Technorati" alt="Technorati" class="sociable-hovers" /></a></li>
	<li class="sociablelast"><a rel="nofollow" id="yahoo! bookmarks" href="javascript:window.location='http%3A%2F%2Fbookmarks.yahoo.com%2Ftoolbar%2Fsavebm%3Fu%3Dhttp%253A%252F%252Fwww.gamerendering.com%252F2008%252F11%252F01%252Fdeferred-lightning%252F%26amp%3Bt%3DDeferred%2520Lighting%26opener%3Dbm%26amp%3Bei%3DUTF-8%26amp%3Bd%3DThis%2520is%2520a%2520lighting%2520technique%2520that%2520lately%2520has%2520increased%2520a%2520lot%2520in%2520popularity.%2520The%2520normal%2520way%2520of%2520shading%2520is%2520to%2520perform%2520the%2520lighting%2520calculations%2520on%2520a%2520fragment%2520when%2520it%2520is%2520rasterized%2520to%2520the%2520screen.%2520This%2520is%2520often%2520good%2520but%2520requires%2520a%2520lot%2520of%2520calculations%2520if%2520';" title="Yahoo! Bookmarks"><img src="http://www.gamerendering.com/wp-content/plugins/sociable/images/yahoomyweb.png" title="Yahoo! Bookmarks" alt="Yahoo! Bookmarks" class="sociable-hovers" /></a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerendering.com/2008/11/01/deferred-lightning/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
