<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://xna-uk.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx</link><description>[Go to the site to view embedded media] Well here is the same skybox, terrain and ocean objects, only this time I have added the fogging effect to the shader. Naturally the class&amp;#39; have had to be modified to pass the fog parameters and I have added</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1543</link><pubDate>Thu, 03 Jan 2008 09:40:48 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1543</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;OK, now I know what you are after I will take a look.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1543" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1541</link><pubDate>Thu, 03 Jan 2008 05:39:07 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1541</guid><dc:creator>JeBuS</dc:creator><description>&lt;p&gt;I suppose stopping it altogether is an option, though I was hoping for something more along the lines of overlayed bump maps going in different directions.&lt;/p&gt;
&lt;p&gt;Thanks for your help, though!&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1541" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1538</link><pubDate>Mon, 31 Dec 2007 21:32:50 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1538</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;JeBuS,&lt;/p&gt;
&lt;p&gt;OK, this is dead easy to sort out. In the shader set the bumpSpeed value to {0.0,0.0} and your flow is stopped.&lt;/p&gt;
&lt;p&gt;Now if I was you I would add another field and property to the class so it can be altered at runtime and so giving you even more control over the shader. There are SOO many other params I have not touched in this shader, I love it, thank you NVIDIA.&lt;/p&gt;
&lt;p&gt;I really should look at writing my own water one day...&lt;/p&gt;
&lt;p&gt;Hope this helps :P&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1538" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1537</link><pubDate>Mon, 31 Dec 2007 19:15:53 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1537</guid><dc:creator>JeBuS</dc:creator><description>&lt;p&gt;I&amp;#39;d appreciate it if you could. &amp;nbsp;It&amp;#39;s not a huge deal, really, and it could wait until I have time to study HLSL, but who knows when that will be. :-)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1537" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1535</link><pubDate>Sun, 30 Dec 2007 19:29:50 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1535</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;Ah, I get what you are saying. Well the shader is by NVIDIA and I guess it was to be used for Ocean that is close to the shaw.&lt;/p&gt;
&lt;p&gt;You could remove the flow, I have not looked at removing this yet, but will if you like, can't see it being that difficult.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1535" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1532</link><pubDate>Sat, 29 Dec 2007 20:51:39 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1532</guid><dc:creator>JeBuS</dc:creator><description>&lt;p&gt;Well, if it were a large body of water, like the open ocean, waves don&amp;#39;t always just go in one direction. &amp;nbsp;The sea surface just kind of rises and falls, if you get my drift. &amp;nbsp;So having all of the waves going in one direction makes it look like it&amp;#39;s either near a shore (where all of the water is going towards the shore), or it&amp;#39;s some funky river in the ocean.&lt;/p&gt;
&lt;p&gt;I hope I described that well. :-)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1532" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1530</link><pubDate>Sat, 29 Dec 2007 20:36:13 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1530</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;Yes I guess so, but I would think this would make the water look odd as you would want the flow to follow the wave...?&lt;/p&gt;
&lt;p&gt;Are you asking me to do an example with a switchable direction of flow??&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1530" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1529</link><pubDate>Sat, 29 Dec 2007 06:51:37 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1529</guid><dc:creator>JeBuS</dc:creator><description>&lt;p&gt;Hey, these are great examples, but I was wondering something about the water. &amp;nbsp;The effect of the animated water makes it appear as though it is moving in one direction. &amp;nbsp;Is there some way to perhaps add a second pass using the normal map maybe inverted and going the opposite way? &amp;nbsp;I don&amp;#39;t know much about HLSL, so forgive my ignorance is this is a simple matter.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1529" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1322</link><pubDate>Thu, 01 Nov 2007 21:47:50 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1322</guid><dc:creator>andrew</dc:creator><description>&lt;p&gt;cool. I&amp;#39;m very interested to see what you come up with.&lt;/p&gt;
&lt;p&gt;thanks much&lt;/p&gt;
&lt;p&gt;andrew&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1322" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1304</link><pubDate>Thu, 01 Nov 2007 09:35:45 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1304</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;I have an FPS counter like that, I am sure it is in one of my posts here.&lt;/p&gt;
&lt;p&gt;I used FRAPS and found I am getting 25fps on my Laptop (windowed), you must keep in mind that this laptop is probably near the bottom end of specification for 3D and gaming in general.&lt;/p&gt;
&lt;p&gt;Also, there is no culling of this terrain or any real LOD work done here, also &amp;nbsp;Half Life 2 and Oblivion are written by professional games developers that have had years of games writing experience, I get a bout 4 hours a week to play with this stuff :P&lt;/p&gt;
&lt;p&gt;I have been working on a self culling terrain class and and this bumps the FPS up a great deal, once I have it down and it is in a presentable format I will post it here.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1304" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1303</link><pubDate>Thu, 01 Nov 2007 05:08:43 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1303</guid><dc:creator>andrew</dc:creator><description>&lt;p&gt;out of curiosity, what frame rate are you getting with your version?&lt;/p&gt;
&lt;p&gt;I added a simple FPS counter, and found that I was only getting around 15 fps when I expanded the window to full screen (1280*1024). &lt;/p&gt;
&lt;p&gt;The weird thing is that my computer can handle Half Life 2 on full settings and Oblivion on medium. I know XNA doesn&amp;#39;t perform as well as unmanaged code, but it should still run better than it does. I&amp;#39;m really puzzled by this,&lt;/p&gt;
&lt;p&gt;heres the link to the FPS counter code if your interested&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/shawnhar/archive/2007/06/08/displaying-the-framerate.aspx"&gt;blogs.msdn.com/.../displaying-the-framerate.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;thanks,&lt;/p&gt;
&lt;p&gt;Andrew&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1303" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1285</link><pubDate>Tue, 30 Oct 2007 09:39:57 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1285</guid><dc:creator>Nemo Krad</dc:creator><description>&lt;p&gt;Yes the original is based on Riemer's work, and I too found it heavy of the FPS. I discovered this was down to the shader so in these Generic XNA samples I have put up I have written my own terrain shader.&lt;/p&gt;
&lt;p&gt;It is cruder than Riemer's but give a boost to FPS, in this example though I have added a second pass for the fog and so this may pull it down again. I have not done this with Riemer's terrain shader.&lt;/p&gt;
&lt;p&gt;Also remember I have added bump/normal mapping to this terrain also so that too will add to the FPS drain. If you look back through the posts you will find where I started to optimize the terrain shader, you will find Riemer's terrain shader (almost original), Riemer's terrain shader bumped as well as my derivative, both simple, bumped and fogged.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1285" width="1" height="1"&gt;</description></item><item><title>re: Simple Bumped Terrain and Water with Fog</title><link>http://xna-uk.net/blogs/randomchaos/archive/2007/10/25/simple-bumped-terrain-and-water-with-fog.aspx#1284</link><pubDate>Tue, 30 Oct 2007 04:55:33 GMT</pubDate><guid isPermaLink="false">cc259236-b685-459d-9e21-6c78c60b874c:1284</guid><dc:creator>andrew</dc:creator><description>&lt;p&gt;I found you from a forum post on riemer&amp;#39;s site. I take it your terrain is an adaptation of his.&lt;/p&gt;
&lt;p&gt;I was getting absolutely absurd fps problems with his code (averaging 30 fps), so I&amp;#39;m curious to see if i get the same problems with yours. well I&amp;#39;ll check it out.&lt;/p&gt;
&lt;p&gt;thanks much &lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://xna-uk.net/aggbug.aspx?PostID=1284" width="1" height="1"&gt;</description></item></channel></rss>