{"id":13663455,"url":"https://github.com/n-yoda/unity-sky-mesh","last_synced_at":"2025-04-25T17:30:51.327Z","repository":{"id":153615939,"uuid":"44446563","full_name":"n-yoda/unity-sky-mesh","owner":"n-yoda","description":"Render Skybox (sky sphere) by user-defined sky mesh.","archived":false,"fork":false,"pushed_at":"2015-11-18T10:44:06.000Z","size":443,"stargazers_count":41,"open_issues_count":1,"forks_count":9,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-11-10T20:37:31.441Z","etag":null,"topics":["shaders","skybox","unity"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/n-yoda.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-10-17T17:08:17.000Z","updated_at":"2023-12-16T12:32:03.000Z","dependencies_parsed_at":"2023-04-19T16:41:43.651Z","dependency_job_id":null,"html_url":"https://github.com/n-yoda/unity-sky-mesh","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/n-yoda%2Funity-sky-mesh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/n-yoda%2Funity-sky-mesh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/n-yoda%2Funity-sky-mesh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/n-yoda%2Funity-sky-mesh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/n-yoda","download_url":"https://codeload.github.com/n-yoda/unity-sky-mesh/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250861950,"owners_count":21499190,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["shaders","skybox","unity"],"created_at":"2024-08-02T05:02:27.923Z","updated_at":"2025-04-25T17:30:51.070Z","avatar_url":"https://github.com/n-yoda.png","language":"C#","funding_links":[],"categories":["C\\#"],"sub_categories":[],"readme":"# SkyMesh shader for Unity\nDo you want to use your own **sky sphere model** made in 3D modeling software (e.g. Blender, Maya)?\nIn that case, the SkyMesh shader in this repository will be **useful and efficient**.\n\n![screenshot.png](screenshot.png)\n\n## How to use?\n### 0. Think twice if you really need to render sky with your mesh.\nIn many cases, you should use [Skybox](http://docs.unity3d.com/Manual/class-Skybox.html) instead,\nbecause **SkyMesh is not suitable for GI**.\nUnity can import several types of textures as [Cubemaps](http://docs.unity3d.com/Manual/class-Cubemap.html).\nEven if you don't want to use Cubemaps, **you'd better write your custom Skybox shader** if the mapping between view direction and color (or texture coordinates) is simple enough.\n\n### 1. Import your sky model, and create SkyMesh material.\nYou can also use builtin meshes.\nCreate a material and select \"Custom/SkyMesh\" as the shader.\n\n### 2. Choose radius of the sky. Finite or infinite?\nUnity's skybox is rendered as **a sphere of infinite radius** when camera mode is perspective.\nThis means sky appearance doesn't depend on translation of camera,\nbut depends only on rotation and field of view of it.\nIf you prefer this behaviour, **uncheck Finite Radius checkbox** of your material.\n\nIf your camera mode is orthographic or you prefer camera-translation-dependent sky,\n**check Finite Radius checkbox**.\n\nIn both cases, the sky mesh **doesn't need to be within the view volume** (read below).\n\n### 3. Choose a renderer. MeshRenderer or CommandBuffer?\n#### CommandBuffer\nAttatch SkyMesh script to your main camera, and fill all the properties.\n\"Camera Event\" is recommended to be \"After Image Effects Opaque\" for efficiency.\n#### MeshRenderer\nCreate GameObject, and attach MeshFilter with your mesh and MeshRenderer with the SkyMesh material.\nIn order to avoid frustum culling, you have to scale the object or\n[Mesh.bounds](http://docs.unity3d.com/ScriptReference/Mesh-bounds.html).\n\n## Features\n### The sky is rendered even if far away from the camera.\nSky meshes will be rendered even if the actual meshes are outside camera view volumes.\nThe mesh is rendered as if it is stuck on the far plane of the volume.\nIt doesn't cosume your depth buffer bits.\n\n### Efficient rendering order.\nThe rendering order is as efficient as builtin Skybox.\nThe areas hidden by opaque objects are culled by depth test.\n\n![render.png](render.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fn-yoda%2Funity-sky-mesh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fn-yoda%2Funity-sky-mesh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fn-yoda%2Funity-sky-mesh/lists"}