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

Struct variable 'globalWaterData' is ignored. #38

Closed
MCPGNZ opened this issue Dec 20, 2017 · 0 comments
Closed

Struct variable 'globalWaterData' is ignored. #38

MCPGNZ opened this issue Dec 20, 2017 · 0 comments
Assignees

Comments

@MCPGNZ
Copy link
Contributor

MCPGNZ commented Dec 20, 2017

After importing the package we see shader compilation error:

Fragment program 'frag': Struct variable 'globalWaterData' is ignored. Only instancing constant buffers can have struct variables

Reason: In the Unity 2017.3 , the shader compiler requires static keyword on globally shared struct variables.

This will be integrated in the new release.
The quick fix for those who need it is to go to the WaterLib.cginc and change the line declaring data
from:
WaterData globalWaterData;
to:
static WaterData globalWaterData;
and reimport the shaders.

unity: 2017.3.0f3
uws version: 2.0.0b3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant