패스는 태그를 사용해 예상되는 렌더 방법 및 시기를 렌더링 엔진에 알립니다.
Tags { "TagName1" = "Value1" "TagName2" = "Value2" }
TagName1에 Value1을, TagName2에 Value2를 지정합니다. 태그를 원하는 수만큼 지정할 수 있습니다.
태그는 기본적으로 키-값 페어입니다. 패스 안에서 태그는 조명 파이프라인(앰비언트, 버텍스 리트, 픽셀 릿 등)에서 패스가 수행하는 역할과 기타 몇 가지 옵션을 제어하는 데 사용됩니다. Unity에서 인식하는 다음 태그는 서브셰이더가 아닌 패스 섹션 안에 있어야 합니다.
LightMode 태그는 조명 파이프라인에서 패스가 담당하는 역할을 정의합니다. 자세한 내용은 렌더링 파이프라인을 참조하십시오. 이 태그는 수동으로 사용되는 경우가 드물고, 조명과 상호작용해야 하는 셰이더는 표면 셰이더로 작성됩니다. 그러면 관련 세부사항이 모두 처리됩니다.
LightMode 태그의 가능한 값은 다음과 같습니다.
패스는 렌더링 파이프라인에서 데이터를 전달하는 방법을 변경하는 플래그를 나타낼 수 있습니다. 이 작업은 PassFlags 태그를 공백으로 구분된 플래그 이름인 값과 함께 사용하여 수행합니다. 현재 지원되는 플래그는 다음과 같습니다.
패스는 특정 외부 조건이 충족되는 경우에만 렌더링되어야 함을 나타낼 수 있습니다. 이렇게 하려면 값이 공백으로 구분된 옵션의 문자열인 RequireOptions 태그를 사용합니다. 현재 Unity에서 지원하는 옵션은 다음과 같습니다.
서브셰이더에도 태그를 지정할 수 있습니다. 서브셰이더 태그를 참조하십시오.
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.