Search Unity

Why perfoms PlayCanvas much better than Unity

Discussion in 'General Discussion' started by FionNoir, Mar 22, 2018.

  1. FionNoir

    FionNoir

    Joined:
    Aug 25, 2015
    Posts:
    14
    I think this is a complex question, but I want to encourage the discussion about the Unity WebGL development and it's weaknesses at the moment. For me a huge problem is the high loading (initialization) time and the bad performance of Unity WebGL. It's still better than Unreal WebGL player but at the moment I'm forced switching to PlayCanvas cause this factors are unreasonable for my clients. But why performs PlayCanvas that much much better, how can Unity WebGL get up to the same level and till when is this possible?
     
  2. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,147
    For the exact same reason that GameMaker excels at 2D. PlayCanvas is built solely for the web which means that any optimizations made to the core are able to be made exclusively for it. Contrast this to Unity which has to take multiple platforms into consideration and can't be solely designed around one of them.
     
    lmbarns, carking1996, Kiwasi and 5 others like this.
  3. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    8,194
    Unity is working on a 72k web html build that should in theory fill this gap.

    Also the developments in a light rendering solution could improve WebGL builds being lighter and faster
    on lower spec hardware.
     
    DungDajHjep and FionNoir like this.
  4. FionNoir

    FionNoir

    Joined:
    Aug 25, 2015
    Posts:
    14
    Thanks for your reply! I understand the difficulty to support multiple platforms like it Unity does. But does this mean that there is no way to improve the performance in near future? That's something I can't imagine cause Blend4Web for example has a better performance and it uses the Blender Game Engine for development which was never designed for WebGL too.
    So after compiling there isn't anything left from the "original" game engine, isn't it? It's only a JavaScript code controlling WebGL.
    I just want to know where is the bottleneck. Is it the effort spend in one single compiling processor? And is the need for a better WebGL compiler much lower than I've expected? Haven't found any numbers for the usage of WebGL with Unity. But there aren't many visual editors out there that can compile to WebGL.
     
  5. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    8,194
    It depends on the build target you can also build to wasm which, in browsers that support it, should be much faster that javascript.

    Do you have an example as in theory Unity should run as fast as any other engine or at least fast enough?

    Also have you tried the profiling tools in Unity as they can really help at pointing out problem areas?
     
  6. Zarod

    Zarod

    Joined:
    Jan 20, 2016
    Posts:
    59
    update:

    Based on my testing, The fragment cost that Playcanvas has for anything that isn't vertex color or albedo is INSANE !

    Geshin impact runs flawlessly on my new phone 200 euros phone ... but the Demo they supposedly make investors watch tanks at 30 fps x___x' ( when you reach the room with the plant monster )

    I would need to be more knowledgeable to be sure, and I hope i'm not mistaken, but I'm so saddened by this that it jest feels like false advertising.
     
  7. DragonCoder

    DragonCoder

    Joined:
    Jul 3, 2015
    Posts:
    1,696
    From what I heard Genshin impact uses a LOT of tricks and likely threw kilotons of money at performance optimization because so much depends on it.
    An engine that is meant to be maximally versatile will have trouble optimizing to this level because versatility is always the enemy of performance...

    Furthermore, think when you show something investors, it's likely not on low end current hardware, because hardware progresses at least one or two generations until a game with the presented tech is published.
    On Mobile you still cannot go all out with features as an indie, sadly.
     
  8. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,147
    Optimizations that undoubtedly include modifying the engine thanks to having the budget for a source license.
     
    Last edited: Nov 5, 2022
  9. DragonCoder

    DragonCoder

    Joined:
    Jul 3, 2015
    Posts:
    1,696
    Yes, but do you think those are changes to the source which could just be brought over into the official Unity releases without breaking/reducing other functionality which Genshin doesn't use?
     
  10. Zarod

    Zarod

    Joined:
    Jan 20, 2016
    Posts:
    59
    Genshin is not "THAT" optimized

    Don't know if they upgraded in the meantime, (cuz i was testing it the month after release) but It used the same exact unity version I was using, and performance was identical when i tried doing similar stuff.

    In short don't get intimidated, cuz there's plenty more work to do and results to achieve using Unity alone.

    Sometimes it feels like I'm using a completely different engine from the one people shame me for, lol
     
    DragonCoder likes this.
  11. Andy-Touch

    Andy-Touch

    A Moon Shaped Bool Unity Legend

    Joined:
    May 5, 2014
    Posts:
    1,483
    Is that 100% confirmed anywhere?
     
  12. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,147
    It's an assumption based on how much of a budget they would have. It's not necessarily major changes either.
     
  13. Andy-Touch

    Andy-Touch

    A Moon Shaped Bool Unity Legend

    Joined:
    May 5, 2014
    Posts:
    1,483
    Would prefer some kind of official confirmation from the studio rather than just assuming 'they have lots of money so must be true lol'.:D
     
    Ryiah likes this.