Search Unity

  1. Calling all beginners! Join the FPS Beginners Mods Challenge until December 13.
    Dismiss Notice
  2. It's Cyber Week at the Asset Store!
    Dismiss Notice

[BETA RELEASE] Amplify Impostors

Discussion in 'Assets and Asset Store' started by Amplify_Ricardo, Jul 10, 2018.

  1. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    @creat327 Here's a quick test using the Unity Tree Editor.

    Impostor on the left, Unity Tree on the right; I did have to use a Standard Cutout material on the leafs for the bake.


    Basic LOD Group using the Unity Tree and Impostor.


    The same prefab scattered a few time in the terrain.
     
    Lars-Steenhoff likes this.
  2. noobynobody

    noobynobody

    Joined:
    May 9, 2019
    Posts:
    74
    I see that there will be "Dynamic Impostors" in the future. Is there an ETA? How does it perform vs. normal impostors?
     
  3. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Apologies but we don't have an ETA yet, we've been a bit overloaded for a while but we're pushing for it. Might be too soon to compare, it's more about what it allows you to do in realtime; I would expect it to perform as well as its baked counterpart.
     
  4. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,171
    Yeah it's way slower than the default Unity Tree. Unity already does the billboarding for the trees for you so you don't need to use amplify impostors for that and all the overload to create LOD groups and such. If you test the same scene on mobile with just the trees and then with the impostors, you'll find you don't have any performance benefit. It would be awesome if you did though :(
     
  5. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    do impostors (transparent objects) work with volumetrics like aura2 or fog volume 2 or hdrp's volumetrics?
     
  6. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    That's not necessarily accurate for all cases, as we usually say, it will ultimately depend on how you use it. A simple billboard shader could be less complex but with an Impostor you would probably get away with rendering them at a much closer distance, and different angles, which could in practice reduce the amount of actual tree models(LOD 0) you need to render.

    How it's used, really makes a difference. I don't know much about your project so I'll have to speculate, I would recommend playing with the LOD distance, I think you might find that you can get away with Impostors much closer than some billboards without revealing that they are fake as a planar billboard.

    Should work just as regular models, let us know if that's not the case and we will look into it ASAP.
     
  7. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385

    Quick heads-up to anyone interested in picking up Amplify Impostors during the Black Friday sale. Thank you for your support and be sure to use the code BF2019AFF10 during checkout for an additional 10% OFF on any products currently sold at a discount.

    Amplify Impostors - Asset Store
     
  8. Sam512

    Sam512

    Joined:
    Jan 13, 2019
    Posts:
    177
    Does it work on mobile android?
     
  9. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    Ok so you've tested it against HDRP volumetric fog?
    And how does it handle highlights of metallic and plastic objects like this one?

    upload_2019-11-28_14-20-40.png
     
  10. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Yes, be sure to let us know if you encounter any specific issues.

    Works great with volumetric HDRP fog!



    Not sure if I fully understand your second question, the resulting baked impostor will use an equivalent material; in this case, I'm assuming, the HDRP Lit shader. Should you have any special requirements, Custom Baking is available via ASE.
     
    Lars-Steenhoff likes this.
  11. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    PBR, cutout transparency, got it!
    Any plan to cover animation? these thousands of robot arms looks so much cooler when moving.
     
  12. creat327

    creat327

    Joined:
    Mar 19, 2009
    Posts:
    1,171
    I'm trying to use this on mobile and it's very very slow. I profiled it and the problem is the shader.
    Mobile does not like the "standard shaders". A single standard shader can slow down by 20fps an old android device. Can we get a fast shader that doesn't require specular, normal maps and all that? For mobile, usually we have only 2 versions of shaders:
    1) diffuse and unlit (no shadows).
    2) diffuse with shadow support

    From far we don't care about specular or metallic or OC or whatever else. So mobile shaders that run on opengl2 or a way for us to adapt the shader would be nice.
     
  13. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    823
    Does this work with trees and grass in Vegetation Studio Pro?
     
  14. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Yes, cutouts!

    Animation support is planned, realtime impostor generation is one of the main updates coming to Amplify Impostors.


    You can set which channels to bake in the Bake Preset but it's not too flexible at the moment, this is definitely something we want to improve as we leave the beta stage. Alternatively, you can create your own custom Bake and Runtime shaders with using our shader editor.

    It should, let me get back to you on Monday with additional details after checking with the dev that was in contact with the Vegetation Studio creator.
     
    SickaGamer and Lars-Steenhoff like this.
  15. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    Ok, can you give more details on how it'll be like for us?
    Let's say you have a bunch of objects animated by bones and you want to impostorize those.
    Where does the animation go? Which component? what code will we have to write to access this texture animation? If say a 10k poly factory has 3 animations: idle, making things and going override, how will that work out?
     
  16. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
  17. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Ideally, everything will be controlled by the original asset, the impostor will only provide the actual visual representation of the model. More on this at a later time, we will detail it as soon as possible.

    That's an odd one, does it look like that immediately after baking?

    We will need additional details in order to debug the issue on our side.
    -Unity version and rendering pipeline used
    -Original asset shader used
    -A sample with the problem present(faster to debug)

    Thanks!
     
    laurentlavigne likes this.
  18. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    510
    Hello, I'm considering Amplify Impostors, but I only use fully baked lightmaps and lightprobes in my project (no realtime lights at all).
    I have checked the manual but it's not clear about exactly how to make an impostor with lightmaps.
    Could you elaborate on the exact way to do it?
    Also, do impostors work with lightprobes?
    Thanks and great work!

    EDIT: I'm using the built-in forward renderer.
     
    Last edited: Dec 2, 2019 at 6:41 PM
  19. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    I'm using Unity 2019.2.4f1 and I believe I'm using the default render pipeline. I didn't go to the package manager and install anything.

    I'm using asset from "Tower Defense and MOBA" by MANUFACTURA K4. I added the Amplify component to the object and built the impostor. Then I created a LOD on the object then added the impostor. In the editor the impostor is working correctly but when I play the project the issue appears.
     
  20. Mithys

    Mithys

    Joined:
    Dec 5, 2017
    Posts:
    1
    Hello!

    I have an issue with the package, where impostors don't show up in play mode. Sometimes it also shows parts of the impostor texture at completely wrong world space positions. This used to only happen in the editor (didn't affect builds), but with the latest version of the project, the issue is present in builds too. As far as I know, the only major thing that's changed is the project platform was switched to UWP and then back to Win32. Also, the impostors show up just fine in scene view.

    Here's a short video of the issue:


    Using Unity 2019 2019.2.3f1 and LWRP 6.10.0
     
  21. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    Bought!
    ASE turned out fantastic so I know you folks are trustworthy.
    After 15 minutes I can attest that this is a very good choice. I model everything in VR so the polycount is very high and I can't be bothered reducing so framerate takes a serious hit real fast.
    I LODed all my models in 20 minutes which were mostly spent reorganizing the prefabs to accomodate LODGroup.
    I am sure the doc is good as usual but I didn't need it, it is that easy. The result is surprisingly good ... in most cases:

    1- The default workflow is add lodgroup, drop all meshes to lod0 then nuke lod2 and add imposter press bake. It's not many steps but it would be great if dropping impostor added lodgroup with 2 lods by default.
    2- I attach a model which isn't work well, maybe that'll help you improve the imposter renderer.
    upload_2019-12-2_16-11-22.png upload_2019-12-2_16-11-13.png
    https://www.dropbox.com/s/qd7p8tcsem0ck9f/big canon.unitypackage?dl=0
    3- doesn't work with unity tree's foliage
    upload_2019-12-2_16-34-9.png upload_2019-12-2_16-34-16.png
    4- Metallic map would be good as I use only standard. perhaps it's not metallic map that's acting weird, in this model it pops even with LOD fade animation turned on, I can see that it's dither fading but the axle pops.
    here is the model:
    https://www.dropbox.com/s/qcsm9mrmk2w2b0f/heart.unitypackage?dl=0
    upload_2019-12-2_16-46-38.png
    5- is it possible to render impostor in an adaptive way? meaning when detail matters there are more pixels. Maybe that would require an extra texture map and also more complexity for the shader and that's not desirable. I'm just worried that the gpu will choke with all these highres textures.
    6- cast shadows don't seem to match the geometry. I know it's possible because there is a parallax texture thing which accepts and deforms shadows.

    A few fixes here and there + animation and you got yourself a very solid release that'll help a lot of people like me.
     
    Last edited: Dec 3, 2019 at 1:30 AM
  22. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    @Amplify_Ricardo I think I have figured out what the issue was. I'm using UniStorm for weather from Black Horizon Studios. Once I removed UniStorm and added Directional light. You don't see that white transparent texture show up.

    But I'm having issue with the it looking weird.
    https://1drv.ms/u/s!Au-_n2IVQW0tuzdxxuhpx4spvXKS
     
    Last edited: Dec 3, 2019 at 4:15 AM
  23. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Great knowing you had a nice first experience, thank you for your support!

    1 - You do have a "Create a LOD Group automatically" toggle in the Unity Preferences; pressing the "+" button on the actual impostor component, and saving the impostor asset, will reveal the required options for additional lod control.
    2 - That's the expected result when using Octahedron Impostors, they breakdown at close distances so be sure to use them from a certain distance at higher LOD levels; consider using the Spherical impostors if you require additional detail(does not blend smoothly between views).
    3 - Must be the shader, try swamping it for a standard material as a test just to be sure.
    4 - Can't quite see the problem in the screenshot, please elaborate; Impostors support both Metallic and Specular workflows by default, it shouldn't be a problem.
    5 - Not at the moment but you can define individual horizontal and vertical resolutions with spherical impostors.
    6 - Really depends on the case, you might need to tweak the material a bit; it's also not a 1:1 translation, some approximation is to be expected. Can you provide an example?


    I see, not sure what could be causing the issue there; we'll take note and see if we can replicate those conditions on our side.

    Are you using the octahedron impostor type?

    Thanks!
     
  24. atomicjoe

    atomicjoe

    Joined:
    Apr 10, 2013
    Posts:
    510
    bump:

    Hello, I'm considering Amplify Impostors, but I only use fully baked lightmaps and lightprobes in my project (no realtime lights at all).
    I have checked the manual but it's not clear about exactly how to make an impostor with lightmaps.
    Could you elaborate on the exact way to do it?
    Also, do impostors work with lightprobes?
    Thanks and great work!

    EDIT: I'm using the built-in forward renderer.
     
    Amplify_Ricardo likes this.
  25. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Apologies @atomicjoe, missed your reply there, I was getting back to you now ;)

    Amplify Impostors supports baked lightprobes. However, impostors don't support baked lighting(lightmaps) without extra work, impostors are pre-baked and intended to be used as repeated objects in the scene to save performance on highly detailed objects. Baked objects have unique baked uvs with unique baked maps assigned to those UVs, which means, every tree is different as far as baking goes, this defeats the purpose of impostors in this particular application; there is a way to bake this lighting information and use it in your impostors but then ALL of them will use it, which means that some of those trees would have "the wrong light".

    To be more specific, you can override the runtime shader bakedGI information, you do this by creating a custom runtime shader with ASE and overriding the bakedGI input port.

    Be sure to check this pages if you have not already:
    -Custom Baking
    -Lightmap Baking

    This is not the best of workflows at the moment, we don't really recommend it unless you absolutely need it.

    Thanks!
     
    atomicjoe likes this.
  26. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    Yes, I'm using octahedron impostor.
     
  27. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
  28. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    Yea, that's what I was finding out. I have tweaked the LODs and it doesn't look very like my previous picture. As far as this issue,
    https://drive.google.com/open?id=1Et6i7AVLrp6L2dbJa18kDz6UJxg48aV8

    UniStorm is impacting that. I'm not sure exactly what's going on but if I remove UniStorm then that white transparent doesn't show up.
     
  29. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    One final question, is this is with Forward rendering or is it also present with Deferred?
     
  30. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    Sorry but stupid question, where do I check that?
     
  31. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    No problem!

    In your camera(changing it here to Deferred to see if there's any change)


    Or in the Graphics Settings
     
  32. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    141
    After switching the rendering to Deferred instead of Forward I believe that has solved the issue with the white transparent texture issue. I'll continue to use it and see what happens. I'll report back later. Thank you for the help. :)
     
  33. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385

    Thank you for confirming it, that sounds familiar to a known issue present with some image effects in Forward; I will pass it on to the developer.
     
  34. Amplify_Paulo

    Amplify_Paulo

    Joined:
    Jul 13, 2017
    Posts:
    286
    Hi all, this marks an important step that impostors needed, a lot of the issues that some of you were having with HDRP should be fixed with this release, and it should now be more prepared for future SRP releases. Other HDRP material types will be added in the next release. Do report any issues you may find.

    cheers, and thank you for the patience, grab it at the usual places

    Amplify Impostors 0.9.6 rev003 - Asset Store - Amplify Products


    Improvements
    • Added support for Universal Rendering Pipeline (URP)
    • Now standard HDRP shaders use the deferred buffer to render impostors, this should make it more stable overall and allow for future support for non-standard shaders, currently supports
      • Standard
      • Standard Specular
      • Subsurface Scattering
    • Added parallax effect to spherical impostors with material configuration
     
    Lars-Steenhoff likes this.
  35. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    1- can't find it clicking on things and doing a quicksearch, got a screenshot of where that is?
    2- indeed, far away it looks good. any tuning we can do to mitigate at closer range? impostors look so good that it would be nice to use unstead of LOD1
    3- the shader is unity tree creator shader. When I changed it to anything else (including standard) it still bakes wrong and causes problems with the LOD0 and snaps back to nature/tree creator leaves optimized when the tree creator is tuned.

    4- then it's not the workflow, perhaps this is related to shadow, have a look upload_2019-12-3_14-47-35.png -> upload_2019-12-3_14-47-26.png
     

    Attached Files:

  36. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Hello there,

    1. Edit > Preferences > Impostors



    2. Not with Octahedron impostors, that's an expected result of the technique used. You can use spherical impostors, they don't breakdown at closer distances but also don't blend between views.

    3. The bake should work with a compatible shader, can you share a problematic sample? Be sure that the Tree Creator is not swapping the shader used before the bake.

    4. Please use another image host, I can't zoom in; a side by side comparison would be great.

    Thanks!
     
  37. joshcamas

    joshcamas

    Joined:
    Jun 16, 2017
    Posts:
    875
    Hello! I'm trying to implement a custom baked / runtime shader, and I've almost gotten it.
    In my case, I'd like to apply the albedo to the masked areas as well. To achieve this, I packed the masked albedo onto a map, with the alpha map being the mask value.

    Bake shader: (Ignore the round node, I removed that)


    Runtime Shader:


    And here's the issue. It looks like some multiplication is happening where it shouldn't be, causing dark brown splotches.


    This is very noticable from afar, when switching between the original and the impostor.

    Any ideas?

    EDIT: I figured out one major issue - the bake shader had culling enabled, while my trees did not. That solved one issue - however I still have the dark splotches, they're just less noticeable.

    I'd also like to figure out how to pack the leaf diffuse alongside the albedo texture, instead of the mask texture. The reason why I didn't do this is because I got white blotches, which I think are due to the leaf diffuse "bleeding" onto the non masked area. But that's just a guess
     
    Last edited: Dec 4, 2019 at 10:45 PM
  38. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
  39. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    bug?: material of impostor doesn't match reflectance of original, which is a standard shader. this looks like a shader glitch as it doesn't look like the usual octahedron smear


    bug:
    it breaks prefabs and puts the lod in the wrong place
    upload_2019-12-4_18-21-3.png

    repro: parent a 3d object under a null, drop it to project to create a prefab
    open that prefab, select the 3d object child and add impostor and bake
    it'll put the lod in the top node instead of the 3d object and adds the impostor as sibling to the 3d object instead of child of
    it'll also break the prefab completely
     
    Last edited: Dec 5, 2019 at 4:00 AM
  40. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    Thank you for the additional details, please forward us your shaders to support@amplify.pt so that we have the same exact parameters on our side. Before we dive into the actual shader, can you confirm that adjusting the Pixel Padding value does not mitigate the problem?

    Do you mean packing in the actual impostor? You can always create separate impostors; not sure I understood your point.

    Seems to be working as long the shader is swapped; Unity does keep changing the shader to its previous Tree stuff so be sure to check that before baking. I understand that this is not ideal, we definitely need to look into this in the future.



    Seems to be working, please share that asset and we will test it on our side.(you can send it to support@amplify.pt) if you prefer. Which HD and Unity version are you using?

    Please disregard the Ocatahedron artifacts, that's quite close.



    Do you mean that you're generating the impostor with the Prefab View Open instead of the scene view? I'm afraid that's not going to work at the moment; bake it in the scene view and it should work as expected. The Automatic LOD Group creation is always added to a new parent object.

    Please elaborate if there are any additional details.
     
    Last edited: Dec 5, 2019 at 3:15 PM
    laurentlavigne likes this.
  41. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    swapped to what shader?

    sent
    Using (soon to be legacy) standard PBR, unity 2019.3f1

    Baking in a prefab editor with auto lodgroup off works perfectly. It's just the automation that's behaving wonky.
    Why would you want to add a lodgroupp in the root rather than the selection?! It's inconsistent to add stuff to a node above selection, a bit of a surprise honestly given how straightforward and intuitive everything you guys make is. Also it makes it more clunky to add multiple LODGroups within a prefab.
     
  42. Amplify_Ricardo

    Amplify_Ricardo

    Joined:
    Jul 19, 2013
    Posts:
    1,385
    The default Unity Tree shaders, the component seems to return to them automatically.


    Thanks! I also tested it with the legacy renderer and it was working so I'm curious to examine the sample.

    It's just that we can't assume that everyone will use an empty parent, this was the safe choice; however, this is a beta, that type of feedback is useful for us, we could add additional control options.

    Thanks!
     
    laurentlavigne likes this.
  43. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    2,119
    so give me the name of the tree shader that impostor is current compatible with. there are so many variants now in 2019.3f1 (and I tested them all unsuccessfully)

    like "add on selection" or "add on root"?
    with nested prefab all bets are off ;)