Search Unity

No gpu skinning on WebGL 2

Discussion in 'Web' started by kognito1, Jan 6, 2017.

  1. kognito1

    kognito1

    Joined:
    Apr 7, 2015
    Posts:
    331
    Hello,

    I was hoping that mesh skinning could be done on the gpu with webgl 2 (I believe the requirement for gpu skinning on mobile is opengl es 3.0, which is basically what webgl 2 is). But when I checked the profiler after making a build, it still reported that mesh skinning was being done on the "slow path" (cpu). I checked the console log in chrome and confirmed it was using a webgl 2 context. Is this the expected behavior? Without threading and simd support, mesh skinning on the cpu is our biggest bottleneck so I would love to offload it to the gpu if possible. Thanks!
     
  2. kognito1

    kognito1

    Joined:
    Apr 7, 2015
    Posts:
    331
    Just a small bump, I asked Aras about it and he didn't know for sure why it was disabled. If gpu skinning for webgl 2 is not in the cards that's completely fine, just want to set expectations. It could really help this platform!
     
  3. jonas-echterhoff

    jonas-echterhoff

    Unity Technologies

    Joined:
    Aug 18, 2005
    Posts:
    1,666
    WebGL 2 supports transform feedback, so it is in theory capable of running our GPU Skinning implementation. However, in all our tests, it was consistently slower then CPU skinning in current WebGL 2 implementations, which is why we disabled it. I think it should not be slower, and I don't know the issue here. I have tried to figure it out with the browser vendors, but not success so far.
     
  4. kognito1

    kognito1

    Joined:
    Apr 7, 2015
    Posts:
    331
    Thanks for the explanation and effort, we greatly appreciate it. Surprised it was slower; skinned mesh rendering on webgl is already...not fast. :D It's a huge bottleneck for us.

    No worries though, I'll file this under "not happening in the near future". If you ever need more data points testing skinned mesh rendering on the gpu, we would be happy to be guinea pigs!
     
  5. kheldorin

    kheldorin

    Joined:
    May 28, 2015
    Posts:
    22
    Is this going to be reevaluated with the latest browser versions? CPU skinning on webgl is slow.
     
    nperrier_manzalab likes this.
  6. Zarbuz

    Zarbuz

    Joined:
    Oct 13, 2015
    Posts:
    44
    Bump ! CPU skinning is still very slow on 2021.3 LTS version for WebGL 2 ..
     
    OceanX000 and ZerglebReal like this.
  7. ZerglebReal

    ZerglebReal

    Joined:
    Apr 27, 2021
    Posts:
    7
    ^ Agreed. It's been a long time perhaps it's a chance to take another look?