[Ssc-dev] InformaCam Experimental Build 149-DEV
Nathan of Guardian
nathan at guardianproject.info
Fri Sep 26 01:40:51 EDT 2014
Based on comments from Martin today in the scrum, I spent some time
looking at the media import process in the InformaCam app to see how we
might make it more efficient.
First, I discovered that at some point, we try to load the entire full
bitmap of each captured image into memory (in order to generate
thumbnail) which uses up a ton of memory, and cause out of memory
errors. Now, we don't do this, and it reduces memory usage and improves
import speed a great deal.
Second, I changed the detection+import process to work in the background
while photos or videos are being captured. This means that as soon as
you take a photo, it is imported and analyzed and associated with
whatever sensor caches exist at the current time. The sensor cache then
resets (mostly) for the next media capture event, so that you don't have
the huge massive sensor log caches if you are shooting many photos or
videos over an extended period of time.
This also means that, for the most part, when you return to the gallery
view, the captured media has already been processed, and is displayed
there - yay!
Third, I improved the speed of the main file hash logic a bit,
processing the file in 64kb chunks instead of 8kb, and there is a
definite improvement there. We should probably implemented our SHA-1
hashing in C at some point, which would really speed up that step of
code (which takes a few seconds per file now).
FINALLY, there is a new experimental Settings option called "Use
External Camera Mode". This is the ground work for a "Proof Mode"
button. When this is activated, instead of having InformaCam launch a
specific camera when you select the icon from the home screen, it just
turns on the InformaCam service in the background. You can then exit the
app, and use any camera app you want, check emails, make phones calls,
play flappysmurf, take some more videos, etc. When you return to
InformaCam and select "FINISH CAPTURE", then the InformaCam engine will
turn off.
@Martin - happy to talk through this more when you have time. I am going
to do a bunch of testing tomorrow on my bike commute and around the
Harvard campus, using my Moto E.
APK to test (signed with release key, so will install over existing app)
https://guardianproject.info/releases/InformaCam-beta-0.1.49-DEV.apk
--
Nathan of Guardian
nathan at guardianproject.info
More information about the Ssc-dev
mailing list