<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: [LPP] Ambient Lights</title>
	<atom:link href="http://mquandt.com/blog/2010/04/lpp-ambient-lights/feed/" rel="self" type="application/rss+xml" />
	<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/</link>
	<description></description>
	<lastBuildDate>Tue, 06 Dec 2011 09:47:27 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Alejandro</title>
		<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/comment-page-1/#comment-3213</link>
		<dc:creator>Alejandro</dc:creator>
		<pubDate>Thu, 15 Apr 2010 11:48:04 +0000</pubDate>
		<guid isPermaLink="false">http://mquandt.com/blog/2010/04/lpp-ambient-lights/#comment-3213</guid>
		<description>Tips annotated!&lt;br&gt;Reusable flexible code is half the battle.&lt;br&gt;&lt;br&gt;I can&#039;t wait to get my hands on XNA 4.0 also to start messing around with the render states objects and new render target rules so I can set aside current rules. The more work is done in 3.1 the more to change with 4.0. Hopefully test something on the phone.&lt;br&gt;I&#039;m really glad by the direction XNA is taking, who knows what we will see in the future.</description>
		<content:encoded><![CDATA[<p>Tips annotated!<br />Reusable flexible code is half the battle.</p>
<p>I can&#39;t wait to get my hands on XNA 4.0 also to start messing around with the render states objects and new render target rules so I can set aside current rules. The more work is done in 3.1 the more to change with 4.0. Hopefully test something on the phone.<br />I&#39;m really glad by the direction XNA is taking, who knows what we will see in the future.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chr0n1x</title>
		<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/comment-page-1/#comment-3212</link>
		<dc:creator>Chr0n1x</dc:creator>
		<pubDate>Thu, 15 Apr 2010 11:34:26 +0000</pubDate>
		<guid isPermaLink="false">http://mquandt.com/blog/2010/04/lpp-ambient-lights/#comment-3212</guid>
		<description>Hi, thanks for your input.&lt;br&gt;&lt;br&gt;Yes you certainly can clear the device to do an ambient light, and if you are fine with restricting yourself to one ambient light or coding that directly into the renderer, then it is perfect.&lt;br&gt;&lt;br&gt;I decided for the tutorial to show the longer, but flexible method, however both work quite well, and generally you only need one ambient light anyway. (I am aiming to be very generic/open with my engine, so who knows what lighting setup I want to use in future :))&lt;br&gt;&lt;br&gt;Yes you are right, the compiler should certainly remove unused methods, and hopefully unused variables. I add the pre-processor directives so that I can play around in future adding/disabling techniques. It also helps me in slightly more complicated shaders - by removing a #define I can trigger compiler errors telling me where the references to the now missing method/variable are, without having to delete the actual method, which I may want to reuse later.&lt;br&gt;&lt;br&gt;All of the code presented comes from my private engine at a certain point in time. I use that engine to experiment with techniques, and just copy over and edit the required parts for a sample.&lt;br&gt;&lt;br&gt;I&#039;m glad you like my blog. =D&lt;br&gt;I hope to have some more content coming soon, just finished up a big push towards a product release at work, and I have not had the time to do anything in XNA. I am also debating whether to wait for XNA 4.0 (HiDef) or continue in 3.1 and figure out some migration path when I can build against 4.0.</description>
		<content:encoded><![CDATA[<p>Hi, thanks for your input.</p>
<p>Yes you certainly can clear the device to do an ambient light, and if you are fine with restricting yourself to one ambient light or coding that directly into the renderer, then it is perfect.</p>
<p>I decided for the tutorial to show the longer, but flexible method, however both work quite well, and generally you only need one ambient light anyway. (I am aiming to be very generic/open with my engine, so who knows what lighting setup I want to use in future <img src='http://mquandt.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> )</p>
<p>Yes you are right, the compiler should certainly remove unused methods, and hopefully unused variables. I add the pre-processor directives so that I can play around in future adding/disabling techniques. It also helps me in slightly more complicated shaders &#8211; by removing a #define I can trigger compiler errors telling me where the references to the now missing method/variable are, without having to delete the actual method, which I may want to reuse later.</p>
<p>All of the code presented comes from my private engine at a certain point in time. I use that engine to experiment with techniques, and just copy over and edit the required parts for a sample.</p>
<p>I&#39;m glad you like my blog. =D<br />I hope to have some more content coming soon, just finished up a big push towards a product release at work, and I have not had the time to do anything in XNA. I am also debating whether to wait for XNA 4.0 (HiDef) or continue in 3.1 and figure out some migration path when I can build against 4.0.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chr0n1x</title>
		<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/comment-page-1/#comment-3211</link>
		<dc:creator>Chr0n1x</dc:creator>
		<pubDate>Thu, 15 Apr 2010 11:34:26 +0000</pubDate>
		<guid isPermaLink="false">http://mquandt.com/blog/2010/04/lpp-ambient-lights/#comment-3211</guid>
		<description>Hi, thanks for your input.&lt;br&gt;&lt;br&gt;Yes you certainly can clear the device to do an ambient light, and if you are fine with restricting yourself to one ambient light or coding that directly into the renderer, then it is perfect.&lt;br&gt;&lt;br&gt;I decided for the tutorial to show the longer, but flexible method, however both work quite well, and generally you only need one ambient light anyway. (I am aiming to be very generic/open with my engine, so who knows what lighting setup I want to use in future :))&lt;br&gt;&lt;br&gt;Yes you are right, the compiler should certainly remove unused methods, and hopefully unused variables. I add the pre-processor directives so that I can play around in future adding/disabling techniques. It also helps me in slightly more complicated shaders - by removing a #define I can trigger compiler errors telling me where the references to the now missing method/variable are, without having to delete the actual method, which I may want to reuse later.&lt;br&gt;&lt;br&gt;All of the code presented comes from my private engine at a certain point in time. I use that engine to experiment with techniques, and just copy over and edit the required parts for a sample.&lt;br&gt;&lt;br&gt;I&#039;m glad you like my blog. =D&lt;br&gt;I hope to have some more content coming soon, just finished up a big push towards a product release at work, and I have not had the time to do anything in XNA. I am also debating whether to wait for XNA 4.0 (HiDef) or continue in 3.1 and figure out some migration path when I can build against 4.0.</description>
		<content:encoded><![CDATA[<p>Hi, thanks for your input.</p>
<p>Yes you certainly can clear the device to do an ambient light, and if you are fine with restricting yourself to one ambient light or coding that directly into the renderer, then it is perfect.</p>
<p>I decided for the tutorial to show the longer, but flexible method, however both work quite well, and generally you only need one ambient light anyway. (I am aiming to be very generic/open with my engine, so who knows what lighting setup I want to use in future <img src='http://mquandt.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> )</p>
<p>Yes you are right, the compiler should certainly remove unused methods, and hopefully unused variables. I add the pre-processor directives so that I can play around in future adding/disabling techniques. It also helps me in slightly more complicated shaders &#8211; by removing a #define I can trigger compiler errors telling me where the references to the now missing method/variable are, without having to delete the actual method, which I may want to reuse later.</p>
<p>All of the code presented comes from my private engine at a certain point in time. I use that engine to experiment with techniques, and just copy over and edit the required parts for a sample.</p>
<p>I&#39;m glad you like my blog. =D<br />I hope to have some more content coming soon, just finished up a big push towards a product release at work, and I have not had the time to do anything in XNA. I am also debating whether to wait for XNA 4.0 (HiDef) or continue in 3.1 and figure out some migration path when I can build against 4.0.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alejandro</title>
		<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/comment-page-1/#comment-3210</link>
		<dc:creator>Alejandro</dc:creator>
		<pubDate>Thu, 15 Apr 2010 11:08:42 +0000</pubDate>
		<guid isPermaLink="false">http://mquandt.com/blog/2010/04/lpp-ambient-lights/#comment-3210</guid>
		<description>Hi there Michael!,&lt;br&gt;I have been playing around with rendering techniques, although still way behind in the process...&lt;br&gt;&lt;br&gt;I would like to comment about ambient color though, with a tip that John David said in his blog &lt;a href=&quot;http://my-pseudocode-life.blogspot.com/&quot; rel=&quot;nofollow&quot;&gt;http://my-pseudocode-life.blogspot.com/&lt;/a&gt;&lt;br&gt;&lt;br&gt;Basically is to flash the device to the ambient color -&gt; device.Clear(ambientColor), it&#039;s almost free. It would only work when additive blending all lights in the lighting pass of LPP. When the lighting pass actually starts blending all the lights, the ambient color is already there. You can clear it to a color with alpha zero so it doesn&#039;t mess with the speculars (in case specular is in alpha as your sample).&lt;br&gt;&lt;br&gt;And a question: &lt;br&gt;Roughly seeing the sample I noticed that in your common.fxh, you have separated some sections using #ifdef preprocessors, so the actual .fx file only will get what is has been defined its &quot;#define&quot; directives. The question is, is this just a &quot;best practices&quot; to keep order in the shaders? or is it somehow faster since the shader has less &quot;methods&quot; to access to?&lt;br&gt; (Although to my understanding until now, the shader parses the compiled file at run-time, where the unused fields and methods will be discarded on the compiled file, but you never now)&lt;br&gt;&lt;br&gt;Nice blog by the way!</description>
		<content:encoded><![CDATA[<p>Hi there Michael!,<br />I have been playing around with rendering techniques, although still way behind in the process&#8230;</p>
<p>I would like to comment about ambient color though, with a tip that John David said in his blog <a href="http://my-pseudocode-life.blogspot.com/" rel="nofollow">http://my-pseudocode-life.blogspot.com/</a></p>
<p>Basically is to flash the device to the ambient color -&gt; device.Clear(ambientColor), it&#39;s almost free. It would only work when additive blending all lights in the lighting pass of LPP. When the lighting pass actually starts blending all the lights, the ambient color is already there. You can clear it to a color with alpha zero so it doesn&#39;t mess with the speculars (in case specular is in alpha as your sample).</p>
<p>And a question: <br />Roughly seeing the sample I noticed that in your common.fxh, you have separated some sections using #ifdef preprocessors, so the actual .fx file only will get what is has been defined its &#8220;#define&#8221; directives. The question is, is this just a &#8220;best practices&#8221; to keep order in the shaders? or is it somehow faster since the shader has less &#8220;methods&#8221; to access to?<br /> (Although to my understanding until now, the shader parses the compiled file at run-time, where the unused fields and methods will be discarded on the compiled file, but you never now)</p>
<p>Nice blog by the way!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pete</title>
		<link>http://mquandt.com/blog/2010/04/lpp-ambient-lights/comment-page-1/#comment-3207</link>
		<dc:creator>Pete</dc:creator>
		<pubDate>Sun, 04 Apr 2010 01:19:23 +0000</pubDate>
		<guid isPermaLink="false">http://mquandt.com/blog/2010/04/lpp-ambient-lights/#comment-3207</guid>
		<description>Nice!&lt;br&gt;&lt;br&gt;Let&#039;s hope we can share depth buffers among different rendertarget &quot;buckets&quot;.&lt;br&gt;&lt;br&gt;&lt;a href=&quot;https://connect.microsoft.com/site226/feedback/details/546327/xna-gs-4-x-allow-sharing-a-depth-buffer-among-render-target-switches&quot; rel=&quot;nofollow&quot;&gt;https://connect.microsoft.com/site226/feedback/...&lt;/a&gt;</description>
		<content:encoded><![CDATA[<p>Nice!</p>
<p>Let&#39;s hope we can share depth buffers among different rendertarget &#8220;buckets&#8221;.</p>
<p><a href="https://connect.microsoft.com/site226/feedback/details/546327/xna-gs-4-x-allow-sharing-a-depth-buffer-among-render-target-switches" rel="nofollow">https://connect.microsoft.com/site226/feedback/&#8230;</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>

