{"id":3914,"date":"2016-10-09T23:56:08","date_gmt":"2016-10-09T22:56:08","guid":{"rendered":"http:\/\/phoenixgamedevelopment.com\/blog\/?p=3914"},"modified":"2016-10-10T00:03:29","modified_gmt":"2016-10-09T23:03:29","slug":"p-172-unity-space-environment-part-17","status":"publish","type":"post","link":"https:\/\/phoenixgamedevelopment.com\/blog\/p-172-unity-space-environment-part-17\/","title":{"rendered":"P-172: Unity: Space Environment: Part 17"},"content":{"rendered":"<p>I have followed a simple tutorial (<a href=\"http:\/\/wiki.unity3d.com\/index.php\/MirrorReflection4\">HERE<\/a>) to make a mirror in unity.<\/p>\n<p>This worked out well, and I also learned a little about Unity&#8217;s shader system in the process. It seems to use it&#8217;s own proprietary language called &#8220;Shaderlab&#8221;, but does allow for Cg shaders to be written within it.<\/p>\n<p>I wrote the shader for my Spherical Terrain project in HLSL, so this will need to be ported, but it is quite simple, so it shouldn&#8217;t be a problem. It may actually be easier to write it in &#8220;Surface&#8221;, because I then wouldn&#8217;t need a separate Vertex and Pixel shader file.<\/p>\n<p>Again, the shader system in Unity seems very easy to learn and use, which is encouraging.<\/p>\n<figure id=\"attachment_3924\" aria-describedby=\"caption-attachment-3924\" style=\"width: 300px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-3924\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM-300x163.jpg\" alt=\"Unity 09\/10\/2016 , 11:52:02 PM Unity Personal (64bit) - P0Lab2.unity - New Unity Project - PC, Mac &amp; Linux Standalone* \" width=\"300\" height=\"163\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM-300x163.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM-768x416.jpg 768w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM-1024x555.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_02-PM.jpg 1920w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-3924\" class=\"wp-caption-text\">Unity<br \/>09\/10\/2016 , 11:52:02 PM<br \/>Unity Personal (64bit) &#8211; P0Lab2.unity &#8211; New Unity Project &#8211; PC, Mac &amp; Linux Standalone*<\/figcaption><\/figure>\n<figure id=\"attachment_3923\" aria-describedby=\"caption-attachment-3923\" style=\"width: 300px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-3923\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM-300x163.jpg\" alt=\"Unity 09\/10\/2016 , 11:52:08 PM Unity Personal (64bit) - P0Lab2.unity - New Unity Project - PC, Mac &amp; Linux Standalone* \" width=\"300\" height=\"163\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM-300x163.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM-768x416.jpg 768w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM-1024x555.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2016\/10\/PhoenixGameDevelopment-09_10_2016-11_52_08-PM.jpg 1920w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-3923\" class=\"wp-caption-text\">Unity<br \/>09\/10\/2016 , 11:52:08 PM<br \/>Unity Personal (64bit) &#8211; P0Lab2.unity &#8211; New Unity Project &#8211; PC, Mac &amp; Linux Standalone*<\/figcaption><\/figure>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have followed a simple tutorial (HERE) to make a mirror in unity. This worked out well, and I also learned a little about Unity&#8217;s shader system in the process. It seems to use it&#8217;s own proprietary language called &#8220;Shaderlab&#8221;, but does allow for Cg shaders to be written within it. I wrote the shader [&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,17,10,11],"tags":[],"class_list":["post-3914","post","type-post","status-publish","format-standard","hentry","category-art-and-designs","category-p-0","category-software-and-games","category-spiritus-astrum","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\/3914"}],"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=3914"}],"version-history":[{"count":4,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/3914\/revisions"}],"predecessor-version":[{"id":3932,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/3914\/revisions\/3932"}],"wp:attachment":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/media?parent=3914"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/categories?post=3914"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/tags?post=3914"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}