Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • THX ALOT LastCoder. Never thought about assigning more data per loop at once, that IS the key to performance here. Its running 3 fps faster now. I readded the Sqrt method because it gives me the nice Sobel Effect. It's also on wikipedia. I don't know how else I can recreate the sobel effect without using the Sqrt function Commented Dec 15, 2011 at 18:17
  • @user1083398 - try a fast java integer only square root implementation, you may find it to be ~3x faster than Math.sqrt. You might also want to consider multi-threading if your hardware supports multiple cores you could run the loop on two threads each processing half of the image. Commented Dec 15, 2011 at 19:50
  • "If you are using your algorithm in real-time, call it less often, maybe every ~20 frames instead of every frame." Wouldn't I be getting 20 frames the same image then if I only decode once every 20 frames? Commented Dec 15, 2011 at 22:29
  • @user1083398 - I was thinking you could use the edge finding image as an overlay on top of the real image, and you'd only update that overlay every ~20 frames. Since I don't know exactly what your doing I can only speak hypothetically... Commented Dec 16, 2011 at 17:37