Uppsats

Performance Comparison of WebGPU and WebGL for 2D Particle Systems on the Web : An analysis of GPU time in web-based graphics APIs

Master-uppsats

KTH/Skolan för elektroteknik och datavetenskap (EECS)

Publicerad: 2024

Språk: Engelska

Sammanfattning

This thesis investigates the comparative performance of WebGPU and WebGL in the context of 2D web-based particle systems, which lies in the area of web graphics and GPUs. WebGPU represents the next generation of web graphics API and introduces a more modern design than WebGL, including compute shaders to facilitate general-purpose computations on the GPU. However, the API is still under development and lacks full cross-platform support which makes it a relatively unexplored area of research. This study tests the performance of these APIs using particle systems entirely run on the GPU in a Google Chrome Canary browser, measuring total GPU time, render and compute time per frame, and initialization time over varying numbers of particles, sizes, and types of particles on two different GPUs, a high-end NVIDIA GeForce RTX 3080 and a lower-end GPU, Intel(R) UHD Graphics 620. The findings of the tests show that WebGPU significantly outperforms WebGL, particularly on the high-end GPU, where the updating of particle positions every frame is reduced by approximately 100 times using WebGPU over WebGL. Even on the lower-end GPU, the compute time is improved by 5 to 6 times with WebGPU. The maximum number of particles at 60 fps using WebGPU on the high-end GPU is about 37 and 20 million, depending on the type of particle. For WebGL, it is about 2.7 and 2.3 million. On the lower-end GPU, it is about 2.1 million and 398 000 for WebGPU, whereas, for WebGL, it is around 374 000 and 310 000. The results highlight the significant performance benefits that WebGPU offers and quantify the improvements compared to WebGL, which contributes to a broader understanding and insights into WebGPU as an upcoming cross-platform web graphics API.

Information

Författare
Palmér, Saga
Lärosäte / institution
KTH/Skolan för elektroteknik och datavetenskap (EECS)
Publiceringsdatum
2024
Uppsatstyp
Master-uppsats
Språk
Engelska

Utforska vidare

Liknande uppsatser

Uppsatser med liknande ämnen och nyckelord.