<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Oshie Labs</title>
    <description>The latest articles on DEV Community by Oshie Labs (@oshielabs).</description>
    <link>https://dev.to/oshielabs</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4192014%2Fe41ccb1e-39aa-44b7-8005-1dd85386e913.png</url>
      <title>DEV Community: Oshie Labs</title>
      <link>https://dev.to/oshielabs</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/oshielabs"/>
    <language>en</language>
    <item>
      <title>I got tired of government portals rejecting my 104KB photos, so I built an offline Android app with Compose</title>
      <dc:creator>Oshie Labs</dc:creator>
      <pubDate>Sun, 18 Oct 2026 12:36:19 +0000</pubDate>
      <link>https://dev.to/oshielabs/i-got-tired-of-government-portals-rejecting-my-104kb-photos-so-i-built-an-offline-android-app-with-2gc1</link>
      <guid>https://dev.to/oshielabs/i-got-tired-of-government-portals-rejecting-my-104kb-photos-so-i-built-an-offline-android-app-with-2gc1</guid>
      <description>&lt;p&gt;Last month, a state portal rejected my application because my photo was 104 KB instead of the required 100 KB limit.&lt;/p&gt;

&lt;p&gt;My phone shoots photos at 12 MB. &lt;/p&gt;

&lt;p&gt;When I searched for a quick compressor, every top website asked me to upload my passport photo to their cloud servers. No clear privacy policy, no idea where the images go. &lt;/p&gt;

&lt;p&gt;I wasn't about to hand over my ID to random servers, but existing Play Store apps were either packed with intrusive full-screen ads or relied on vague "low/medium/high" sliders that leave you guessing the output size.&lt;/p&gt;

&lt;p&gt;So I spent the last few weeks building &lt;strong&gt;&lt;a href="https://play.google.com/store/apps/details?id=com.oshielabs.compresse" rel="noopener noreferrer"&gt;Compress-E&lt;/a&gt;&lt;/strong&gt; at &lt;strong&gt;Oshie Labs&lt;/strong&gt;.&lt;/p&gt;




&lt;h3&gt;
  
  
  The problem with hitting exact KB in Android
&lt;/h3&gt;

&lt;p&gt;In Android, &lt;code&gt;Bitmap.compress(JPEG, quality, stream)&lt;/code&gt; takes a quality parameter from 0 to 100. But that's a quantization multiplier, not a file size target.&lt;/p&gt;

&lt;p&gt;Setting &lt;code&gt;quality = 75&lt;/code&gt; on a plain wall might output 40 KB, while on a textured background it could stay at 1.5 MB. &lt;/p&gt;

&lt;p&gt;To hit an &lt;strong&gt;exact target&lt;/strong&gt; like 95 KB without trial and error, Compress-E runs a quick adaptive binary search loop:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;First, it downscales unnecessarily massive canvas resolutions.&lt;/li&gt;
&lt;li&gt;Then, it binary-searches the quality table to converge on the target byte size in 3–4 quick passes.&lt;/li&gt;
&lt;li&gt;Everything runs on background coroutines so the Compose UI stays smooth at 120Hz.&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  100% On-Device &amp;amp; Private
&lt;/h3&gt;

&lt;p&gt;Most tools process images in the cloud because server-side processing is easier than managing mobile memory. &lt;/p&gt;

&lt;p&gt;Compress-E does everything strictly in device RAM:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Zero cloud uploads&lt;/strong&gt;: Works completely offline.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Privacy cleanup&lt;/strong&gt;: Automatically strips EXIF geolocation metadata so your personal coordinates aren't embedded in uploaded photos.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Batch Mode&lt;/strong&gt;: Shrink multiple photos simultaneously with one tap.&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  Tech Stack
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Built 100% with &lt;strong&gt;Jetpack Compose&lt;/strong&gt; &amp;amp; Material 3.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;iTextG &amp;amp; BouncyCastle&lt;/strong&gt; for clean ID/document PDF exports.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AndroidX ExifInterface&lt;/strong&gt; for correct orientation handling.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Check it out on Google Play:&lt;br&gt;&lt;br&gt;
👉 &lt;strong&gt;&lt;a href="https://play.google.com/store/apps/details?id=com.oshielabs.compresse" rel="noopener noreferrer"&gt;Download Compress-E on Google Play&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Would love any feedback on the compression speed and UI!&lt;/p&gt;

</description>
      <category>android</category>
      <category>privacy</category>
      <category>showdev</category>
      <category>kotlin</category>
    </item>
  </channel>
</rss>
