Unity의 스탠다드 에셋 패키지에는 여러 워터 프리팹(필수 셰이더, 스크립트 및 아트 에셋 등)이 포함되어 있습니다. 주간 및 야간 워터 프리팹이 별도로 제공됩니다.
이 문서에서 설명하는 워터 반사는 VR에서 작동하지 않습니다.
기존 프리팹 중 하나를 씬에 배치해야 합니다. 스탠다드 에셋 설치가 되어 있는지 확인해야 합니다.
프리팹은 워터에 타원 모양의 메시를 사용합니다. 다른 메시를 사용해야 하는 경우 워터 게임 오브젝트의 Mesh Filter 에서 메시를 변경할 수 있습니다.
심플 워터를 만들려면 평면형 메시에 스크립트를 연결하고 워터 셰이더를 사용해야 합니다.
반사/굴절 워터를 처음부터 만들려면 유사한 절차를 따라야 합니다.
다음과 같은 프로퍼티가 Reflective 및 Refractive 워터 셰이더에서 사용됩니다. 대부분은 Simple 워터 셰이더에서도 사용됩니다.
프로퍼티: | 기능: |
---|---|
Wave scale | 웨이브 노멀 맵 스케일링입니다. 값이 작을수록 워터 웨이브가 더 큽니다. |
Reflection/refraction distort | 웨이브 노멀 맵에 의해 반사/굴절이 왜곡되는 정도입니다. |
Refraction color | 굴절 시 추가되는 색조입니다. |
Environment reflection/refraction | 실시간 반사 및 굴절을 위한 렌더 텍스처입니다. |
Normalmap | 웨이브 모양을 정의합니다. 최종 웨이브는 각각 다른 방향, 스케일, 속도로 스크롤되는 두 노멀 맵을 결합하여 생성됩니다. 두 번째 노멀 맵의 크기는 첫 번째 맵의 절반입니다. |
Wave speed | 첫 번째 노멀 맵(첫 번째와 두 번째 숫자)과 두 번째 노멀 맵(세 번째와 네 번째 숫자)의 스크롤 속도입니다. |
Fresnel | 프레스넬 효과(보는 각도에 따라 반사와 굴절이 대비되어 보이는 정도)를 제어하는 알파 채널이 있는 텍스처입니다. |
나머지 프로퍼티는 Reflective 및 Refractive 셰이더에서 사용되지 않지만 사용자의 비디오 카드로 지원되지 않거나 더 단순한 셰이더를 백업으로 사용해야 하는 경우에 대비하여 설정해야 합니다.
프로퍼티: | 기능: |
---|---|
Reflective color/cube and fresnel | 보는 각도에 따라 워터 컬러(RGB)와 프레스넬 효과(A)를 정의하는 텍스처입니다. |
Horizon color | 수평선에서 표시되는 워터 컬러로, Simple 워터 셰이더에서만 사용됩니다. |
Fallback texture | 아주 오래된 비디오 카드로 시각 효과가 더 우수한 셰이더를 실행할 수 없는 경우에 워터를 표현하는 데 사용하는 폴백 텍스처를 정의합니다. |
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.