셰이더 에셋은 셰이더 오브젝트를 정의하는 Unity 프로젝트의 에셋입니다. 확장자가 .shader
인 텍스트 파일입니다. 셰이더 코드가 포함되어 있습니다.
새 셰이더 에셋을 생성하려면 메인 메뉴의 Assets > Create > Shader 또는 Project View 컨텍스트 메뉴를 사용합니다.
Unity 프로젝트에서 셰이더 에셋을 선택하면 인스펙터는 정의한 셰이더 오브젝트에 관한 기본 정보를 표시합니다. 또한 컴파일을 제어하고 컴파일된 코드를 확인합니다.
인스펙터의 임포트 설정 섹션에서 셰이더 에셋의 기본 텍스처를 설정할 수 있습니다. 새로운 머티리얼이 이 셰이더로 생성될 때마다 텍스처가 자동으로 할당됩니다.
인스펙터의 임포트된 오브젝트 섹션에서 셰이더 오브젝트 자체 관련 설정과 셰이더 컴파일러가 이를 처리하는 방법을 보고 편집할 수 있습니다.
표면 셰이더의 경우 Show generated code 버튼은 Unity가 단순화된 소스 파일에서 생성한 코드를 나타냅니다. 생성된 코드를 커스터마이즈하려면 셰이더 소스 파일에 복사하여 붙여넣으면 됩니다.
Compile and show code 팝업 메뉴를 사용하여 다음을 수행할 수 있습니다.
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thank you for helping to make the Unity documentation better!
Your feedback has been submitted as a ticket for our documentation team to review.
We are not able to reply to every ticket submitted.