Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

PopcornFX - Optimized Particle Effects Plugin

Discussion in 'Assets and Asset Store' started by PopcornFX, Feb 13, 2015.

  1. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    That's still in our plans but nothing we can communicate on, yet.
     
  2. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Last edited: Apr 5, 2016
  3. pexoid

    pexoid

    Joined:
    Aug 29, 2014
    Posts:
    16
    New information regarding this, it is flipped when you have forward rendering and MSAA on.
     
  4. mittense

    mittense

    Joined:
    Jul 25, 2013
    Posts:
    168
    I have a problem and it's that I can't use Editor v1.10 with the Unity plugin yet.

    This is a major problem that I demand be rectified immediately. In fact, it's not already done. I'm upset. I'm never saying you guys are the best ever again (jk you're the best).

    The fact that not everyone uses this astounds me. ASTOUNDS.
     
  5. ZJP

    ZJP

    Joined:
    Jan 22, 2010
    Posts:
    2,649
  6. Crusare

    Crusare

    Joined:
    Feb 14, 2014
    Posts:
    21
    Any plans to support PS4 and XBox One? It would be great to have an alternative for Shuriken as it's rather inconvenient to work on bigger projects without an external particle editor, but at the moment, Popcorn FX severely limits the available target platforms.
     
  7. Alverik

    Alverik

    Joined:
    Apr 15, 2016
    Posts:
    417
    Hi, noob question, I've just started to check out this plugin (just about to open the free pack in test project). But I noticed that in the tutorials you say you have to set the camera to deferred rendering. Is that mandatory for the plugin or does it depend on the particle effects you select/create? I ask because I'm currently working on PC project which is in Forward rendering.
     
  8. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi there, it's been a while since I last posted here.

    Indeed @ZJP we recently opened our own store, it allows us to provide different licensing schemes, including the personal license, thanks for pointing it out! :)

    @Crusare : We do have an XBone port, PS4 is lagging behind, unfortunately for technical reasons on Unity's side.
    It turns out the PS4 doesn't implement the command buffer interface properly with regards to access to the rendering context.

    @Alverik : Thanks for your interest in PopcornFX! Which tutorial are you talking about? Must be a pretty old one. We might need to fix that, since Forward rendering mode has been supported for a very long time, now.

    For the record, I'm currently wrapping things up for the next release of the plugin, making sure everything works on all the supported platforms and so on...
    What you can expect for the 2.8 is, among other things, sampler attributes (shapes, skinned meshes, textures, curves, text), full access to the C# sources of the plugin (still working on a sturdy solution to upgrade from a project created with the assemblies, coming up nicely) and OpenGL Core support for Macos and Linux!
     
    Alverik likes this.
  9. TechnicalArtist

    TechnicalArtist

    Joined:
    Jul 9, 2012
    Posts:
    736
    hi,

    Can possible Particle inter collsion ?

    dev
     
  10. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi all!

    I'm pleased to announce the v2.8 of the plugin is now live!
    Here's the changelog :

    - /!\ Moved from C# assemblies to sources (see http://wiki.popcornfx.com/index.php/Updater_(Unity_Plugin)).
    - Attribute samplers : shapes, textures, curves... (see http://wiki.popcornfx.com/index.php/Particle_effect_attributes#Attribute_samplers)
    - Fixed orthographic cameras support (see PopcornFX Preferences...)
    - Fixed glitchy billboarding on Android.
    - Added multi-object editing for FX components.
    - Fixed conf file loading when loading from a read-only location.
    - Fixed moving pkfx files breaking components association.
    - Fixed scene reset when destroying the first camera. /!\ A manual call to PKFxManager.Reset() when loading a new level is now required /!\
    - Added audio sampling named audiogroups.
    - Renamed native libraries from HH prefix to PK prefix, reflecting a name change that happened even before the plugin was released. You might want to check your Asset/Plugins directory if you didn't use the provided updater to update your project.
    - Added OpenGL Core support (Windows/Mac/Linux).
    - Stability improvements.

    @3d_Artist1987 : I'm not entirely sure what you meant by that, but if it's particle/particle collisions you're talking about, you can do that using our socalled "spatial layers" : http://wiki.popcornfx.com/index.php/CParticleSpatialDescriptor

    @Crusare (and @hippocoder IIRC) : We made good progress on the PS4 port (and XBone is pretty much done), please do get in touch if you'd still be interested in giving it a go (http://www.popcornfx.com/contact-us/ and for more info : http://www.popcornfx.com/unity-plugin-integration/ ).

    As always, feel free to ask your questions here or over at http://answers.popcornfx.com
    Ta-ra
     
    Last edited: Aug 9, 2016
  11. TechnicalArtist

    TechnicalArtist

    Joined:
    Jul 9, 2012
    Posts:
    736
    Thanks for reply.
     
  12. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    You're welcome!
     
    TechnicalArtist likes this.
  13. Hilm

    Hilm

    Joined:
    Nov 2, 2007
    Posts:
    338
    Hi, we're considering using popcorn on a client project I'm working on. We're attempting to change the mesh emitter of a popcorn particle system at run-time (on mobile); is this possible? I can't find any functions in PKFxFx that allow for this?

    (It's a mesh we're generating at runtime / that changes every so often (not once a frame, just on occasion)).

    Thanks!
     
    Last edited: Aug 11, 2016
  14. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi, thanks for your interest in PopcornFX.
    To answer your question : yes.
    Since v2.8 it's possible, thanks to the shape attribute sampler.
    It works by declaring such a sampler in the PopcornFX editor and setting it from Unity.

    Currently setting the shape at runtime through scripts require quite a bit of code, but we've already added some getter-setter methods to ease the process, to come in the next update.

    If you do decide to go through with PopcornFX and need help with the scripting part, come and ask over at answers.popcornfx.com
     
  15. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Looks like I forgot to post here to notify the FX packs update.

    All our FX packs on the asset store got an update, both for the PopcornFX runtime and the plugin version. Bringing all the bugfixes and features linked to both (most notably native VR support).

    Find them here :
    Discovery (free)
    Warfare
    Cartoon

    Cheers,
     
    ikemen_blueD likes this.
  16. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi everyone,
    Just a quick post here to let you all know I submitted the 2.9 update of the plugins to the asset store.
    I'll update the thread with the changelog and stuff when the Asset Store team validates the packages.
     
  17. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Aaaand we're live!
    Here's the changelog :
    • Attribute samplers : added getter/setters for easier access via scripts
    • Attribute sampler image : Logs an error when texture read is disabled.
    • Attribute sampler image : Added PVRTC support.
    • Attribute sampler shape : allow to drag an drop a MeshFilter on a sampler mesh.
    • Attribute samplers : Fixed broken list with unsupported samplers.
    • Attributes : fixed leak with attributes names when getting descriptors.
    • Attributes : now display their descriptions as tooltips.
    • Scene mesh builder : now creates path if it doesn't already exist.
    • Fixed a #define preventing the plugin to load on OSX when targetting iOS.
    • Added DeepReset : like Reset but also unloads FXs and clean the render mediums.
    • Now attempts to load the pack from relative path to prevent issues with non-ascii paths.
    • Added a "reset attributes to default values" button on PKFxFX.
    • Fixed checks for attribute samplers OnDestroy.
    • Fixed attribute sampler mesh : don't pin non-blittable types (bool).
    • Fixed sampler shape mesh : not feed with the mesh after StopEffect StartEffect.
    • Implemented native OSX assert catcher.
    • Sync. PopcornFX runtime v1.10.6 (@mittense ;) )
    Make sure you upgrade your editor and re-bake your effects.
    I'll be updating the documentation over the next couple days, making sure is up-to-speed.

    The effects packs have been submitted as well and should be available soon.

    Cheers,
     
  18. hakankaraduman

    hakankaraduman

    Joined:
    Aug 27, 2012
    Posts:
    353
    Hi,

    I have 2 questions;

    Does these effects work on all ios devices?
    What does "Only NEON" means for android devices? Thanks
     
  19. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi hakankaraduman,
    Yes, it does work on all current iOS devices.
    "Only NEON" means PopcornFX only runs on arm devices supporting the NEON instruction set.

    Hope this helps.
     
    hakankaraduman likes this.
  20. flexum

    flexum

    Joined:
    Jan 21, 2015
    Posts:
    2
    Hello.

    I've been trying to use the latest PopcornFX plugin with Unity 5.5. It looks not working.
    The rendered image was flipped in the final result image.
    I'm sure PopcornFX dose not support Unity 5.5 yet. However, may I have a chance to get some kind of hot-fix tips for using it on Unity5.5?
    Thank you.
     
  21. davide445

    davide445

    Joined:
    Mar 25, 2015
    Posts:
    138
    Hi appear the Unity plugin feature list is far less evolved than the Unreal one, any plan to complete some elements such as i.e. Mesh rendering illuminated from Unity lights?
     
    Last edited: Nov 5, 2016
  22. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hey @helements,
    Indeed, 5.5 still had issues with command buffers and native plugins last I checked the beta. I did report the bugs I saw back then and they should be fixed at some point.
    If you do see remaining bugs, please report them to Unity in the appropriate channels. If there's problems in 5.5 and not in 5.4, it's more likely due to changes on Unity's side. If you end up posting about such bugs in the dedicated forum, make sure to mention me in the topic so I can chime in if necessary.
    Also, keep in mind we don't officially support beta versions.

    Hi @davide445,
    The feature list for Unity is less developed than UEs because of the restrictive plugin API. We don't have access to most of Unity's rendering pipeline and can't use its materials. Unfortunately that means no lighting integration.
    A workaround is possible with the help of custom shaders (there should be an sample scene in the plugin package showcasing this) and point lights but that's still very basic and setting it up requires some knowledge about HLSL/GLSL depending on the targeted platform(s).
     
  23. flexum

    flexum

    Joined:
    Jan 21, 2015
    Posts:
    2
    Hello, @booyah ,
    Thank you for your reply.

    The 5.5 issue just happens in 5.5 and not in 5.4.
    And this is what is the cause of the issue I suppose.
    https://twitter.com/timsoret/status/768082633821650944/photo/1

    Depth Buffer is now reversed in Unity 5.5. PopcornFX shall switch to reverse depth buffer in 5.5.
    I don't rush to fix the issue. just notifying.
    I'm looking forward to getting the next update for Unity 5.5!
     
  24. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Heya!
    Yeah, we're looking into this.
    The fix should be available by the time 5.5 comes out.
     
  25. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
  26. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    @booyah, Hi!
    I'm very intrested in your sustem... but my game dont use built in unity shaders and some render functionality will fully overwritten (for example we use fully custom sm5.0 transparancy). Your system can be rendered with custom shaders or not?
     
  27. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi!
    Thanks for considering PopcornFX.
    You can find more details on the rendering integration on our wiki here : http://wiki.popcornfx.com/index.php/Rendering_Pipeline_(Unity_Plugin)#Unity_5.2.2B
    Please note our particles are rendered with native code, not with Unity's materials/shaders.
    We do however support custom shaders albeit with a slightly convoluted process (more on that here : http://wiki.popcornfx.com/index.php/Custom_Shaders_(Unity_Plugin))
     
  28. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    Thx for answer... and another question... How I understand your plugin not provide collision with dynamic colliders and triggers? And can I save your assets into AssetBundle?
     
  29. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    You're welcome!
    Indeed, dynamic collisions are not supported at the moment due to Unity's native plugin interface's limitations.
    There is a way of implementing dynamic triggers, though. Using one of our features : the spatial layers, single particles can act as the center of a trigger zone.
     
  30. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    @booyah what about asset bundles?
     
  31. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    We had a similar question on our answerhub recently, I'll just paste my answer here (please note that PopcornFX assets : fx files and textures, etc... are stored in StreamingAssets in order to be accessible from the native layer) :

     
  32. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    So... Thx for answers.... Its very strange choice for us. System looks very sexy and solid, but we cant build it in our pipeline... We need thinking about it.
     
  33. jeroenvdv

    jeroenvdv

    Joined:
    Oct 25, 2010
    Posts:
    52
    Good evening,

    Looks like an amazing Particle Engine. For my use, my application needs to be able to change quite some properties of the system during runtime. That could be possible via the Attributes system.

    However, I can't seem to find how to change the texture of, for example, the billboard renderer, from Unity C# code (so during runtime). Will that be possible in the (near) future?
     
  34. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hey, thanks!
    We also have a $25 version of the plugin on our website, for personal use. You could use that to evaluate whether the investment is worth it or not.

    Hi, thanks for the kind words.
    Yeah, changing the actual textures bound to the material isn't currently possible.
    Usually what is done to achieve that is grouping the different possible textures in a single texture atlas, binding the atlas to the effect and exposing an integer attribute to act as a "selector" for the texture to use.
    Of course that's more suitable for non-animated textures, atlases can become quite big when storing different flipbook animations.
     
  35. gyltefors

    gyltefors

    Joined:
    Apr 5, 2013
    Posts:
    48
    Hi,

    I am evaluating the use of PopcornFX for my project. The editor is Windows only, but runs in Parallels. Though there are some minor issues:

    1. Viewport navigation is hard coded, and can not be configured. The MagicMouse shipped with Mac:s only have one button, and it is possible to click on the right side for right click, but it is not possible to use middle click, or click left and right at the same time. The same restrictions apply when using a Wacom stylus.

    2. Path names for accessing the OS X side do not work, so the files have to be saved on the Windows side, which is a bit awkward.

    What is your priority for addressing these issues, so that Mac users can use PopcornFX while waiting for the native Mac version?

    Also, having a dedicated tool for particle system design, that still requires coding scripts for the emitters kind of defeats the purpose. I believe PopcornFX would attract much more users if you could replace that with a node editor.
     
    Last edited: Nov 25, 2016
  36. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Thanks for your interest in PopcornFX.

    It is currently not possible to rebind any viewport controls, unfortunately. However, navigation without middle click should be possible :
    Alt+left click : orbit
    Alt+right click : dolly
    Alt+left+right click : pan
    right click + WASD : fps mode.

    Not sure what this is about but it does sound like a virtual machine setup issue rather than a PopcornFX editor problem.
    Did you setup any shared disk space between your host and guest?

    Our limited resources are currently heavily focused on the v2 of the (multi-platform) editor that should address all these issues. Unfortunately that means we're unlikely to address the same issues in the current editor.

    Yeah, we're working on that for editor v2. :)
     
  37. JeiBell

    JeiBell

    Joined:
    Oct 1, 2013
    Posts:
    4
    Hello PopcornFX team,

    There seems to be a resource consumption bug in your runtime PKFxCamera.OnPreRender() for OSX 10.10.1 Unity 5.4.1f1.

    In testing your butterflies demo package I disabled all particle effects except 1 of the 8 butterfly emitters, which was configured to have 100k flux (spawn count?). Initially, the FPS were high and then proceeded to drop at a steady rate; no other actions were being made, I was simply watching them fly around for 10 mins.



     
  38. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi!
    The increase is seen in OnPreRender because the particles' update is done there.
    It also turns out this particular effect has a bug : the way it's made has the annoying side-effect of increasing both the particle count AND the update time on low framerates.
    This is likely due to precision issues with the collision detection at lower framerates, triggering some state switching twice thus duplicating the particles.

    So with such a high flux you get a lot of particles that have a chance of "cloning", increasing update time which in turn makes every particles' update more expensive, increasing the chances of cloning, etc... Basically an unlucky combination of factors leading to a feedback loop killing the framerate.

    This flaw in the FX' design isn't visible at higher framerates and/or more precise (albeit more expensive) collision detection settings.

    If you'd like to benchmark/profile long simulations, I'd suggest trying with a more stable effect by design.
    We've let scenes run overnight in the past, it shouldn't be an issue.

    Cheers,
     
  39. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    @booyah, I have question again =)
    Now Unity expose native id for meshes (you can acess it from your plugin, if I have correctly understood). Do you plan use it for render your particles with unity shaders or not? I asking because integration its very weak side of your project... =(
     
    Last edited: Dec 5, 2016
  40. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hey!
    No promises but I'm currently evaluating if that's a viable option.
     
  41. AaronClark

    AaronClark

    Joined:
    Oct 14, 2013
    Posts:
    39
    @booyah Any update on the cross platform editor? I have been waiting a couple years for this as I am sure a number of others have as well.
     
  42. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    We're currently actively working on it. V2 will definitely bring osx and linux support to the editor's feature list. :)
     
  43. AbyssWanderer

    AbyssWanderer

    Joined:
    Mar 15, 2016
    Posts:
    77
    Hello there!

    First of all, your asset is amazing and worth every cent. Really wonderful platform.
    Just as I wrote it, I understood that you would prefer to see this in AssetStore's review section :)
    Will do that afterwards)

    For now we have several questions to ask:

    1) In this video you can see that after 9th second fire in the smoke starts blinking as if it's rendering queue is changed.
    Bug appears after lots of fire spots are spawned (both at runtime or if placed on scene).

    Could you help us to get rid of this blinking?
    (Fire spots are taken from Torch effect you have in Samples)

    ----------------
    2) We spawn these fire spots after Flame Thrower (from Sci-fi Effects) touches the collider ==> hence lots of these spots may appear and disappear ==> hence we've set up pool manager. And mystics begins.
    After despawning the effect it is still rendered - looks like "PK Fx Rendering plugin" keeps doesn't know about despawning.

    The only way to stop the effect is to remove "Pk Fx FX" component on fire spot. It's not so bad, but kinda awkward way.
    Do you have some sort of command to do that nice and clean?

    ----------------
    3) Ideally we would like to use Popcorn's FlameThrower instead of Sci-Fi Effects - it has better both visuals and perfomance.
    But the question rises - how to hit moving geometry?
    Baking geometry every update is obviously not an option.

    Can you advise any way around? This is not only about FlameThrower, of course, but about many other effects. We would agree on quality decrease, but really need some collisions on dynamic meshes.

    ----------------
    4) There are other cool effects in your library that we would use - but unfortunately they can't be baked in Popcorn editor.
    For example, "Static_Lightning" or "ElectricalBall_pCoords" located in folder "Magic".
    Upon baking they throwgh something like this:

    Error : [ BaseObject ] Skipping unknown HBO field "Autostart"...
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking platform "unity" to "C:/Users/Sallah/Documents/Builds/unity/Popkorn"
    Error : [ BaseObject ] Skipping unknown HBO field "Autostart"...
    Error : [ BaseObject ] Skipping unknown HBO field "Autostart"...
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (Evolve-sub)
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (Evolve-cst)
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (spawn)
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking 7 dependencies...
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/Lightning_05.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/AtlasX4.pkat
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/SymmetricGradient_02.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/Glow_03.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/Distortion_01.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/Stars_01.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking dependency Textures/Fx/Trail90_01.dds
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baked 7/7 dependencies OK
    Info : [ ??? ] [BakeAsset] "Particles\Magic/Static_Lightning.pkfx": baking OK



    Or "SimCache_Advect" effect in "V1110" folder returns this:

    Info : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baking platform "unity" to "C:/Users/Sallah/Documents/Builds/unity/Popkorn"
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (Evolve-sub)
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (Evolve-cst)
    Info : [ Particles ] No suitable script IR cache found. Recompiling script (spawn)
    Info : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baking 2 dependencies...
    Info : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baking dependency Particles/v1110/AdvectParticle.pksc
    Error : [ ??? ] [BakeAsset] "Particles/v1110/AdvectParticle.pksc": FAILED
    Info : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baking dependency Textures/FX/flare.png
    Info : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baked 1/2 dependencies OK
    Error : [ ??? ] [BakeAsset] "Particles\v1110/SimCache_Advect.pkfx": baking FAILED

    Could you, please, direct us where to fix these errors?
     
  44. AbyssWanderer

    AbyssWanderer

    Joined:
    Mar 15, 2016
    Posts:
    77
    I apologize, "Static_Lightning" and "ElectricalBall_pCoords" work despite the errors.
    But "SimCache_Advect" doesn't.
     
  45. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi!
    Thanks for the kind words, we'd love to see them in a review, indeed. :)

    By default the draw order is determined by the renderers' positions and bounding boxes. When spawning several effects instances, the compatible layers are merged together for rendering. It's the merged renderers that are used for this, so in this case, the fire and the smoke must have overlapping bboxes and tend to switch orders.

    To get rid of this issue I can think of a couple solutions :
    - Use an arbitrary draw order value. On each effect's renderers it's possible to set an arbitrary draw order value, so that a renderer is always rendered before or after the others. This is practical when the order isn't supposed to change at ANY time, which may or may not be your case here.
    - Merge the renderers into one. Because compatible renderers are merged before they are sorted and drawn to save drawcalls. To achieve this you'll need to have the renderers have the same material (what seems to be a flavour of alphablend in this case, additive can be adapted to work with alphablend with the additive_alpha material anyway), the same texture (you might have to stitch them together in an atlas and manually set the texture ID in your effects) and the same draw order (other renderer settings might also break the compatibility but they're less commonly changed).

    Have you tried using PKFxFX.StopEffect or PKFxFX.KillEffect at some point?

    So, this is a tricky one. Since we do both the simulation and rendering in a native plugin we can't directly interact with unity's dynamic geometry.
    A convenient workaround that we've been using would be to use what we call the "spatial layers".
    The way it would work would be by having an invisible effect, made of a single particle in a localspace evolver inserting itself in a global spatial layer, acting as a dynamic collider.
    The flamethower (or any other effect) would then have to query that global spatial layer and kill/change the bahaviour of the particles that are too close to one of the aforementioned invisible particles.

    All you'd have to do in unity would be attaching those invisible effects on every pieces of dynamic geometry.

    We actually have an example of such a mechanism in a demo we showed at GDC this year :

    It's subtle but the spheres eject some particles when the cube gets close.

    More on spatial layers on our wiki.
    Also this quick tip video.


    As you said, those 2 first actually baked properly and those errors can be ignored safely.
    For the simcache one, I don't think it should fail that way, I suggest you send us an email to support@popcornfx.com so the editor guys can look at it.

    Cheers,
     
    overthere likes this.
  46. AbyssWanderer

    AbyssWanderer

    Joined:
    Mar 15, 2016
    Posts:
    77
    Hello Raphaël.

    Thank you for detailed answer!
    I've posted the review back then and have just updated it to 5 stars, as we were able to switch flamethrower on collisions with dynamic obstacles.

    However, we still can't get rid of blinking on video from previous post.
    - Could you, please, send link on documentation about arbitrary draw order ?
    - Also, could you advise: which tools (Unity tools or settings in Popcorn-editor) we can merge renderers of effects?

    Thanks in advance
     
  47. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi,
    Sorry I couldn't answer you earlier, I was on holiday the last 3 weeks.
    Glad to hear you got the flamehrower working, though!
    The documentation for the draw order can be found here and we have a video covering renderers batching here :
     
  48. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    @booyah, Hi!
    Any news about use external meshes in your asset? Very intresting use it but with standart unity rendering pipeline and unity shaders.
     
  49. ArtyBoomshaka

    ArtyBoomshaka

    Joined:
    Mar 5, 2013
    Posts:
    226
    Hi there!
    Yes, absolutely.
    Shortly after you suggested it I started working on a solution using the new API and it's looking promising.
    I had to scrap a lot of code and refactor a lot of stuff so the road towards feature parity might be a bit bumpy and take some time but we'll get there.
    Here's a glimpse of what the new renderers look like :

    (edit not sure why the img embedding works in the preview but not in the final post... here's the link : http://i.imgur.com/nuscAzm.gif)
    (the most interesting part is the mesh particles renderer, complete with shadows. The editor view rendering comes for free with the new set of renderers ^^)
    In their current state they're implemented both in DX11 and OpenGL and run on both windows and macosx.
    I'm working on the Metal implementation and when that's proven to work we'll move on to implementing the full features.

    On a side note, all our plugins and FX packs are currently on sale on the Asset Store.
     
  50. NeonTanto

    NeonTanto

    Joined:
    Jun 19, 2013
    Posts:
    156
    Wow! Impressive!!! Its very nice!