Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

► Advanced Dissolve ◄

Discussion in 'Assets and Asset Store' started by Arkhivrag, Feb 13, 2018.

  1. TakuyaBabuya

    TakuyaBabuya

    Joined:
    Dec 17, 2020
    Posts:
    9
    upload_2022-10-15_22-23-59.png
    Hi, I'm trying to generate shaders but it's being greyed out, followed all the steps in the documentation.

    upload_2022-10-15_22-25-8.png

    Using Unity 2021.3.5f1
     
  2. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Did you copy HLSL shader from the shadergraph first?
     
  3. TakuyaBabuya

    TakuyaBabuya

    Joined:
    Dec 17, 2020
    Posts:
    9
    upload_2022-10-16_3-57-3.png

    According to the documentation, I've clicked on the Copy Shader button and upon right clicking the .Shader file, the option was greyed out
     
  4. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    What is Unity version?
    Send me shadergraph file (with asset purchase invoice) on support e-mail: support@amazingassets.world
    I will check it.
     
    TakuyaBabuya likes this.
  5. z_yq

    z_yq

    Joined:
    May 3, 2017
    Posts:
    16
    I have purchased this resource pack, but there is a gradient material, how can I fade it
    upload_2022-10-17_14-19-21.png upload_2022-10-17_14-19-45.png This is my custom material
     
  6. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    If you need dissolve effect to be affected by gradient, then you can make it using Shader Graph:
    upload_2022-10-17_12-5-45.png

    Advanced Dissolve.gif

    But modifying custom hand-written shaders (as your GradientMesh.shader) is not supported.
     
  7. DeuSens

    DeuSens

    Joined:
    Sep 23, 2015
    Posts:
    3
    Hi, I am trying to test the demo and build it to check its performance in Oculus Quest 2.
    The demo doesnt even run, a lot of Shader errors pop up. I am using URP but also tested in HDRP in case URP was the problem but I got similar results.

    upload_2022-10-18_10-50-56.png

    I am using Unity 2020.3.40f1 and URP 10.10.1
    I have also tested Unity 2021.3.11f1 and URP 10.10.1 and HDRP 12.1.7
     
  8. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    upload_2022-10-18_16-30-8.png
     
  9. DeuSens

    DeuSens

    Joined:
    Sep 23, 2015
    Posts:
    3
    Ok... I am so dumb xD
    The sice of the file name was shorter than its full length and I couldn't read that small detail... Thanks
     
    Arkhivrag likes this.
  10. ist-hoshino

    ist-hoshino

    Joined:
    Oct 3, 2022
    Posts:
    1
    Hi.
    When I try to import this asset, I get many errors.
    They are CS0246 and CS0115. Below are some of them.
    Am I not allowed to use assets in this version?

    -------
    Assets/Amazing Assets/Advanced Dissolve/Editor/Material Editors/Universal/BakedLitShader.cs(10,54): error CS0246: The type or namespace name 'BaseShaderGUI' could not be found (are you missing a using directive or an assembly reference?)
    Assets/Amazing Assets/Advanced Dissolve/Editor/Material Editors/Universal/BakedLitShader.cs(24,53): error CS0246: The type or namespace name 'MaterialHeaderScopeList' could not be found (are you missing a using directive or an assembly reference?)
    Assets/Amazing Assets/Advanced Dissolve/Editor/Material Editors/Universal/BakedLitShader.cs(49,30): error CS0115: 'AdvancedDissolve_BakedLitShader.OnGUI(MaterialEditor, MaterialProperty[])': no suitable method found to override
    ...
    -------

    Using Unity 2021.1.9f1, URP
     
  11. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Unity 2021.1 isn't supported, as it is not the LTS version.
    Use the latest 2021.3 LTS version.
    After updating Unity, remove asset from project, clear Asset Store cache folder and re-download it using package manager.
     
  12. LittleRookey

    LittleRookey

    Joined:
    Feb 5, 2019
    Posts:
    1
    Hi is it impossible for this asset to have dissolve effect on a text meshes?
    What I'm aiming here is to have dissolve effect on a Mesh Renderer.
    Can someone recommend me specific setting for this of Advanced Dissolve shader?

    upload_2022-11-1_18-41-5.png upload_2022-11-1_18-42-15.png

    Oh I think I saw the post you posted about Text Mesh Pro shader.
    Can you share that one if possible?
     
    Last edited: Nov 1, 2022
  13. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    TextMesh Pro package is inside Shaders folder. Just import it.
     
  14. BusterDev

    BusterDev

    Joined:
    Mar 21, 2022
    Posts:
    18
    Greetings. When I follow the instructions on an object I create it works fine (not glow effect I'm after but that's a another day.) When I try it exact same way on assets Ive purchased it doesn't. They are just solid till I move the clip slider to a certain point then the object changes completely to the edge color, then as move it more the entire object goes transparent. You dont get any of the cutout effect.

    Im too new to Unity to diagnose the issue. What should I be considering?
     
  15. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Looks like your meshes have no correct UV coordinates.
    How do they look with any built-in shader and diffuse texture assigned, not with those textures that came with asset, but any other?
     
  16. BusterDev

    BusterDev

    Joined:
    Mar 21, 2022
    Posts:
    18
    Ok between testing a few things then discussing issue over at Synty Studios, its seems thats most likely the problem. Their UVs are done a bit different. Was suggested to ask if theres an option to use the shader to dissolve based on world space instead of object base? Or any other work around you can think of?
     
  17. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    upload_2022-11-5_21-48-14.png
     
  18. BusterDev

    BusterDev

    Joined:
    Mar 21, 2022
    Posts:
    18
    Ok, tried out those settings and if use Screen Space the effect is not as cool as on object with normal texture map but I can live with it. Thanks a lot :)

    One more question... while probably not use it in this project because figure it will clash with the low poly/texture style; but how to you get the line to look that cool neon like effect in the vid?
     
  19. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Which one, exactly?
     
  20. BusterDev

    BusterDev

    Joined:
    Mar 21, 2022
    Posts:
    18
    was referring to the red in this video
    but basically any of them. The way the cut lines light up.
     
  21. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Check Advanced Dissolve\Example Scenes\Demo Scenes folder.
    Or download free demo version from the store page description.
     
  22. Honoki_

    Honoki_

    Joined:
    Sep 15, 2014
    Posts:
    9
    Hi! I just got the asset from the store and is experiencing the same issue. I have used 2021.3.5f1 to test.
    Should I downgrade my unity to remove the errors? Or updating my Editor to the latest will fix it? I am thinking of upgrading it to 2021.3.14f1
     
  23. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Update Unity to the latest LTS version. Then remove AD asset from project, clear Asset Store cache folder and re-download asset using package manager.
     
  24. Thundermare1987

    Thundermare1987

    Joined:
    Jul 20, 2018
    Posts:
    7
    Hi, I am trying to create a custom shader graph with advanced dissolve. I follow the steps from the manual; Create AD node and plug it in the alpha clip threshold and endable alpha clipping. I copy the shader code and create a new unlit shader and then go to Advanced Disolve -> Generate Shader.

    However the new shader does not include any of the advanced dissolve properties or keywords and in the inspector the AD section is missing.

    Maybe its a Unity version issue? Or maybe i am missing something?
    I am using 2022.1.23f1 which is the latest build as i am writing this. upload_2022-12-4_9-54-15.png
     
  25. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Unity tech releases are not supported. Only LTS version.
     
  26. Thundermare1987

    Thundermare1987

    Joined:
    Jul 20, 2018
    Posts:
    7
    Yeah, I guess i'll wait for the next update.
     
  27. SpaharGR

    SpaharGR

    Joined:
    Dec 5, 2012
    Posts:
    11
    Hello.

    I would like to achieve a construction effect for a building. I'll demonstrate the desired result with an image. As seen below I would like for the building to be on an white transparent state, and gradually to be "filled" from bottom up as construction is progressing. Can this be achieved with Advanced Dissolve? I understand that technically this may not be a dissolve effect, but I see from examples and doc that the part of gradually showing more of the building is achievable with an inverted dissolve. What about the part of showing the white transparent part instead of nothing?

    Thanks a lot.

    construction_effect.jpg
     
  28. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    With dissolve shader - no. As top side of your mesh will be cutoff (removed from the rendering) completely and the same time you are asking to render it with some-kind of transparency. This is not possible.

    It may be achieved using custom transparent shader - top side semitransparent with alpha 0.5 and bottom part with alpah 1.0. But in this case you may encounter some ZWrite problems, like all transparent shaders have.

    The better solution would be to use two materials, one for dissolving and another for rendering transparency.
     
  29. LucasPignataro

    LucasPignataro

    Joined:
    Apr 11, 2019
    Posts:
    2
    i have an error in AdvancedDissolve_LitShader , headerStateKey doesent exist
     
  30. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Update Unity to the latest LTS version (2020.3.43 or 2021.3.16), then remove AD folder from project, clear Asset Store cache folder (Amazing Assets subfolder) and re-download AD using package manager.
     
  31. The11thAlchemist

    The11thAlchemist

    Joined:
    Aug 10, 2020
    Posts:
    30
    I'm having the same problem as mentioned above where the Advanced Dissolve options are not visible when shader is assigned to a material. I am using the recommended 2021.3.16 LTS. Initially I tried converting the Synty Modular Character Shadergraph to an Advanced Dissolved Shader as per the instructions but it didn't work. I thought maybe the Synty shader was too complicated so I made a couple basic Lit and Unlit shadergraphs and followed the instructions to create a new unlit shader and copy the shadergraph....but still didn't work.
    upload_2023-1-8_1-32-53.png
     
  32. The11thAlchemist

    The11thAlchemist

    Joined:
    Aug 10, 2020
    Posts:
    30
    Forgot to mention I get a "Undefined custom material editor." error
     
  33. The11thAlchemist

    The11thAlchemist

    Joined:
    Aug 10, 2020
    Posts:
    30
    Did a little more testing by adding the material to the AD Keywords Controller, AD Properties Controller, and AD Geometric Cutout Controller in the XYZ tutorial scene. The characters dissolve when I move Pivot Point so it appears the shader is working but not displaying the dissolver options and parameters within the material when the shader is assigned.
     
  34. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    It may happen only in the case if using AD version designed for Unity 2020.3 inside Unity 2021.3.

    Remove AD folder from project, clear Asset Store cache folder (Amazing Assets subfolder) and re-download AD using package manager.
     
  35. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    Hi there,
    Thanks for the awesome plugin, it's already well integrated in our project.

    I started a new effect using screen space mapping, kind of a hologram. However it seems that the scale and thus the tiling is mesh dependent (to have the same on screen effect I sometimes set 700 sometimes 4 in tiling). Is there a way to specify a world/screen scale for this mapping ? Or an easy way to temper this in the shaders ? (I'm only using the Metallic SM4 atm)

    Or I might have overlooked something, wrongly setting keywords maybe ?

    I've seen that there is only 6 parts to check in the shader, an likely the first one would hold my answer, as it seems it's the only one that access UVs (l.814 AdvanceDissolve.cginc), the step that follows is the one that actually gets the custom map tiling (L. 829)
    Code (CSharp):
    1.     #ifdef _DISSOLVEMAPPINGTYPE_SCREEN_SPACE
    2.         float2 screenUV = dissolveMapUV.xy / dissolveMapUV.w;
    3.  
    4. screenUV = screenUV * VALUE_MAP1_ST.xy + VALUE_MAP1_ST.zw + VALUE_MAP1_SCROLL.xy * TIME;
    5.  

    Thanks for your answer.

    upload_2023-1-27_22-6-27.png

    Example of too meshes with the same params but different resulting patterns :

    upload_2023-1-27_22-21-43.png
     
    Last edited: Jan 28, 2023
  36. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Looks like you are using very old version. ScreenSpace mapping already has option for constant UV scale.
    Advanced Dissolve.gif
     
    Whatever560 likes this.
  37. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    I'll update ;), yeah sorry for that, I've been using the dissolve effect for a long time now ...
     
  38. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    So it was quite an extensive process, indeed I had a very old version integrated and had to do quite some refactoring. However the new controllers are nice and helpfull.

    I have but one issue though, the secondary maps are not shown in the standard shader when I swap to the dissolve metallic. In the past there was the SM4 shader distinction, I believe it's not needed anymore but still I'm not sure of what is happening.

    I'm swapping the standard shader to the dissolve shader at runtime, maybe there is an issue with the keywords ?

    Details maps are correctly displayed in both editors.
    upload_2023-2-1_11-29-57.png

    Dissolve metallic without details showing
    upload_2023-2-1_11-28-45.png

    Standard with details showing
    upload_2023-2-1_11-29-34.png
     
    Last edited: Feb 1, 2023
  39. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Try comment (or remove) lines 6-30 inside Advanced Dissolve\Shaders\Built-in\Core\Limits.cginc file.
    This shouldn't be necessary, but...
     
    Whatever560 likes this.
  40. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    I went on and also removed the limits for the unlit shader as I had a blending issue hoping it'll fix it. I'm not targeting mobile/low end anyway. Thanks it works now.
     
  41. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    Is there a way to detect that the shader is or is not one of your dissolve shader in a build ?
    Utilities.IsShaderAdvancedDissolve can only be used in editor.
    Thanks
    [Edit] : taking a look at the implementation there is actually a similar API on shaders themselves without the need to shader editor api. And it works this way

    Code (CSharp):
    1.  
    2.         public bool IsCutoutShader(Shader shader)
    3.         {
    4.             for (int i = 0; i < shader.GetPropertyCount(); i++)
    5.             {
    6.                 if (shader.GetPropertyName(i) == "_AdvancedDissolveCutoutStandardClip") return true;
    7.             }
    8.  
    9.             return false;
    10.         }
    11.  
     
    Last edited: Feb 16, 2023
  42. Toby31

    Toby31

    Joined:
    Jul 7, 2014
    Posts:
    70
    Hi Arkhivrag,

    Just wanted to ask if the advanced dissolver works with terrains?

    Thanks in advance

    Toby
     
  43. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,998
    Package doesn't include terrain shaders.
     
  44. maramak

    maramak

    Joined:
    Mar 7, 2016
    Posts:
    13
    Hi! I have a problem using an asset on an Android device: the shader doesn't work there at all, although everything is fine in the Unity editor. For the test, I created a new scene in which there are several spheres with customized materials and a Mobile-Diffuse shader. An example of setting up one of the materials in the attached screenshot. I use Unity 20.3.27f1 and the latest version of the asset from the store. Rendering pipeline: Built-In. Maybe I forgot to setup something? If you need additional information, please let me know.

    UPD: The problem disappeared after upgrading to Unity 2021.3.22f1
     

    Attached Files:

    • 1.png
      1.png
      File size:
      329.2 KB
      Views:
      84
    Last edited: Apr 12, 2023
  45. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    Check that it is included in the build (or force it to be in shader variant manager)
     
  46. maramak

    maramak

    Joined:
    Mar 7, 2016
    Posts:
    13
    Can you check if I done this right? Because aftes adding the shader variant collection nothing has changed (
     

    Attached Files:

    • 2.png
      2.png
      File size:
      127 KB
      Views:
      82
    • 3.png
      3.png
      File size:
      168.9 KB
      Views:
      81
  47. Toby31

    Toby31

    Joined:
    Jul 7, 2014
    Posts:
    70
    Thanks you very much for the response and informing me.
    We are replacing the terrain with a plane and adding the dissolver custom shader to it and then adding the material to the cone for a players vision. but when the player walk's on the plane it is creating an instance of the material. Could this be related to the Advanced dissolver as I see in all of your examples the floor is always present?
     
  48. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    Not sure which keyword you'd need in your case, you can also try to put the shaders you use in the always included list.
    You might also get away by adding a dummy material correctly configured somewhere in one of your scenes.
     
  49. maramak

    maramak

    Joined:
    Mar 7, 2016
    Posts:
    13
    I've already tried adding a Mobile-Diffuse shader to this list, but the build failed because of the error that the shader has too many variants to include all of them in the build.

    That's just for this purpose, I made a separate scene with spheres and customized materials on them. However, for some reason, the build still lacks the necessary shader variants, if I understand correctly...
     
  50. Whatever560

    Whatever560

    Joined:
    Jan 5, 2016
    Posts:
    546
    That's unlucky, I've had some trouble getting the variants to add as well lately. Last thing I can think of is an issue with shader version on your device. Do you have a screenshot of your build ? (The spheres)