[PLUGIN] Canvas

From the Asset Store
Pixel Destruction like in "Worms" (Drawing Canvas based)
  • newt

    I'd rather not remove features if I can.

    clrammer

    Opps, re-download the plugin to eliminate the javascript error.

    And yeah, the performance issue is related to webgl and this plugin.

  • Ok, not a big deal I guess.

    Also:

    Ios doesn't use webgl.

  • R0J0hound

    Let me preface by saying thank you for this plugin, it's a great asset!

    I'm working with clrammer on the same project, and we are both psyched to see an update to address the performance hit introduced with CJS 1.4.

    We haven't seen a difference in performance, but we are probably missing something since it works for others.

    2 Questions:

    1) Was just wondering if minifying the script is necessary for the performance fix? I don't see why it would, but worth asking.

    We haven't been using it (or able to use it) because of conflicts during export with 64-bit java, and due to our lack of understanding of the minifying process we just kind have been forgoing that aspect.

    2) What operating systems / devices do you personally test on? In what capacity have you tested iOS?

    I'm sure we are probably overlooking something at this point, just trying to identify what it is.

    SirSpunky

    What operating systems / devices are you testing on that you noticed the performance gain?

  • Sigmag

    1) The minifying bug isn't the cause of the performance hit. The hit is from using canvas2d internally and copying it to a webgl texture every frame. A proper fix would be to only use webgl when it's enabled.

    2) I test on a 10+ year old laptop with winxp/sp3 and a 5+ year old laptop with vista. Due to their age and a lack of updated drivers I only get a marginal speedup from using webgl. I have both android and ios devices but I haven't tested on them.

  • R0J0hound

    So the memory leak fix in your latest update doesn't address canvas copying to webgl texture? I take it that a proper fix would require a code overhaul with a large time commitment on your part?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Question: can I use minifying?

    I'm getting an empty c2runtime.js

    Thanks.

  • I found a workaround: I'm using a YUI compressor to minify the HTML5 script, works fine.

  • rojohound

    I hate being a devil's advocate, but I still have that memory issue when trying the updated example from keepee at dl.dropboxusercontent.com/u/53374990/Misc%20C2/Light%2BShadow/02/index.html

  • Ok, a quick update. Updated download on first post.

    *Fixed the issue with the minifier.

    *A optimization was added for webgl. A texture won't be created every frame if nothing has changed on the canvas. Now only after stuff was drawn to the canvas will it update. This will make it faster for projects that draw occasionally or just once. If stuff is to be drawn every frame then there will be no benefit.

  • tulamide

    Hmm... The memory usage stays stable for me on my vista computer. I'll have to try it out on the xp one and get back to you.

  • R0J0hound

    Thank you so much for the improvements. This helps a lot with the app we're working on!

  • Great plug-in indeed. Would it be possible to allow drawing only a part of the canvas, by defining a rectangle or something?

  • Thanks R0J0, now seems to work great on minify, thanks a lot!

  • R0J0, would you be offended if I said I made a new icon?

    It may stand out just as much to some because it's not as 2d as the standard ones, but it uses the color scheme.

    <img src="https://dl.dropboxusercontent.com/u/85412219/forumposts/CanvasIcon.png" border="0">

    If anyone wants it.. https://dl.dropboxusercontent.com/u/85412219/forumposts/Canvas-PluginIcon.ico

  • Great plug-in indeed. Would it be possible to allow drawing only a part of the canvas, by defining a rectangle or something?that would kind of defeat the whole purpose of using it, don't ya think? You could just use a smaller canvas.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)