[Ssc-dev] ObscuraCam 1.1-FINAL
Andrew Senior
andrew.senior at gmail.com
Fri Sep 23 02:48:54 EDT 2011
Hi Nathan,
Sorry I didn't find time to work on the grey/black issue.
This should fix it. I've not tested it extensively. I haven't got my git
properly set up on this laptop, so I'm sending the one line fix here:
--- a/lib/jpeg_decoder.cpp
+++ b/lib/jpeg_decoder.cpp
@@ -309,11 +309,12 @@ int JpegDecoder::DecodeOneBlock(int dht, int comp, int
redacting) {
// Default is the cumulative sum so far.
int value_to_write = dc_values_[comp];
// If solid, we write out 0.
if ( redacting != kRedactingEnding) {
if (redaction_method_ == Redaction::redact_solid)
- value_to_write = 0;
+ // Write black.
+ value_to_write = (comp == 0) ? (-127 * (1 << dct_gain_)) : 0;
else if (redaction_method_ == Redaction::redact_copystrip)
value_to_write = redaction_dc_[comp];
else if (redaction_method_ == Redaction::redact_pixellate ||
redaction_method_ == Redaction::redact_inverse_pixellate)
value_to_write = LookupPixellationValue(comp);
To do other colours, we would write out non-zero values when comp!=0, and
the intensity would need to be some other value.
This did bright green:
value_to_write = (comp == 0) ? (0 * (1 << dct_gain_)) : ((comp==1) ? -511 :
-511);
I'm not sure of the exact scaling that needs to be applied.
http://www.impulseadventure.com/photo/jpeg-color-space.html
Cb= (B-Y)/(2-2*0.114)
Cr=(R-Y)/(2-2*0.299)
On Tue, Sep 20, 2011 at 10:26 PM, Nathan of Guardian <
nathan at guardianproject.info> wrote:
> Ahem, actually this:
>
>
> https://github.com/guardianproject/SecureSmartCam/ObscuraCam-1.1.1-FINAL.apk/qr_code
>
> /me forgot to refresh his code from the file system when he did the build.
>
> On 09/21/2011 12:56 AM, Nathan of Guardian wrote:
> > I've built ObscuraCam 1.1-FINAL and update the Android Market and Github.
> >
> > You can download it directly here:
> >
> https://github.com/guardianproject/SecureSmartCam/ObscuraCam-1.1-FINAL.apk/qr_code
> >
> > I decided to NOT include the native/full res processing in this release,
> > because I want to fix the grey/black issue and also solve the thumbnail
> > display issue first. I think I know the solution for both, but just need
> > a few more days.
> >
> > In the meantime, I think the existing fixes we have were worthy enough
> > to push an update. I would like to get more frequent updates out anyhow,
> > so doing a 1.2 next week with the native code back in would be fine.
> >
> > Thanks to all for your contributions in both code and testing. Let me
> > know if you see anything wrong with this latest update.
> >
> > +n
> > _______________________________________________
> > Ssc-dev mailing list
> >
> > Post: Ssc-dev at lists.mayfirst.org
> > List info: https://lists.mayfirst.org/mailman/listinfo/ssc-dev
> >
> > To Unsubscribe
> > Send email to: Ssc-dev-unsubscribe at lists.mayfirst.org
> > Or visit:
> https://lists.mayfirst.org/mailman/options/ssc-dev/nathan%40guardianproject.info
> >
> > You are subscribed as: nathan at guardianproject.info
>
> _______________________________________________
> Ssc-dev mailing list
>
> Post: Ssc-dev at lists.mayfirst.org
> List info: https://lists.mayfirst.org/mailman/listinfo/ssc-dev
>
> To Unsubscribe
> Send email to: Ssc-dev-unsubscribe at lists.mayfirst.org
> Or visit:
> https://lists.mayfirst.org/mailman/options/ssc-dev/andrew.senior%40gmail.com
>
> You are subscribed as: andrew.senior at gmail.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mayfirst.org/pipermail/ssc-dev/attachments/20110922/cbec025b/attachment.htm>
More information about the Ssc-dev
mailing list