Search Unity

► Wireframe shader - The Amazing Wireframe shader ◄

Discussion in 'Assets and Asset Store' started by Arkhivrag, Jun 11, 2014.

  1. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    I can not know. You can try importing your additional scripts now to your project and check which one conflicts with Wireframe shader.



    Amazing Assets - YouTube Facebook Twitter
     
  2. Damo9000

    Damo9000

    Joined:
    Nov 4, 2015
    Posts:
    7
    I love this shader!! Thank you for creating it!

    My issue is the Temp Meshes.

    Im using the Forever Endless Runner asset, which also created TEMP wireframes (so it can extrude or bend the meshes on a path)

    It seems impossible to get WireFrame Shader to work at all, because it relies on baked mesh coordinates. Is it possible to do a runtime thing, where the shader get work with the temp mesh at runtime?

    Im kind of a noob with Unity, so I dont know whats possible..

    Maybe you could point me in the right direction?

    Cheers
    Damien
     
  3. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    If target device supports Geometry Shader, you have no need to bake anything - just use Geometry Shaders inside material for those meshes.

    Otherwise you can always calculate wireframe data for mesh and bake it in runtime. Check Example_5 (Runtime) and Example_8 (Runtime Quad Converter) example scenes. For safety reasons make sure source mesh vertex count is less than 21.000.


    Amazing Assets - YouTube Facebook Twitter
     
  4. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    82
    I have a advice, you can make a editor, allow user make lines which user don't want make it show hide. I use it to make building frame line, some lines i want to hide.
     
  5. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    You can render wireframe from predefined texture. In this case you can have wireframe with any design and style.



    Amazing Assets - YouTube Facebook Twitter
     
  6. Fabrizio_1990

    Fabrizio_1990

    Joined:
    Feb 21, 2016
    Posts:
    5
    Hi, I have a product viewer with one model dowloaded runtime on webgl using assetbundles, this model can change depends of chosen product on website, these models can be 30/40 k verts. can i apply this shader runtime on webgl?
     
  7. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    As WebGL does not support Geometry Shaders, you have to bake wireframe data inside mesh (package includes such run-time tool) that later will be rendered by shader.
    But in this case make sure sure mesh has less than 21k vertices. If your mesh has more vertices, just split it in run-time. Even included tool can bake wireframe inside mesh with more than 21k vertices, this limitation is done only for security reasons not to reach Unity's default mesh vertex limitation.

    Wireframe shader working in webGL example: https://arkhivrag.itch.io/wireframe-shader



    Amazing Assets - YouTube Facebook Twitter
     
  8. Fabrizio_1990

    Fabrizio_1990

    Joined:
    Feb 21, 2016
    Posts:
    5
    S
    Thank you for response.
    Can i found an example or an automated tool to perform this operations ? after this i have to genereate an assetbundle with two meshes instead one ?
    http://www.sixaview.com/index.php?t...productMN=&selqua=289&idp=&istred=Y&prNUI=174
    Here is an example of what i need to reach (clic on the pyramid button)
     
  9. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
  10. Fabrizio_1990

    Fabrizio_1990

    Joined:
    Feb 21, 2016
    Posts:
    5
    Ok, Thank you.
    I've also seen that i can generate wireframe texture using contextual menu, can also be triggered by code?
     
  11. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    No, this feature is available only in editor.



    Amazing Assets - YouTube Facebook Twitter
     
  12. a436t4ataf

    a436t4ataf

    Joined:
    May 19, 2013
    Posts:
    1,302
    Unity removed that limitation 2+ years ago. Are you saying this limitation exists because you're still supporting Unity 5 / 2017? Or because there's something in your code that's not been upgraded to use Unity's current mesh code?
     
  13. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Geometry Shaders still not supported by webGL.
    32bit index meshes not supported by all mobile devices.



    Amazing Assets - YouTube Facebook Twitter
     
  14. a436t4ataf

    a436t4ataf

    Joined:
    May 19, 2013
    Posts:
    1,302
    Even 3 years ago (according to arasp) it was already supported by all of iOS, and almost all of Android. Those few Android phones haven't been available to purchase for many years now, and are totally unsupported by Android (i.e. full of malware, viruses, security holes).

    I'm all in favour of backwards compatibility, but 16bit indexes are a waste of time today. Does your code only use 16bit indexing?
     
  15. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Currently available version of this asset supports only 16 bit indexes.
    32 bit index meshes and SRP with ShaderGraph support will be added in the next version.



    Amazing Assets - YouTube Facebook Twitter
     
  16. bg3

    bg3

    Joined:
    Jan 3, 2014
    Posts:
    3
    Hi Arkhivrag, I bought the shader but believe I have misunderstood this point:
    • Wire Size controll (can be Screen Space or Fixed size)
    Is it possible to create wires which are 1 pixel wide and not anti-aliased?

    Secondly, I have a cube mesh using the Mobile/Unlit shader, with no transparency. The top surface of the cube is occluding the wire on the back edge of the cube - it appears the wire is drawn on the back face, not the edge?

    EDIT: Added example image. Note also that the wires taper off at one end, like a needle... how can I fix this too?

     
    Last edited: Jun 29, 2020
  17. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    'Artifacts' on the edges are not actually shader created artifacts, it's just a mesh edge. You can smooth it by enabling Camera anti-aliasing.
    upload_2020-6-29_17-52-13.png

    By default wire size is always in screen space. It means that pixel width of a wire is constant regardless camera position. This can create unwanted wire rendering effect when mesh becomes small inside camera view and wire color completely covers mesh. In this case you can enable Reduce By Distance checkbox inside material editor.

    Wireframe is calculated using both sides of a polygon. If wire size is too small it may not be rendered completely like on tables your sceenshot. In this case you have to increase wire size.



    Amazing Assets - YouTube Facebook Twitter
     
  18. scott1984

    scott1984

    Joined:
    Nov 13, 2013
    Posts:
    1
    I've buy and testing this asset, It's a amazing work and I like it.
    But I've got a problem for reproducing demo.
    As demo video

    It's just like demo scene Example_9 (Dynamic GI)
    But when I play the scene it's not "Glowing" like demo video(is the Glowing mean GI?).
    It's a great effect which I also need.
    I've try on 2018.4 and 2019.2 without success.
    Am I missing something simple? thanks!
     

    Attached Files:

  19. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Seems scene lightmap needs to be re-baked.
    Got to Unity scene Lighting Settings and click on Generate Lighting button.



    Amazing Assets - YouTube Facebook Twitter
     
  20. Fabrizio_1990

    Fabrizio_1990

    Joined:
    Feb 21, 2016
    Posts:
    5
    Hi, when is planned the next release? becouse i need to bake meshes with more than 21K verts and it will good to use URP
     
  21. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    New wireframe shader is planed to be released somewhere in September.
    It will support mesh with 32 bit meshes, Universal and High Definition render pipelines and will have Shader Graph integration.

    I'm updating all my asset for SRP and it is a big queue. That's why September.



    Amazing Assets - YouTube Facebook Twitter
     
    LostPanda, Bartolomeus755 and amynox like this.
  22. Raptosauru5

    Raptosauru5

    Joined:
    Feb 8, 2019
    Posts:
    21
    I am very interested in URP support! I am actually waiting with the asset purchase until URP support is released. Hopefully you will have success implementing it. Thanks for your hard work. Looking forward!
    Best Regards
     
  23. maiscrudo

    maiscrudo

    Joined:
    Mar 3, 2016
    Posts:
    4
    I'm in a similar, but somewhat different situation: this shader is already fundamental in my current project, so I'm waiting for URP support to migrate my project to the new pipeline :).

    By the way, really amazing work @Arkhivrag... and great support too. Very satisfied with the purchase so far.
     
  24. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Working on new Wireframe shader is in progress.
    Will be supported both SRP, ShaderGraph, Amplify Shader Editor, meshes with 32bit index, run-time wireframe texture exporter and other improvements.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Aug 27, 2020
  25. maiscrudo

    maiscrudo

    Joined:
    Mar 3, 2016
    Posts:
    4
    Cool!
    I also have a technical question: today I was trying to cast shadows from my wireframe models, I had no problems with cutout or opaque but I was not able to do that with transparent.
    Is it even possible?
    Thanks!

    Marco
     
  26. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Shadows cast only Opaque and Cutout shaders.



    Amazing Assets - YouTube Facebook Twitter
     
    maiscrudo likes this.
  27. LostPanda

    LostPanda

    Joined:
    Apr 5, 2013
    Posts:
    166
  28. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Asset supports only built-in (standard) render pipeline.
    HDRP and URP is in development. Releasing in October.



    Amazing Assets - YouTube Facebook Twitter
     
    Bartolomeus755 likes this.
  29. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Hi @Arkhivrag , your Wireframe shader is really cool!
    I'm thinking of buying it but I see there is a new version coming.
    If I buy it now, will the update be free or should I wait?
     
  30. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    New wireframe shader will be released as new asset, but upgradable from current version. Upgrade price will be price difference between those two assets. You can purchase now and than upgrade, or wait to the new release.



    Amazing Assets - YouTube Facebook Twitter
     
  31. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Ok cool!
    What will the new asset cost?
     
  32. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Last edited: Oct 27, 2020
    Bartolomeus755 and atomicjoe like this.
  33. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Well, I just purchased it and it's not working with my models because they have more than 21k vertices, which is ridiculous given Unity supports 4 BILLION vertices per mesh since 2017.
    I would gladly fix the scripts, but everything is packed and well hidden inside DLLs, so I'm stuck.
    Geometry shaders are not an option since I'm on mobile and they don't work correctly (and are extremely slow anyway).

    How is that new version going?
    Is the vertex limit gone?
     
    Last edited: Sep 30, 2020
  34. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    In new Wireframe shader limit of 21.000 vertices is removed and added support for 32 bit index meshes. DLL also will be removed and source code included.



    Amazing Assets - YouTube Facebook Twitter
     
    atomicjoe likes this.
  35. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Great! thanks!
     
  36. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Sooo.... about that update?
    I mean, this asset is useless to me as it is... My meshes have more than 21.000 vertices.
    o_O
     
  37. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Almost finished. Submitting next week.



    Amazing Assets - YouTube Facebook Twitter
     
    amynox and atomicjoe like this.
  38. amynox

    amynox

    Joined:
    Oct 23, 2016
    Posts:
    160
    URP support ?
     
  39. maatvee

    maatvee

    Joined:
    Oct 4, 2014
    Posts:
    5
    Hooboy, I've been waiting with anticipation for this update, as soon as I realised the QuadShader didn't work in the URP I've been using with the Oculus Quest VR SDK.

    Here is a screen capture of a simple demo running in the built in renderer:
     
  40. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232
    Are you using prerecorded meshes for this or are you using the geometry shader version of the shader?
    I ask because the geometry shader version doesn't work on the Quest and is extremely slow anyway.
     
  41. maatvee

    maatvee

    Joined:
    Oct 4, 2014
    Posts:
    5
    Hmm I've been using the physically based Vacuum Shader, but I've also tried it with the Standard Vacuum Shader too, and it seems to work but this is still running the built in renderer soooo....

    The Mesh itself is procedurally generated using this implementation: https://github.com/TomaszFoster/NaiveSurfaceNets

    Anyway I guess I won't know if I've hit a dead-end until the new Amazing Wireframe Shader version is released, and I've had a chance to experiment with it in the URP.
     
    atomicjoe likes this.
  42. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    amynox likes this.
  43. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    New Wireframe Shader has been submitted for review.

    • All render pipelines are supported: Universal (URP), High Definition (HDRP) and Built-in (Standard).
    • One node integration with Shader Graph and Amplify Shader Editor.
      upload_2020-10-30_18-24-45.png
    • Added support for 32bit indexed buffer meshes (supporting meshes with 4 billion vertices).
    • Full source code included (dlls removed).
    • Improved faster mesh generator.
    • Wireframe texture can be generated in runtime.
    • Compatible with Curved World 2020.
    • New improved editor window (all in one). upload_2020-10-30_18-20-56.png


    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Nov 3, 2020
  44. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    1,232

    Seriously, Thank you!
     
  45. a436t4ataf

    a436t4ataf

    Joined:
    May 19, 2013
    Posts:
    1,302
    Great! I'll get this once it's live.
     
  46. Pourya-MDP

    Pourya-MDP

    Joined:
    May 18, 2017
    Posts:
    121
    Hello it seems i great tool for wireftaming
    One question before buying btw
    Does it suports masking for wireframes?
    And also can we create maybe custom shpe wireframes on objects?
     
  47. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    Wireframe masking is supported using texture or dynamic object (Plane, Sphere, Box).
    Custom shape wireframes - No.



    Amazing Assets - YouTube Facebook Twitter
     
  48. sloopidoopi

    sloopidoopi

    Joined:
    Jan 2, 2010
    Posts:
    244
    Hi, is there any transparent shader in the new version ? In the old version i had the posibillity to use transparent render mode but i can't see any option like this any more. :( (I want to set the alpha of the base color and the wireframe color separately)
     
  49. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,732
    For Built-in (Standard) render pipelines new package includes similar shaders as in the old one.

    For Scriptable RP (URP and HDRP) new package does not include so much shaders, as it now supports ShaderGraph and with its help now users can create even more and better effects.
    You can check included example shaders, they all are mode using ShaderGraph and you can adjust them and modify for your needs.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Nov 10, 2020
  50. LostPanda

    LostPanda

    Joined:
    Apr 5, 2013
    Posts:
    166
    @Arkhivrag

    I have purchased your plug-in, but I have encountered a problem. I use Unity2020.1.14f1, hdrp is 8.2.0.

    If I move the folder to another file directory, the following problems will occur.

    thanks


    upload_2020-11-25_14-58-2.png
     
unityunity