Search Unity

[Released] MegaSplat, a 256 texture splat mapping system..

Discussion in 'Assets and Asset Store' started by jbooth, Nov 16, 2016.

  1. ixikos

    ixikos

    Joined:
    Jun 21, 2013
    Posts:
    26
    Yea I noticed this, it changed lines a few times depending on what features I included. Thanks for the tips, I imagine I just set up things improperly. All I am using is the Terrain mesh module.. I may just attempt to start from scratch with this all and see if that fixes it.
     
  2. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    In an older version, sometimes the terrain instancing flag would persist to the newly created material- unity stamps this on materials when Draw Instanced is enabled, but there's no UI to clear it. I believe I added code to do that, but you might want to try toggling Draw Instanced off when you do the conversion..
     
  3. avinitzca

    avinitzca

    Joined:
    Mar 25, 2019
    Posts:
    2
    Hey JBooth,

    Maybe it was asked before but I cannot find the question in the thread.
    Is it possible to have a Mesh with Tesselation and environmental reflections or SSR?
    Activating Tesselation on a MegaSplat mesh shader turns reflections off somehow.
    I'm using Unity version 2019.4.8f1.

    Thank you in advance
     
  4. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    SSR happens in post processing- it shouldn't make a difference what shader draws the data into the GBuffer, or if it's tessellated or not.
     
  5. avinitzca

    avinitzca

    Joined:
    Mar 25, 2019
    Posts:
    2
    Yeah, makes sense, but all types of reflections seem to behave the same (not showing) when tesselation is active.
    Reflection probes, environmental sky (which works the same way I guess), or SSR gets disabled on the mesh.

    upload_2020-10-28_12-52-52.png

    upload_2020-10-28_12-54-59.png


    A weird thing is that, when tesselated, the terrain gets baked into reflection probes and it shows to be reflective there, but not in the scene pass.

    upload_2020-10-28_12-52-33.png

    Also, this gets fixed when I switch the camera to forward mode. I could go on with forward rendering but I need to use deferred decals, so it's not an option by now.

    upload_2020-10-28_12-52-37.png
     
  6. lorrainelin

    lorrainelin

    Joined:
    Mar 4, 2020
    Posts:
    4
    Hello JBooth,

    I recently downloaded MegaSplat and watched the intro video. I checked Active (ESC) on the Vertex Painter. Clicking "fill" works fine, but the brush doesn't show up when I mouse over the scene window, and if I try to paint, I get a usual Unity selection box that also deselects the mesh. What might I be missing?

    Thank you for reading. megasplat_q.png megasplat_q2.png
     
  7. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Are you trying to paint meshes (vertex), or terrain- there is a painter for each, so you have to use the right one..
     
  8. lorrainelin

    lorrainelin

    Joined:
    Mar 4, 2020
    Posts:
    4
    Hi,

    Thank you for the quick reply.
    I am trying to paint meshes. I'm using the Mesh scene in the examples folder, and the Vertex Painter tool.
     
  9. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I just loaded MegaSplat on 2019.4LTE and everything seems to work fine, so I'm not sure what you could be running into. Does the brush show up on the meshes when you mouse over it?
     
  10. lorrainelin

    lorrainelin

    Joined:
    Mar 4, 2020
    Posts:
    4
    The brush doesn't show up on the meshes when I mouse over them. I originally installed MegaSplat on my laptop. I just installed it on my desktop to see if it would work, and the same thing happens, no brush showing up.
     
  11. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I can't think of a reason why this would be- or repro it. So your best bet is to step through the vertex painter code and see why it's not finding the mesh. It would be in the VertexPainterWindow_Painting.cs file in the OnSceneGUI() function, and I'd check to make sure the jobs list has meshes in it..
     
  12. syscrusher

    syscrusher

    Joined:
    Jul 4, 2015
    Posts:
    1,104
    Hello, @jbooth.

    I'm interested in purchasing MegaSplat but have a couple of integration questions:
    • If I've used the terrain converter downstream of Terrain Composer 2, is that a one-time operation that will automatically reflect further changes to the splatmap that is generated by TC2, or do I repeat the terrain converter as desired, to propagate additional TC2 splatmap changes? If the latter, what happens to any painting I've done within MegaSplat's own painting tool? EDIT: After watching the "convert an existing terrain" tutorial, I've revised the question to be more specific. :)
    • Having followed your posts on the SRP threads, I know HDRP and URP have made your shader devvelopment...interesting. That being said, and knowing you don't currently support HDRP in MegaSplat, my question is whether it's feasible for me to do that myself, using the ASE integration you provide? I'm comfortable working in ASE, to the point of making a couple of custom nodes myself, but I'm not sure how much of MegaSplat's custom ASE node(s) is/are bound to the Standard rendering pipeline and therefore tricky to port to a custom HDRP shader created in ASE.
    • Alternatively, if HDRP integration as a DIY project in ASE isn't feasible now, but you're planning to release an addon module soon, that would also work for me.
    I'll continue looking for answers to these questions online, but since the sale ends Friday I thought it wise to go ahead and ask on the forum, in parallel. Thanks.
     
    Last edited: Dec 1, 2020
  13. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I have no plans to port MegaSplat to SRP's, the amount of maintenance work required to support a shader system through three rendering engines is insane, so I had to make a choice of which system I was going to support, and MicroSplat is much better in many ways. I don't think the ASE nodes will work in HDRP, they've changed the way you work with textures, etc.
     
  14. syscrusher

    syscrusher

    Joined:
    Jul 4, 2015
    Posts:
    1,104
    Are you recommending I choose MicroSplat over MegaSplat?
     
  15. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Yes, unless there's a reason you need 256 unique textures, MicroSplat is better in pretty much every way at this point..
     
    syscrusher likes this.
  16. syscrusher

    syscrusher

    Joined:
    Jul 4, 2015
    Posts:
    1,104
    Okay, thanks for the recommendation. I'll take a deeper look at MicroSplat. I had been attracted to it for other reasons but had pulled toward MegaSplat because of the larger texture count. Even 28, though, is way more than the Unity default.
     
  17. MaDDoX

    MaDDoX

    Joined:
    Nov 10, 2009
    Posts:
    764
    Hey @jbooth, please tell me if that's also true for the following use case:
    - Needing to have perfect texture tile-breaking
    - Having the ability to export the full texture from either the mesh or terrain as a high resolution image (eg.: 8k)

    My gut feeling is that with the tile-breaking package from microsplats I could get rid of the need to use texture clusters, thus saving up on texture space, *as long as* I can bake those shader effects onto the texture - since I plan to use the resulting terrain-wide textures in other game engine (long story). I currently own Megasplats and would be more than willing to buy the needed modules for Micro, but I don't know how much easier or harder it would be to fit my required workflow using Microsplats.

    Any help appreciated.
     
  18. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I mean baking out the resulting textures can be done in either, but the whole point of this type of shading is because that doesn't work out well- you run out of texture resolution very fast. MicroSplat supports texture clusters, but also stochastic texture clustering which gets very close to the same quality without additional textures.
     
    MaDDoX and eaque like this.
  19. dsilverthorn

    dsilverthorn

    Joined:
    May 14, 2017
    Posts:
    841
    We just completed final editing to our latest video, "Apollo's Dream", and it will be coming soon to our YouTube channel.
    Using MegaSplat on this one.
     
  20. dsilverthorn

    dsilverthorn

    Joined:
    May 14, 2017
    Posts:
    841
  21. silversmithstewart

    silversmithstewart

    Joined:
    Dec 2, 2020
    Posts:
    1
    Running into an issue trying to paint terrain. All my textures that i attempt to put into an array end up looking like this broken color including when i'm using copied assets as seen below. Any help is much appreciated. upload_2021-1-26_5-52-5.png

    Here are the steps i'm taking on a new terrain:
    *Test out texture array "MegaSplat_Example_texlist.asset in megasplat/examples/textures/arrays ; it works
    A.Right click -> create -> megasplat -> texture array config
    B. Copy the example textures into the array
    C. hit update
    D. Hit generate clusters
    E. Hit update again
    F. Attempt to paint textures in terrain painter -> it works. yay
    (Now let's copy some textures into another folder and see what happens)
    G. Delete all textures out of the array and update. Clear clusters too.
    H. Get to folder with some copy pasted example textures and repeat steps B to F
    I. Try to paint using terrain painter-> Corrupted textures

    What am I missing here?
     
    Last edited: Jan 29, 2021
  22. MaDDoX

    MaDDoX

    Joined:
    Nov 10, 2009
    Posts:
    764
    Reinstalling Megasplats fixed it for Stewart, I helped him. Since then we've moved to Microsplats, not perfect but the fact that it breaks tiling with single textures (stochastic clustering is amazing) is a winner feature, making Mega's large 256-textures support unnecessary for most purposes.
     
  23. ununion

    ununion

    Joined:
    Dec 2, 2018
    Posts:
    275
    does it or will it support URP?
     
  24. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Nope - MicroSplat does..
     
  25. dsilverthorn

    dsilverthorn

    Joined:
    May 14, 2017
    Posts:
    841
  26. dlstilts

    dlstilts

    Joined:
    Sep 29, 2017
    Posts:
    40
    Hi, I am interested in using your asset for an infinite procedural terrain. It is a flying game and I want to be able to change the terrain at runtime as the character is flying. I noticed you have runtime tools built into MegaSplat. It says you can add/remove different textures or features like snow, lava, grass, etc. at runtime. Can I use this feature in an infinite terrain to blend between biomes, like from dirt to grass, to lava, with a C# script? I would like to change the terrain depending on user input. Is this possible with MegaSplat? Also, will this work with say Map Magic or my own procedurally generated terrain tile script. Please let me know. Thank you.
     
  27. dsilverthorn

    dsilverthorn

    Joined:
    May 14, 2017
    Posts:
    841
    Apollo's Dream II is now live!
    A ton of work went into this one, I hope everyone will enjoy it.
    Creating beauty with Unity for a Virtual Experience with an original soundtrack is a lot of fun and I hope it shows in the video.

    @jbooth assets helps create the textures to this old west experience.
     
  28. Hemath

    Hemath

    Joined:
    Jul 15, 2020
    Posts:
    15
    Hi jbooth! First of all, excellent solution for painting multiple textures!

    I'm wording whether the texel in SplatData.png exported represents the index of the texture in texture array? If so, I'm confused that why I filled the mesh with a blended material and then exported SplatData, the image looks different from what I expected. The mesh is covered almost evenly by both materials, but why the distribution is so uneven in SplatData.png, and why is there a gradient of color in the area (the left-most arrow)?

    Thanks in advance!
     

    Attached Files:

  29. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    The data format is described in the docs- it's not a splat weight map like Unity terrains traditionally use, because then you'd need 64 textures to store the weights..
     
  30. Hemath

    Hemath

    Joined:
    Jul 15, 2020
    Posts:
    15
    Thanks! I understand.
    Btw, the link "Here's a brief comparison guide." in the asset store is invalid now?
     
  31. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
  32. Hakazaba

    Hakazaba

    Joined:
    Jul 1, 2015
    Posts:
    119
    Hi, i get errors saying that SelectionMode.OnlyUserModifiable is obsolete.
     
  33. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    you can remove that option from the check or change it like the message recommends. I'll upload a new patch with this change.
     
  34. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Try reading the documentation, it explains exactly what you need to do to prepare your mesh, adjust the blend contrast, etc.
     
  35. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Adjust the interpolation contrast..
     
  36. AndreyO

    AndreyO

    Joined:
    Jan 31, 2014
    Posts:
    20
    Hi. On 2020.3.16f1 TextureArrayConfig generates white texture arrays.
    upload_2021-8-27_17-7-58.png
     
  37. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    Any errors in the console? I'm assuming you have textures in the slots?
     
  38. AndreyO

    AndreyO

    Joined:
    Jan 31, 2014
    Posts:
    20
    Yes. Textures are set. No any error. On clean project example array generated just fine, but in our project (after upgrade from 2019.3) white texture arrays. Reimported megasplat, deleted Library. No luck.
     
  39. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    If it's working fine in a clean project, then it's something to do with your project..
     
  40. RegdayNull

    RegdayNull

    Joined:
    Sep 28, 2015
    Posts:
    68
    Problem is in migration. New one work as expected, but old not reimported properly, producing white arrays. And hash does not match between different PCs, since generated arrays is generating over and over via OnPostprocessAllAssets. Again producing white texture arrays.
    Solution - do not track in version control texture array config.
     
  41. Ishizuke

    Ishizuke

    Joined:
    Jan 27, 2015
    Posts:
    48
    Problem with tesselation shaders, MegaSplat version 1.77, released 11 of October, Unity version 2021.2.1f1.3791. Not possible to set "Tesselation" flag in mesh material "MegaSplat_TessMesh" (Scene "MeshTessellation"). Tesselation flag is always set to "None". In fresh loaded project before material modification attempt the tesselation works in shader, although material settings for "Tesselation" is set to "None", but after trying to change "Tesselation" to "Distance" or "Edge", the option remains "None", but shader changes and tesselation no longer works in scene view.
     
  42. Ishizuke

    Ishizuke

    Joined:
    Jan 27, 2015
    Posts:
    48
    The problem is in SplatArrayShaderGUI.cs, line 484

    fData.Unpack(targetMat.shaderKeywords);

    shaderKeywords here returns zero-length string array, so, no shader feature can be detected. Temporary solution I found so far is to comment out the string

    CustomEditor "SplatArrayShaderGUI"

    in shader code, so shader features at least become editable.
     
  43. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    It looks as if Unity has changed keyword handling in some way that completely breaks MegaSplat on Unity 2021.2.. Commenting out the interface isn't going to let you use the system, as it relies heavily on the custom editor to generate shaders.
     
  44. bvonline

    bvonline

    Joined:
    Feb 27, 2021
    Posts:
    85
    Does it support URP partly / fully? Might buy it these days.
     
  45. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    No
     
  46. daber996

    daber996

    Joined:
    Oct 28, 2021
    Posts:
    2
    Mr. Booth,

    I'm wondering if you've heard of issues with newtonsoft json package conflicts? Since bringing in the Megasplat package into my project, it's conflicting with the attached error message. From what I can gather, there are duplicate packages with the same name. I wanted to I guess ask if you had any insight into this from previous customers, and to confirm that I do need the json package for the megasplat tool to work?

    I was reading this thread, but it's a bit tricky for me to entirely understand as I'm on the art side, not the programming side.

    https://forum.unity.com/threads/con...onsoft-and-packagemanagers-newtonsoft.843898/

    Thanks!

    screenshot_680.jpg
     
  47. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I don't use json in MegaSplat.
     
    daber996 likes this.
  48. daber996

    daber996

    Joined:
    Oct 28, 2021
    Posts:
    2
    Thank you - this is very helpful, much appreciate the prompt response!
     
  49. newguy123

    newguy123

    Joined:
    Aug 22, 2018
    Posts:
    1,248
    Hi Jason

    Quick pre-sales question (and please excuse my ignorance)

    Whats the difference between this Megasplat, and Microsplat with all its modules? To me it seems Megasplat is a cheaper version with everything built in that Microsplat and its various modules offer.
     
  50. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    No, MegaSplat is a lot older, has a lot less features, and isn't as optimized. It also doesn't run in SRPs like MicroSplat does.
     
    Zypo and newguy123 like this.