Poko Posted February 19, 2018 Share Posted February 19, 2018 Hi everyone, I'm actually working on an app using phaser. I receive inputs from a device and i need to draw the last 200 points received each frame. I looked all day trying various solutions with bitmapdata and render textures but i couldn't find any way to draw all thoose points at once, each time i check with the firfox's canvas inspector i get to 202 drawings with something like 800 calls, i'm totally lost. Could any one help me? Thank you in advance! Link to comment Share on other sites More sharing options...
samme Posted February 19, 2018 Share Posted February 19, 2018 I think you would have to use a SpriteBatch (or just ordinary Sprites) to take advantage of WebGL batch drawing. Link to comment Share on other sites More sharing options...
Poko Posted February 20, 2018 Author Share Posted February 20, 2018 Thanks for your answer, but i totally forgot to precise that i'm working on CANVAS mode, the app is running with ionic cordova and WebGL had really poor performances. Anny suggestions? Link to comment Share on other sites More sharing options...
Tom Atom Posted February 20, 2018 Share Posted February 20, 2018 You do not precise how you are drawing individual points. If one by one with something like RenderTexture.RenderXY(), then points are not batched. Instead create group, put points into it and then draw whole group at once. I had similar problem in past, here is detailed post: DanielKlava 1 Link to comment Share on other sites More sharing options...
Recommended Posts