Search Unity

ats color map ULTRA shader [RELEASED]

Discussion in 'Assets and Asset Store' started by larsbertram1, Oct 17, 2012.

  1. Veteran66

    Veteran66

    Joined:
    Jul 12, 2015
    Posts:
    21
    Version 3.0

    When i will add the Colormap Painting script to a new 5.6.2 Build and new Scenes (Assets in Build is: Colormap Ultra Shader V3,SampleScenes and Standard Assets)



    I get the error:

    Can`t add script
    Please fix compile errors before creating new script components.

    in Console:
    Use of UNITY_MATRIX_MV is detected. To transform a vertex into view space, consider using UnityObjectToViewPos for better performance.
    (Assets/Colormap Ultra Shader V3/Lux 2.01 Personal/Lux Shaders/Lux Core/Resources/Lux Deferred Library.cginc)

    Property (_HeightMaps) already exists. Use SetTexture instead.
     
  2. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    that is a warning and should not be a problem.

    hmm, do you have installed other custom shaders which use _HeightMaps?
     
  3. Veteran66

    Veteran66

    Joined:
    Jul 12, 2015
    Posts:
    21
    no only Colormap Ultra Shader V3,SampleScenes and Standard Assets in the build.

    please try self yout Colormap Ultra Shader V3.0 with Unity 5.6.2
     
  4. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i tried cmu in unity 2017.
    i get the error: "Property (_HeightMaps) already exists. Use SetTexture instead." as well.
    but it does not point to any line of code, the scripts actually use "SetTexture" and everything looks fine.
     
  5. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    Adam-Bailey and hopeful like this.
  6. xxhaissamxx

    xxhaissamxx

    Joined:
    Jan 12, 2015
    Posts:
    130
    is there any update on mobile performance or test ? i hope u can upload APk to test thanks
     
  7. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i do not recoommend this shader on mobile unless you have gloves made out of asbestos. i do not recommend any other terrain shader replacement as well due to the same reason: if you are targeting mobile even the built in shaders might be way too heavy.
     
    xxhaissamxx likes this.
  8. xxhaissamxx

    xxhaissamxx

    Joined:
    Jan 12, 2015
    Posts:
    130
    thanks for answer what about if terrain doesn't have grass or even tress and reduce camera view distance still hard to optimize it for mobile ?
     
  9. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    that does not make any difference: the pixel shader of each of the advanced terrain shaders be it rtp, cts, megasplat or cmu is much more complicated.
     
    xxhaissamxx likes this.
  10. xxhaissamxx

    xxhaissamxx

    Joined:
    Jan 12, 2015
    Posts:
    130
    thanks i want to use one of them to make terrain looks better on android devices thanks for help and sry for all this questions
     
  11. OfficialHermie

    OfficialHermie

    Joined:
    Oct 12, 2012
    Posts:
    482
    @larsbertram1

    Hello Lars, did somebody already tell you that your logic has the tendency to drive people (or is it just me?) crazy?
    I have no idea about your assets, and I'm trying to learn about it.

    In the asset store I see

    1) Colormap Ultra Terrain Shader 3.0, updated Jul 31, 2017
    2) ats Colormap ULTRA Terrain Shader, updated Aug 18, 2015

    1) has an update price, so I assume it's an update to 2), but that's not mentioned in the asset description.

    I know I will ask myself this again in 6 months, so it would be great (and perhaps also for others) if you could update the asset description.
    I have seen so nice, informative descriptions at the front page of some assets, it seems that Unity isn't restrictive on that, so it would be nice if you could make it so that it's easy to understand.

    Thank you very much.

    ps: I'm lurking on your assets since years, and I find myself Sherlock-Holmesing about them again and again, so I finally dare to ask you about it...
     
  12. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    well, things develop.
    2) is the successor of 1) in fact 2) has been rewritten from scratch and apart from the color map feature they do not have much in common.

    and thanks for the feedback.
     
  13. OfficialHermie

    OfficialHermie

    Joined:
    Oct 12, 2012
    Posts:
    482
    @larsbertram1 Huh??? You say that #2 (ats Colormap ULTRA Terrain Shader, updated Aug 18, 2015) is the newer version / successor of #1 (Colormap Ultra Terrain Shader 3.0, updated Jul 31, 2017)???
    Now you're getting confused yourself, aren't you?
     
  14. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    then simply take it the other way around. luckily the assets are not named 1) and 2) but have meaningful version numbers :)
     
  15. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175
    Unity3D 2017.1.0p5
    ColorMap Ultra 3.04
    Base shader = Parallax

    Shader compiler error:
    Shader error in 'Nature/Terrain/CMU-FirstPass-Parallax': undeclared identifier '_TerrainParams' at Assets/Colormap Ultra Shader V3/Shaders/Includes/CMU-Core.cginc(34) (on d3d11) Compiling Vertex program with DIRECTIONAL SHADOWS_SCREEN LIGHTMAP_ON DIRLIGHTMAP_COMBINED DYNAMICLIGHTMAP_ON LIGHTMAP_SHADOW_MIXING EFFECT_HUE_VARIATION _SNOW _WETNESS_FULL 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

    Terrain shows all white using, as usual, base map distance = 0, but it becomes pink using base map distance>0.

    PS: Tassellation shader doesn't show anything. Terrain becomes trasparent.
     
    Last edited: Aug 29, 2017
  16. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    ouch, that is quite embarrassing.
    i am uploading a hotfix for the parallax shader right now.
    you can either until it gets published or send me you invoice no. and email address so i can send you the fixed shader files.
    sorry, lars

    that one actually should work fine but might not be supported on your hardware?
     
  17. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175
    Others tassellation shaders works ! I use a Nvidia GTX 950.

    Tnx for fast support: Meanwhile i solved the parallax bug removing snow and water effects.
     
  18. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175
    I upgraded to 3.051: Tassellation and parallax shader are ok, but I had to set base map distance = 2000. Setting base map distance=0. I have full white (parallax shader) or trasparent (rassellation shader) terrain.

    Thanks mr. Lars !!!
     
    Last edited: Sep 1, 2017
  19. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    that is pretty strange – as it should make the shader not working properly... 0 should be the correct value.
     
  20. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175
    If i remove colormap asset and reinstall it, I'll lose terrain settings ?
    Can i load parameters from terrain material ?
    I think it's possible but i like be sure, before losing a lot of work.
     
  21. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i never tried that... but theoretically you should be able to just keep the material (that stores your settings).
    if you then remove all cmu components it will go pink.
    but i would expect that if you reload cmu it should be fine again. you might have to assign the shader manally.

    untested!
     
    frankadimcosta likes this.
  22. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
    Hello lars in Unity 5.6 I upgraded yesterday your color map ultra shader 3.0 and what is stange after that I have exception about Lux shader 2.02 (that I'm using too) it looks like that: upload_2017-9-12_12-19-47.png

    What should I do?
     
  23. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    well, you should have unity let do the upgrade :)

    edit edit!
    sorry it is quite difficult to answer and read from the screen shoot at the same time...
    using:
    RendererExtensions.UpdateGIMaterials(SnowGIMasterRenderers);
    should do the job (from the github version).
     
    Last edited: Sep 12, 2017
  24. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
    Hello thank you, but could you please be more clear? I tried lux 2.02 from github too and it has problem too ( also version from github very often creash and makes models pink, I use version from asset store now, but there is still that problem if I'll update ultra color map shader :)
     
  25. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    double click the error. then mono develop or visual studio should open and show the line that errors.
    replace it with the code from the post above.
     
  26. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
  27. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    you are welcome.
     
  28. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
    Hell its working now but still sometimes I have this and after that mdoels with your shader are pink, after reloading package everything is ok but is happen sometimes... upload_2017-9-13_19-2-30.png
     
  29. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i get a lot of these error – with all kind of different shaders.
     
  30. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
    So do you mean that this is unity issue and should give no problem if it is not in play mode?
     
  31. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i think it is a unity problem. simply reimporting the shader that bugs always fixes it for me.
     
  32. Jakub_Machowski

    Jakub_Machowski

    Joined:
    Mar 19, 2013
    Posts:
    338
  33. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175

    It WORKED !!! TNX !!!
     
  34. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    fine!
     
    frankadimcosta likes this.
  35. frankadimcosta

    frankadimcosta

    Joined:
    Jan 14, 2015
    Posts:
    175
    New error ! (Unity 2017.1.1p3)
    Shader error in 'Hidden/TerrainEngine/Splatmap/CMU-AddPass-Parallax': Fragment program 'frag_surf': Unrecognized sampler 'samplerunity_lightmap' - does not match any texture and is not a recognized inline name (should contain filter and wrap modes).
    (on d3d11)

    Compiling Fragment program with LIGHTMAP_ON DIRLIGHTMAP_COMBINED SHADOWS_SHADOWMASK
    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

    Can you help me ? TNX in advance.
     
  36. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i tested cmu version 3.051 in unity 2017.1.0f3 using mixed lighting and baked shadow masks: no errors!
    but your keywords look a bit awkward: when i open the frame debugger i get far less keywords...
     
  37. Manimor

    Manimor

    Joined:
    Sep 7, 2013
    Posts:
    21
    Hello, I've got a couple of questions:

    • Parallax mapping does not seem to work in VR. I use a Texture Dxt5, a Normal map dxtnm and a heightmap argb 16 bit. I can't seem to get any displacement how much I might increase extrusion.
    • Mesh blending, A cool feature. Why did it get axed in 3.0? Do 2.5 work with Unity 2017? What are the performance differences between 3.0 and 2.5? What makes 3.0 better? ;P
    • I'm using regular meshes with terrain material on, would mesh blending work on them? Is there any other way to get mesh blending?
    • Thanks for your time.
     
  38. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i can not say much about this as i do not have any vr device.

    because the whole effect just breaks as soon as you activate ssao – which is kind of a standard effect nowadays. not to mention light mapping...

    as far as 2.5 is concerned: i have not tested it in 2017. it is faster than 3.0 but – apart from mesh blending – offers way less possibilities like dynamic snow or advanced wetness.
     
  39. Manimor

    Manimor

    Joined:
    Sep 7, 2013
    Posts:
    21
    Thanks for the pretty fast response.

    Okey, that makes sense. Light mapping is pretty important!

    Snow I don't really need but water is a pretty cool feature.

    I think v3.0 is the most useful after all. Just wish I could get that parallax going. Is there anything I could be missing? Any setting that may be forgotten. Parallax mapping is the only technique to get you cheap displacement in VR. Thanks!
     
  40. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    it should work... does parallax mapping of the standard shader work in vr?
    you may check the per layer extrusion settings. that is all i can think of right know.
     
  41. Manimor

    Manimor

    Joined:
    Sep 7, 2013
    Posts:
    21
    Hi Lars,

    I couldn't find a working solution for the Standard Shader, didn't try long though.

    But the Legacy Parallax Mapping worked just fine:

    Settings


    No Parallax/Parallax


    When I try on a standard terrain, with


    I get: With parallax/Without:


    I'm using the sames textures in both methods.

    Edit: Ramped up Extrusion under "Extrusion and Blending" to 2, didn't have any noticable effect.

    Edit2: And to answer your question: Yes, it works in VR, the textures become a little stretches, and you get no shadowing but it works
     
    Last edited: Oct 1, 2017
  42. Redrag

    Redrag

    Joined:
    Apr 27, 2014
    Posts:
    128
    I am using v2.5 - on Unity 5.3.4. I am having trouble with the paint tool. If I let it copy the current color map, the map is just black (but I can paint on it). If I copy my colormap and change the settings to ARGB 32 bit (or any of the others specificed) I cannot paint on it..
     
  43. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    i do not have any 5.3. version any more, sorry. but i tested it with 5.1. – were it works fine.
    especially this behavior does not make much sense: argb32 is exactly the format which is needed.

    edit: i also tested it in 5.4.3 – where it works as well. so i guess that there is something wrong with your texture/settings.
     
    Last edited: Oct 11, 2017
  44. Redrag

    Redrag

    Joined:
    Apr 27, 2014
    Posts:
    128
    This is the file generated by the script:

    upload_2017-10-11_15-34-53.png

    And this is my file:
    upload_2017-10-11_16-9-49.png

    I can't seem to get it quite the same. Weirdly the copied image is RGB 24 bit, so in this case I have copied that setting...
     
  45. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    what happens if you set it manually to argb 32bit?
     
  46. czokka

    czokka

    Joined:
    Mar 14, 2017
    Posts:
    13
    Ok so I baught v3 and i cannot tell what im doing wrong. Ive been working on this for the past 2 weeks and nothing works. I have chewed my way trough the documentation multiple time going step by step. I have tried every single slider and button. My main problem is that i cannot even paint my layers propely. only the first one of my 8 layers shows up and nothing i do changes that. Im using a raw16 from world machine for my terrain and mega scans for the detail textures. I have them set up correctly but nothing seems to work.
     
  47. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    sorry, but that is just a few of information. what does not work?
    do you get any errors?
     
  48. czokka

    czokka

    Joined:
    Mar 14, 2017
    Posts:
    13
    Firstly id love to thank you for your hard work upgrading unitys dogshit terrain system. Other have got amazing results and im trying to achieve the same. No i am not getting any errors. However my entire terrain is flooded with the first detail texture i added. everything seems to function except actually blending between textures. Im quite confused as i cant find any height clamping setting which should allocate where the rocks and grass should go. I just eventual gave up with the automated assignment. So instead i tried to manually paint in my rock and grass. No matter what i do they will simply not appear at all. On an earlier try i was able to see the different color from the rock detail appear but only if i zoomed out very far.
     
  49. czokka

    czokka

    Joined:
    Mar 14, 2017
    Posts:
    13
    sorry for all the terrible typos ill edit it now
     
  50. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    5,341
    hmm, first i would check the height maps.