{"id":1142,"date":"2014-12-04T18:12:39","date_gmt":"2014-12-04T18:12:39","guid":{"rendered":"http:\/\/phoenixgamedevelopment.com\/blog\/?p=1142"},"modified":"2014-12-04T18:12:39","modified_gmt":"2014-12-04T18:12:39","slug":"p-152-virtual-world-concept-update-21-spherical-terrain-sphere-texturing","status":"publish","type":"post","link":"https:\/\/phoenixgamedevelopment.com\/blog\/p-152-virtual-world-concept-update-21-spherical-terrain-sphere-texturing\/","title":{"rendered":"P-152: Virtual World Concept Update 21: Spherical Terrain: Sphere Texturing"},"content":{"rendered":"<p>I have successfully added basic procedural texturing to this project. I have simple used the perlin noise to colour each vertex point.<\/p>\n<p>I have used an If statement to select one colour from a range of 8 colours (from deep water to snow) based on the height of the noise at that point. This has produced some very nice results in the below images.<\/p>\n<p>I obtained the colour values from <a href=\"http:\/\/libnoise.sourceforge.net\/tutorials\/tutorial8.html\">THIS<\/a> very useful tutorial from libnoise&#8217;s sourceforge site.<\/p>\n<p>In order to improve the quality of the texture, I will need to increase the resolution of the terrain, as well as modify the parameters of the perlin noise function, I also intend to add a smooth gradient to the pixel colours, instead of choosing a solid colour based on height.<\/p>\n<p>Once I have a basic texture working, I can start implementing collision detection on the sphere, and then I can begin working on paging and very large terrains.<\/p>\n<p>To generate the starfields in the below images, I used the very useful free program &#8220;Spacescape&#8221; , available <a href=\"http:\/\/sourceforge.net\/projects\/spacescape\/\">HERE<\/a>.<\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment12-Dec.-03-19.15.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1141\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment12-Dec.-03-19.15-300x232.jpg\" alt=\"PhoenixGameDevelopment12 Dec. 03 19.15\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment12-Dec.-03-19.15-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment12-Dec.-03-19.15-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment12-Dec.-03-19.15.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment17-Dec.-03-19.30.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1140\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment17-Dec.-03-19.30-300x232.jpg\" alt=\"PhoenixGameDevelopment17 Dec. 03 19.30\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment17-Dec.-03-19.30-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment17-Dec.-03-19.30-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment17-Dec.-03-19.30.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment19-Dec.-03-19.30.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1139\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment19-Dec.-03-19.30-300x232.jpg\" alt=\"PhoenixGameDevelopment19 Dec. 03 19.30\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment19-Dec.-03-19.30-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment19-Dec.-03-19.30-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment19-Dec.-03-19.30.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment46-Dec.-03-20.14.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1138\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment46-Dec.-03-20.14-300x232.jpg\" alt=\"PhoenixGameDevelopment46 Dec. 03 20.14\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment46-Dec.-03-20.14-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment46-Dec.-03-20.14-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment46-Dec.-03-20.14.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment48-Dec.-03-20.15.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1137\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment48-Dec.-03-20.15-300x232.jpg\" alt=\"PhoenixGameDevelopment48 Dec. 03 20.15\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment48-Dec.-03-20.15-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment48-Dec.-03-20.15-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment48-Dec.-03-20.15.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment47-Dec.-03-20.15.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1136\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment47-Dec.-03-20.15-300x232.jpg\" alt=\"PhoenixGameDevelopment47 Dec. 03 20.15\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment47-Dec.-03-20.15-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment47-Dec.-03-20.15-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment47-Dec.-03-20.15.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment67-Dec.-03-20.51.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1132\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment67-Dec.-03-20.51-300x232.jpg\" alt=\"PhoenixGameDevelopment67 Dec. 03 20.51\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment67-Dec.-03-20.51-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment67-Dec.-03-20.51-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment67-Dec.-03-20.51.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment63-Dec.-03-20.49.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1133\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment63-Dec.-03-20.49-300x232.jpg\" alt=\"PhoenixGameDevelopment63 Dec. 03 20.49\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment63-Dec.-03-20.49-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment63-Dec.-03-20.49-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment63-Dec.-03-20.49.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment61-Dec.-03-20.48.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1134\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment61-Dec.-03-20.48-300x232.jpg\" alt=\"PhoenixGameDevelopment61 Dec. 03 20.48\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment61-Dec.-03-20.48-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment61-Dec.-03-20.48-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment61-Dec.-03-20.48.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment57-Dec.-03-20.47.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1135\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment57-Dec.-03-20.47-300x232.jpg\" alt=\"PhoenixGameDevelopment57 Dec. 03 20.47\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment57-Dec.-03-20.47-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment57-Dec.-03-20.47-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment57-Dec.-03-20.47.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment72-Dec.-03-20.52.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1131\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment72-Dec.-03-20.52-300x232.jpg\" alt=\"PhoenixGameDevelopment72 Dec. 03 20.52\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment72-Dec.-03-20.52-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment72-Dec.-03-20.52-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment72-Dec.-03-20.52.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment71-Dec.-03-20.52.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1130\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment71-Dec.-03-20.52-300x232.jpg\" alt=\"PhoenixGameDevelopment71 Dec. 03 20.52\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment71-Dec.-03-20.52-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment71-Dec.-03-20.52-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment71-Dec.-03-20.52.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have successfully added basic procedural texturing to this project. I have simple used the perlin noise to colour each vertex point. I have used an If statement to select one colour from a range of 8 colours (from deep water to snow) based on the height of the noise at that point. This has [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,10],"tags":[],"class_list":["post-1142","post","type-post","status-publish","format-standard","hentry","category-art-and-designs","category-software-and-games","has-post-title","has-post-date","has-post-category","has-post-tag","has-post-comment","has-post-author",""],"aioseo_notices":[],"builder_content":"","_links":{"self":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1142"}],"collection":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/comments?post=1142"}],"version-history":[{"count":2,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1142\/revisions"}],"predecessor-version":[{"id":1144,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1142\/revisions\/1144"}],"wp:attachment":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/media?parent=1142"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/categories?post=1142"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/tags?post=1142"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}