S
S
Sergey2020-06-14 14:34:11
JavaScript
Sergey, 2020-06-14 14:34:11

On what to render the simulation with an increasing number of objects?

For demonstration (training) purposes, you need to visualize a dozen simulations of some processes that mainly describe the behavior / movement of some objects. In some ways it looks like conway's game of life, some looks like some kind of game simulation. In general, the ideas are heterogeneous, but a common problem is a large number of objects or increasing exponentially.

Because I know JS more or less tolerably - I used 2D Canvas in the browser (at first it was enough), but I came across the fact that with 60fps rendering with simple logic and collision calculation - one canvas in the browser decently loads the processor, on the cooler - as if running stress tests ) with the number of objects up to a hundred, and with an increase in the number of objects and logic - on the slideshow screen, on the cooler - a fireplace.

What lower-level alternative to JS and 2D Canvas can be used without drowning in manual memory management and learning C|C++?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
maaGames, 2020-06-14
@paper_castle

WebGL
But I have a suspicion that the brakes are due to the calculation of collisions. Surely there is no check for the collision of each with each?

M
mayton2019, 2020-06-15
@mayton2019

Read about Web assembly. In theory, this technology allows you to simply run very fast code in a browser environment. I won't say anything about languages.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question