PTR Changelog 2017-09-14: WebGL renderer (WIP)


  • YP

    currently getting a upgrade notice on the ptr that I can't get rid of (tried all keyboard combos and even disabling all caches in chrome development tools)

    also getting an error:

    build.min.js?bust=1506510255327:1 Uncaught (in promise) TypeError: a.setTerrain is not a function
        at build.min.js?bust=1506510255327:1
        at <anonymous>
    

  • Culture

    It is amazing how much less battery is used by the client when in WebGL mode. I am very, very happy with the performance difference. I've been sitting outside with the client running in the background and my laptop fans haven't even turned on (with the older client it would literally blast the fans at max).


  • Culture

    I'm also having massive improvements in CPU efficiency. Normally while having screeps open I could not properly play another game without stutters every tick update. With the webgl version I still get solid FPS's in other games.

    I found out by accident yesterday that portals are not yet rendered in the new client.


  • Dev Team

    A new patch has been deployed to the PTR! It includes display and animation of more objects, improved landscape visualization and lighting effects. See how it looks in this GIF:

    0_1507883011412_webgl.gif

    Only a few minor improvements and bug fixes are remaining. We expect to deploy it to production on the next week.



  • @artch: Seems to be broken for now (Chrome Version 61.0.3163.100 (Official Build) (64-bit), Linux 4.4.0-96-generic Ubuntu Tue Sep 12 14:59:54 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux).

    UPDATED:

    Integrated: VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06) (prog-if 00 [VGA controller])

    NVIDIA: GForce 740m

    Screenshot:

    0_1507808975826_Screenshot_2017-10-12_14-47-00.png


  • Dev Team

    @mototroller Please enable "Show renderer metrics" option and check if it displays "Renderer: WebGL" in the top left corner? I believe it doesn't. What is your GPU model?



  • @artch previous post upfated, you are right, seems like some issues with GPU and f*king NVIDIA+Intel integrated graphics.


  • Dev Team

    @mototroller Does this link show that your browser supports WebGL at all? https://browserleaks.com/webgl



  • @artch: looks like yes, but gonna investigate:

    Details:

    0_1507809469109_Selection_263.png


  • Dev Team

    @mototroller You might probably need to enable WebGL 2.0 in chrome://flags/#enable-es3-apis



  • @artch: I've already tried this, but it might be an issue with nvidia drivers/default graphical adapter/Intel integrated hardware accelerator/Bumblebee drivers for Intel-nvidia ad-hoc switching in Linux. Thanks, never mind, I gonna try another options, but this conversation should stay here with its keywords. I'll post a solution in case of success.

    Another useful link -- WebGL 2 enabling


  • Dev Team

    The fix for disabled WebGL is deployed. It won't show any fancy lighting effects, but at least will remain playable.


  • Culture

    The lightning / swamp effects seem to have a very big impact on performance:
    Poor FPS since the new update

    I've tested it on this room: https://screeps.com/ptr/#!/room/shard1/W48N8

    As for specs:

    Specs



  • @artch: yep, it's working (without lightning effects, but ok).

    UPDATED: there may be issues with Intel Optimus + Bumblebee drivers (this was my case and it described above). Solution : install and use Nvidia Prime instead of Bumblebee (link).

    Screenshot and adapter details after Nvidia Prime enabling:

    0_1507814781178_Screenshot_2017-10-12_16-23-57.png

    0_1507818496120_Selection_264.png

    Thanks for help. Anyway, there are lots of possible problems with Linux + NVIDIA drivers, especially for laptops with integrated Intel graphics, they aren't Screeps issues.



  • @dissi are you sure about it's a real impact? FPS showed by metrics isn't stable, but scaling/moving around a room map is pretty smooth. I've got worse NVIDIA GForce GT 740m than you, and metrics shows FPS 10-100 with average is about ~50.



  • @dissi @artch can confirm glitches, yep, FPS is strongly depends on view scale. The higher camera is, the higher FPS is, and vice versa.


  • Dev Team

    You probably have your integrated GPU enabled instead of NVIDIA. "Unmasked Renderer" via this link should display your GPU model, try to configure your setup so that it displays your actual GPU.


  • Culture

    @artch You were correct. It used the:

    ANGLE (Intel(R) HD Graphics 530 Direct3D11 vs_5_0 ps_5_0)

    I've forced the graphics driver to the actual graphics card:

    ANGLE (NVIDIA GeForce GTX 960M Direct3D11 vs_5_0 ps_5_0)

    Result: All the FPS

    You can do this with nvidia as follows:

    Config


  • YP

    this really looks good 🙂

    maybe you could do a minimal power mode for laptops or slow computers that disables all optional fogging and stuff like that? I really like it for desktop use but might want to disable it on laptop while on battery .)


  • Culture

    @w4rl0ck even with all the fun bits turned on I'm not seeing that much of a performance difference and my battery life is amazing compared to what it previously used to be while running screeps.

    I also just want to say that this looks amazing. The increased contrast makes it much more visible in high glare areas.