I try to implement an online painter, i.e. there is a certain area where anyone can draw anything.
How to make, that after change (one person drew) and changes received everything?
I try to implement an online painter, i.e. there is a certain area where anyone can draw anything.
How to make, that after change (one person drew) and changes received everything?
The university had a similar task. As one of the ways: after a person clicks on a region and leads along this region (draws a line), the handler reads all coordinates, draws small straight lines between these coordinates, an array of coordinates and a line drawn by the user are obtained. Then there are several options: either every time the point is read, send to the server, which, in turn, sends to everyone, or as soon as the user releases, send the entire array at once.
Source: https://ru.stackoverflow.com/questions/522534/
All Articles