Re:How Math Helped Me Write Less Code and Made Our App Faster
by eru on Wednesday February 12, 2014 @04:32AM
(#7223372)
> Now imagine doing this on the front-end
Like, in the browser?
Re:How Math Helped Me Write Less Code and Made Our App Faster
by noelwelsh on Wednesday February 12, 2014 @06:38AM
(#7223774)
I can't tell if you're being sarcastic or not, so I'll give you the benefit of the doubt.
Yes I mean in the browser. The convolution (edge-detection) is definitely possible in WebGL, and the dynamic programming algorithm probably is, so you could probably get sufficient performance in the browser to do this on multiple images in real time.
Somewhat related, I came across an interesting method to resize images called "seam carving". It uses a dynamic programming approach to remove rows or columns that seem uninteresting. The end result is that the important parts of the image are retained when the image is resized. The wikipedia page is fairly good: http://en.wikipedia.org/wiki/Seam_carving There are nice demos on Youtube as well: http://www.youtube.com/watch?v=6NcIJXTlugc Now imagine doing this on the front-end (might be possible now in real-time) and the layouts this would allow!