Re: Speed comparison with imageData 1920x1080
The canvas2d dataURL-methods (and LC's base64-methods) are so far optimized that it is even slower if one directly sends and receives arrays, I tried it. There could be more gain (what would give a speed-up-factor of up to 500) by using webGL, but this has issues with some 'black-listed' graphic cards. Also this is interesting for video-postprocessing/ animations/ 3D-Rendering only. For image processing canvas2d is fast enough and _very_ comfortable for complex filtering by internally using Uint8ClampedArrays. My HTML5/JS template given in the speedCcomparison stack is as simple as possible so that for a LiveCoder who ever worked with imageData, to write the basic image filters is learned in 15 minutes. ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Speed comparison with imageData 1920x1080
hh wrote: Here is a stack that compares simple grayLevel- and invert-filter for an image of size 1920x1080, needs LC 8 or 9. It shows the power of this "external" we have via LC Builder/the browser widget. go stack url ("http://hh.on-rev.com/xstacks/speedComparison.livecode";) or download the file http://hh.on-rev.com/xstacks/speedComparison.livecode.zip (1 MByte) The LC Script version is, TMHO, rather fast (feel free to improve it). The HTML5/js version could be optimized but that may be too hard for the result ... Thus the first HTML5/JS call is slower than the following (initiates caching). The average speed improvement depends on your hardware, this HTML5/JS version will be in average 20-60 times faster than LC Script. Note. The improvement is mostly due to the fact, that HTML5/JS uses your graphics hardware. With a decent graphic card the speed factor is here (for less simple filters) up to 100. Very interesting. Thanks for posting that. I wonder how much speed could be gained if we didn't need to do so much type coercion? -- Richard Gaskin Fourth World Systems Software Design and Development for the Desktop, Mobile, and the Web ambassa...@fourthworld.comhttp://www.FourthWorld.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Speed comparison with imageData 1920x1080
Here is a stack that compares simple grayLevel- and invert-filter for an image of size 1920x1080, needs LC 8 or 9. It shows the power of this "external" we have via LC Builder/the browser widget. go stack url ("http://hh.on-rev.com/xstacks/speedComparison.livecode";) or download the file http://hh.on-rev.com/xstacks/speedComparison.livecode.zip (1 MByte) The LC Script version is, TMHO, rather fast (feel free to improve it). The HTML5/js version could be optimized but that may be too hard for the result ... Thus the first HTML5/JS call is slower than the following (initiates caching). The average speed improvement depends on your hardware, this HTML5/JS version will be in average 20-60 times faster than LC Script. Note. The improvement is mostly due to the fact, that HTML5/JS uses your graphics hardware. With a decent graphic card the speed factor is here (for less simple filters) up to 100. ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode