A Unity ID allows you to buy and/or subscribe to Unity products and services, shop in the Asset Store and participate
in the Unity community.
Discussion in 'Assets and Asset Store' started by jbooth, Aug 9, 2017.
I will try to figure it out.
Can you help me with MicroSplat under Unity beta9? I have a job to do under the beta9 for a client :/ don't ask my why :/ and microsplat sends me an error message on the texture array script "invalid texture size". I used the same four textures already with micrsplat without problems. If you need more information, I can make a screesnhot of the error message, when I am back at my pc.
Appriaciate every help!
Don't use Beta's, Unity broke Graphics.CopyTexture.
I don't suppose this is the fix we've been waiting for? (It's listed under Features, not Fixes, for b10, so I assume not...)
Graphics: Added texture 3D CopyTexture support.
No, that’s what broke it in version 4.
I see, I misread it entirely. So do you know if Unity is working on this...or aware of it? What can we do to get it moved to high priority?
It's been bugged, posted on the beta forums by several users, and @Tim-C said he'd poke the dev's about it but no luck so far. It basically breaks all 13 of my assets, along with a bunch of other ones, so hopefully they won't ship 2018.3 with it.
I see. Thanks for the info!
PM me, along with a description of what issues your actually having..
Oh so please bring support for hdrp, I love microsplat and the results achieved, but I would love it even more if I could use it with hdrp
I'm sure/know he will after 2018.3 has a stable release. No point in doing it many times for beta releases.
I totally agree, just showing my interest in the product
Hi, I'm trying to build my game in unity 2018.2
I've used microsplat in previous versions of unity, like 5.6.
It worked fine in editor and build.
But in 2018.2, it shows error in the build, several hidden shaders are not found, this was not in the old builds, any ideas how to avoid these errors? Should I include microsplat shaders in some places?
Can you post the error?
I don't know about @Harekelas but this has been a problem in my builds for a very long time and I have not been able to resolve it despite your suggestions. You did say it was not a big deal (just an early out) so I have not really followed it up.
Shader 'MicroSplat/Landscape': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Oh, this thing. Yeah, never been able to figure out what it wants, but it doesn’t cause any problem and it actually finds the shader at runtime anyway..
So I got 2018.3b12 and opened my project...and get this error-- any suggestions?
Assets\MicroSplat\Editor\TextureArrayConfigEditor.cs(1308,123): error CS0104: 'TextureCompressionQuality' is an ambiguous reference between 'UnityEditor.TextureCompressionQuality' and 'UnityEngine.TextureCompressionQuality'
I think Unity 2018.3 betas are still broken for CopyTexture anyway. At least it seemed to be still broken in the latest b12 when I did a quick test yesterday, so maybe no point trying it with Microsplat just yet.
Darn it, they said that was fixed in b12!
are microsplat shader for terrain will be support for beta 3's terrain instancing?
It will, or does. If only that CopyTexture bug in Unity would be fixed in time..
I've met this error when building my game in unity 2018, it was not present in unity 5.6:
Shader error in 'Hidden/MicroSplat/Survisland_High_Ultra_Base2035933029': maximum ps_4_0 sampler register index (16) exceeded at line 1553 (on d3d11)
Compiling Fragment program with UNITY_PASS_FORWARDADD SPOT SHADOWS_DEPTH SHADOWS_SOFT
Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP SHADER_API_DESKTOP UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_LIGHTMAP_FULL_HDR
here are the features I've enabled:
Would love to know the sampler cost for each feature. I've tried to tweak some settings: enable/disable parallax or tessellation, enable or disable global snow. But there still will be index exceeded error. Any suggestions?
PS: this error also does not show up when I choose different features in the material, but if I try to compile and show the shader, this error shows up.
There's no way to get an exact sampler count other than to go over it. This is because the sampler count is actually dependent on lighting as well as the shader itself- for instance, if the shader needs to sample a light probe it can require an extra texture for the light probe. The closest approximation would be to look at the shader's texture count (you can see this by selecting the shader) and you'll see how many MicroSplat is actually allocating..
Shader 'MicroSplat/Survisland_Mid': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Shader 'MicroSplat/Survisland_High': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Shader 'MicroSplat/Survisland_High_Ultra': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Shader 'MicroSplat/Survisland_Low': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Shader 'MicroSplat/Survisland_VeryLow': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
Shader 'MicroSplat/Terrain 0,0': dependency 'AddPassShader' shader 'Hidden/MicroSplat/AddPass' not found
These are the errors in the output log in a build game.
Yeah, these don't seem to cause any issue- the shader actually gets found at runtime, so I'm not sure why the build log throws these errors..
Bad news..it looks like they introduced the Graphics.CopyTexture bug into 2018.2.19f1 and it's still there in 2018.3.0f1
Of course they did..
I guess I can't vote for it to be fixed since they think it's "already fixed" (for 2019.1) but I hope they still intend to fix 2018.2 and 2018.3
I really hope they fix this - I've seen it mentioned a few places and it would be a real shame to impact amazing assets like MicroSplat, especially with all the hard work you put into developing this.
Man, been waiting for the fix so we can update our project :/ Worrying that they think it is fixed.
Thanks for the heads up on this one. That was poor form from Unity. I wonder whether this needs to have a new bug report submitted given that they closed the original one?
We have a large game world, so we're loading and unloading Unity and mesh LOD terrains in additive scenes. We've decided to put some environmental objects like rocks into the main scene, since they are visible from most areas of the map. (This is a change of plans since I chatted with you on Discord a few days ago.)
These have the Microsoft blendable object component on them, but that doesn't work when there's no terrain underneath the rocks initially at runtime -- the component shows an error: Can't find terrain underneath. If I toggle that component off and on again, then the rock turns pink, with a second material slot added, but no material assigned to it, and two errors: Terrain shader not setup for blending, and Terrain does not have blending data. We could manually assign a material with the Blend shader, but even when I do that, the blending doesn't work, and the MS Blend component still shows those errors.
Also, for the rocks that initially have a mesh LOD terrain (with MS mesh shader), they simply lose the second material entirely at runtime, and the MS Blend component shows an error "Terrain not detected."
So....is there a way to get this to work with additive terrain scenes?
Well, you're going to need to figure out a way for it to access the data it needs when the terrain isn't there. The object blending uses a custom height/normal map that gets generated so it can figure out the terrain topology in the shader, as well as the bounds of the terrain. At startup, it finds the terrain the object is on and caches that stuff. You could change it to cache this at editor time or manually enter the data- the reason it does this is so you can move objects and terrains around and everything just works as it should.
Okay, thanks for the pointers. We'll look into it.
Also: After pulling the most recent MS updates, I've started getting some errors when I change settings and regenerate the MicroSplat material. We use Assembly Definitions so I have to manually move all Editor scripts into a main MS/Editor folder, and I suspect I did something wrong there, but I've reviewed and recopied them and can't figure it out, and I keep getting the errors. Sorry for the bother, but can you see what it might be from these errors?
Shader error in 'Hidden/MicroSplat/AmethystTerrain_x6_y1_Base-1289839447': 'ApplyAntiTilePerTex': no matching 5 parameter function at line 2584 (on d3d11)
Shader error in 'MicroSplat/AmethystTerrain_x6_y1': 'ApplyAntiTilePerTex': no matching 5 parameter function at line 2584 (on d3d11)
Shader error in 'MicroSplat/AmethystTerrain_x6_y1_BlendWithTerrain': 'ApplyAntiTilePerTex': no matching 5 parameter function at line 2586 (on d3d11)
If your pulling from the github it may be a bug I introduced.
yes I was, so will pull again, thanks!
Just confirming this is the same 2018.3 bug. Upgraded from 2018.2 to 2018.3 (release) and updated microsplat to latest on the store and it throws this. I am guessing the release version of 2018.3 is still incompatible with Microsplat until that copy texture bug is fixed. Just looking for confirmation that we would not be able to use MS on 2018.3 at this point.
NullReferenceException: Object reference not set to an instance of an object
MicroSplatTerrain.RestorePrototypes () (at Assets/MicroSplat/Core/Scripts/MicroSplatTerrain.cs:245)
MicroSplatTerrain.Sync () (at Assets/MicroSplat/Core/Scripts/MicroSplatTerrain.cs:208)
MicroSplatTerrain.OnEnable () (at Assets/MicroSplat/Core/Scripts/MicroSplatTerrain.cs:53)
line with the null ref.
if (protos.diffuseTexture != cfg.sourceTextures.diffuse)
I have not had the copy texture issue since upgrading to the released version from the beta, so as far as I know they actually fixed that bug. This looks like you don't have your config assigned correctly in the MicroSplatTerrain component- check the debug section, maybe the upgrade borked the reference or something.
Are others running well on 2018.3? Been holding off because of CopyTexture() bug but if that's all clear I'd love to see the perf changes for many terrains on iOS....
Couple questions about Snow:
1) Having weird streaking once the UV Scale is above 1. See screenshots (UV of 3 and 50). Is something misconfigured?
2) On objects with MS blending, as I increase the amount on that material, it creeps in VERY slowly along the blended areas, and then suddenly the entire object has snow on it. I thought it would only affect the top surfaces?
Can you attack a screenshot of your material settings (top section) so I can repro?
sure, here you go
I have the same error. How should the debug menu be setup to work?
There’s a rollout on the MicroSplatTerrain component labeled debug, click to open it.
I've successfully managed to get Microsplat working with 2018.3 and all the paid modules, which is great.
Now I was just wondering if there's any plan to get it integrated with the new terrain instancing system? If I try to activate the flag (Draw Instanced) I get the whole terrain disappearing and I get the error below:
"Shader error in 'Hidden/MicroSplat/_Base-640971990': invalid subscript 'instanceID' 'UnitySetupInstanceID': no matching 1 parameter function at line 2201 (on d3d11)"
I suppose there would be performance benefits by using this flag, am I right?
Thank you for your time!
Also, regarding snow on MS Blendable objects: There's no "G" button on that component to sync the snow with Enviro weather....possible to add?
You need to regenerate the shader in 2018.3, otherwise MicroSplat won't write out the requited #pragma's because they don't compile in 2018.2 correctly.
On which property? Those apply to shader properties, not components. If you make them global it will apply to the terrain blending shader as well.
I meant on the mesh objects with the Blendable component. I have "G" toggled on and working nicely on the Unity and mesh terrains, but no snow is accumulating on the blendable objects at runtime when Enviro snows....so I was looking for something I might have missed. But maybe it's part of the above issues....
I know but how should it look to be setup correct? How do I know if my is setup correct?