Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix compilation warnings on shaders from VFX graphs #7893

Open
wants to merge 2 commits into
base: 2022.2/staging
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Packages/com.unity.render-pipelines.universal/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
Version Updated
The version number for this package has increased due to a version update of a related graphics package.

### Fixed
- Fixed an issue where a compilation of any VFX Graph caused warnings when using URP.

## [14.0.6] - 2023-03-24

This version is compatible with Unity 2022.2.13f1.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,9 @@ float3 VFXGetCameraWorldDirection()
#if defined(_GBUFFER_NORMALS_OCT)
#define VFXComputePixelOutputToNormalBuffer(i,normalWS,uvData,outNormalBuffer) \
{ \
float2 octNormalWS = PackNormalOctQuadEncode(normalWS); \ // values between [-1, +1], must use fp32 on some platforms
float2 remappedOctNormalWS = saturate(octNormalWS * 0.5 + 0.5); \ // values between [ 0, 1]
half3 packedNormalWS = PackFloat2To888(remappedOctNormalWS); \ // values between [ 0, 1]
float2 octNormalWS = PackNormalOctQuadEncode(normalWS); /* values between [-1, +1], must use fp32 on some platforms */ \
float2 remappedOctNormalWS = saturate(octNormalWS * 0.5 + 0.5); /* values between [ 0, 1] */ \
half3 packedNormalWS = PackFloat2To888(remappedOctNormalWS); /* values between [ 0, 1] */ \
outNormalBuffer = float4(packedNormalWS, 0.0); \
}
#else
Expand Down