Bilge Posted February 3, 2015 Share Posted February 3, 2015 In my case I have many such large shapes but they are only outlines. These shapes are so large they may cover the screen many times over. However, since only the edges should be rendered it is possible that only its transparent centre sits in the view. Should I create large sprites or is it too memory inefficient? Is it better to draw directly to the canvas? If so how can I do this? Link to comment Share on other sites More sharing options...
Raicuparta Posted February 4, 2015 Share Posted February 4, 2015 I'm not an expert, but I'd say the most memory efficient way to do this would be to draw using BitmapData, as this would avoid having lots of sprites that need to be drawn every frame. Link to comment Share on other sites More sharing options...
clark Posted February 4, 2015 Share Posted February 4, 2015 Hey Bilge, are your shapes provided as textures (like a png) or are you drawing them dynamically with code? Link to comment Share on other sites More sharing options...
razorMonkey Posted February 4, 2015 Share Posted February 4, 2015 Also not an expert, but it seems to me that you need vector graphics. Hope this will help at least a little bit: http://www.w3schools.com/html/html5_svg.asp I do not have any personal experience with that in HTML5 Link to comment Share on other sites More sharing options...
Bilge Posted February 4, 2015 Author Share Posted February 4, 2015 Hey Bilge, are your shapes provided as textures (like a png) or are you drawing them dynamically with code? I will draw them with code. Link to comment Share on other sites More sharing options...
Recommended Posts