3 ms·
> Do you mean TypedArray? [0] Yes, generally you'll want Float32Array, but I guess which TypedArray you'll want to use in your code use will depend on use. >
by kypro 3y ago
> Do you mean TypedArray? [0]
Yes, generally you'll want Float32Array, but I guess which TypedArray you'll want to use in your code use will depend on use.
> I already use Web Workers with async calls to divide main task into smaller pieces and not to block main render. But I am pretty new to this concept so I don't grasp fully what is the overhead of using this method.
If you can you'll want to use a "transferable object" to reduce overheads when passing data into worker thread,
https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Transferable_objects https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers...
If you're using Web Workers this is a great video to watch and it discusses "transferable objects" around the 7 minute mark,
https://www.youtube.com/watch?v=pQPqhZRUz3U https://www.youtube.com/watch?v=pQPqhZRUz3U
The other thing I forgot to mention was to avoid using async/await wherever possible. I'm guessing you're not using it unnecessarily anyway, but it will add a significant overhead to your method calls if you are.
- chilling 3y agoamazing video! Thank you very much