Nvidia and Robotics w/ Barrett Williams – XDA:DevCon 2014

Robotics continues to dominate our videos from this years XDA:DevCon 2014 in … more

Speed Up Deodexing with JoelDroid Batch Deodexer

Android 5.0 Lollipop brings many under-the-hood changes like changing the default compiler … more

Top 5 Apps for 2014 + Top Xposed Mod of 2014 – XDA TV

Its that time of year where you look back and remember the things that happened … more

NVIDIA SHIELD Tablet Gets Android 5.0.1, OTA Available

The NVIDIA SHIELD Tablet is the latest Android-powered device released by famed GPU … more

Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

Images too compressed?

OP slickdealers

5th July 2014, 04:31 AM   |  #11  
fergie716's Avatar
Senior Member
Flag Buffalo, NY
Thanks Meter: 3,719
 
3,985 posts
Join Date:Joined: May 2011
More
I think I found a fix for this (maybe). If you decompile SecMms_Blue.apk and look @ the mms_config.xml these lines are there (stock)

Code:
<int name="maxMessageSize">307200</int>
    <int name="mmsHeaderSize">5120</int>
    <int name="maxImageHeight">480</int>
    <int name="maxImageWidth">640</int>
Maybe increasing the values would result in less compression?

---------- Post added at 10:31 PM ---------- Previous post was at 10:01 PM ----------

Quote:
Originally Posted by fergie716

I think I found a fix for this (maybe). If you decompile SecMms_Blue.apk and look @ the mms_config.xml these lines are there (stock)

Code:
<int name="maxMessageSize">307200</int>
    <int name="mmsHeaderSize">5120</int>
    <int name="maxImageHeight">480</int>
    <int name="maxImageWidth">640</int>
Maybe increasing the values would result in less compression?

I made an apk and tried this, didn't work. Did unlock a few settings I found in that xml though


EDIT AGAIN

- I found this line in the customer.xml in csc/SPR/system/csc

Code:
 <MessageSize>1m</MessageSize>
          <ImageResizeResolution>uxga</ImageResizeResolution>
Ill see if editing this, along with the mms_config edits add up to anything
Last edited by fergie716; 5th July 2014 at 04:51 AM.
The Following User Says Thank You to fergie716 For This Useful Post: [ View ]
5th July 2014, 03:24 PM   |  #12  
Senior Member
Thanks Meter: 41
 
157 posts
Join Date:Joined: Dec 2010
Quote:
Originally Posted by fergie716

I think I found a fix for this (maybe). If you decompile SecMms_Blue.apk and look @ the mms_config.xml these lines are there (stock)

Code:
<int name="maxMessageSize">307200</int>
    <int name="mmsHeaderSize">5120</int>
    <int name="maxImageHeight">480</int>
    <int name="maxImageWidth">640</int>
Maybe increasing the values would result in less compression?

---------- Post added at 10:31 PM ---------- Previous post was at 10:01 PM ----------


I made an apk and tried this, didn't work. Did unlock a few settings I found in that xml though


EDIT AGAIN

- I found this line in the customer.xml in csc/SPR/system/csc

Code:
 <MessageSize>1m</MessageSize>
          <ImageResizeResolution>uxga</ImageResizeResolution>
Ill see if editing this, along with the mms_config edits add up to anything

Odd, those first things you found are what I would expect to be the issue.

When you changed them and tested I take it you rebooted and tested it with a different MMS image?
I noticed if I send an MMS and go to send the same one again it seems to re-use the compressed version it made the first time, maybe try testing again with a different image to make sure?

Hopefully someone figures it out. I actually don't mind the stock app beyond this annoyance.
Thanks for looking/trying though.
5th July 2014, 11:44 PM   |  #13  
fergie716's Avatar
Senior Member
Flag Buffalo, NY
Thanks Meter: 3,719
 
3,985 posts
Join Date:Joined: May 2011
More
Quote:
Originally Posted by bryanu

Odd, those first things you found are what I would expect to be the issue.

When you changed them and tested I take it you rebooted and tested it with a different MMS image?
I noticed if I send an MMS and go to send the same one again it seems to re-use the compressed version it made the first time, maybe try testing again with a different image to make sure?

Hopefully someone figures it out. I actually don't mind the stock app beyond this annoyance.
Thanks for looking/trying though.

I've tried multiple things including some smali edits but I'm on stock odex. If you're on a deodexed system upload your SecMms_Blue.apk from /system/priv-app/ and I'll make the same edits for you to see if they stick
7th July 2014, 07:43 AM   |  #14  
Member
Flag Minnesota
Thanks Meter: 25
 
66 posts
Join Date:Joined: Feb 2010
More
I also decompiled the messaging app and made some changes like upping the max size to 2mb (2097152 bytes) and the height and width the same as 2.4 mp. I sent myself a picture that was ~700 kb and the resolution was 2.4 mp and the app still scaled it way down to something like 1600 X 900 I also made the CSC edits in customer.xml.
9th July 2014, 11:08 PM   |  #15  
vinman12's Avatar
Recognized Themer
Thanks Meter: 1,566
 
2,135 posts
Join Date:Joined: Dec 2011
Donate to Me
More
in the past the edits that fixed this was in the ImageModel.smali

search for this line

# direct methods
.method static constructor <clinit>()V

in here is where the goods are
The Following 2 Users Say Thank You to vinman12 For This Useful Post: [ View ]
11th July 2014, 07:30 AM   |  #16  
Member
Flag Minnesota
Thanks Meter: 25
 
66 posts
Join Date:Joined: Feb 2010
More
Quote:
Originally Posted by vinman12

in the past the edits that fixed this was in the ImageModel.smali

search for this line

# direct methods
.method static constructor <clinit>()V

in here is where the goods are

Ok I found this line in ImageModel.smali. I know nothing about editing smali and I'm not sure what I'm looking for This is copied directly from Notepad++

# direct methods
.method static constructor <clinit>()V
.locals 2

const/high16 v0, 0x434b0000

invoke-static {v0}, Lcom/android/mms/util/UIUtils;->dp2Pixels(F)I

move-result v0

sput v0, Lcom/android/mms/model/ImageModel;->THUMBNAIL_BOUNDS_LIMIT:I

invoke-static {}, Lcom/android/mms/ui/MessageUtils;->getScreenHeight()I

move-result v0

invoke-static {}, Lcom/android/mms/ui/MessageUtils;->getScreenWidth()I

move-result v1

if-le v0, v1, :cond_0

invoke-static {}, Lcom/android/mms/ui/MessageUtils;->getScreenWidth()I

move-result v0

mul-int/lit8 v0, v0, 0x2

:goto_0
sput v0, Lcom/android/mms/model/ImageModel;->SLIDESHOW_BOUNDS_LIMIT:I

invoke-static {}, Lcom/android/mms/MmsApp;->getApplication()Lcom/android/mms/MmsApp;

move-result-object v0

invoke-virtual {v0}, Landroid/content/ContextWrapper;->getResources()Landroid/content/res/Resources;

move-result-object v0

const v1, 0x7f0a004b

invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDimension(I)F

move-result v0

float-to-int v0, v0

sput v0, Lcom/android/mms/model/ImageModel;->THUMBNAIL_MAX_SHORT:I

invoke-static {}, Lcom/android/mms/MmsApp;->getApplication()Lcom/android/mms/MmsApp;

move-result-object v0

invoke-virtual {v0}, Landroid/content/ContextWrapper;->getResources()Landroid/content/res/Resources;

move-result-object v0

const v1, 0x7f0a004c

invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getDimension(I)F

move-result v0

float-to-int v0, v0

sput v0, Lcom/android/mms/model/ImageModel;->THUMBNAIL_MAX_LONG:I

return-void

:cond_0
invoke-static {}, Lcom/android/mms/ui/MessageUtils;->getScreenHeight()I

move-result v0

mul-int/lit8 v0, v0, 0x2

goto :goto_0
.end method
13th July 2014, 05:04 PM   |  #17  
slickdealers's Avatar
OP Senior Member
Thanks Meter: 26
 
114 posts
Join Date:Joined: Nov 2012
Any progress update? 8sms is still compressing the images like the stock messaging app.
20th July 2014, 08:24 AM   |  #18  
Senior Member
Thanks Meter: 9
 
236 posts
Join Date:Joined: Dec 2009
More
Ditto - can someone most a modded SecMMS_Blue.APK for NE5 ?

Would like to get the max MMS size bumped up to 5 or 10 MB

From browsing Sprint forums - sending MMS to Sprint phones has no limit max but most other carriers have a 1-2mb limit for MMS

I tried decompiling and editing, couldn't get it to work

tried decompressing and editing, then re-compressing the apk - apk kept force-closing

I'm probably missing something basic but can't figure out what it is.
20th July 2014, 09:07 PM   |  #19  
Member
Flag Minnesota
Thanks Meter: 25
 
66 posts
Join Date:Joined: Feb 2010
More
Quote:
Originally Posted by Does_It_Matter

Ditto - can someone most a modded SecMMS_Blue.APK for NE5 ?

Would like to get the max MMS size bumped up to 5 or 10 MB

From browsing Sprint forums - sending MMS to Sprint phones has no limit max but most other carriers have a 1-2mb limit for MMS

I tried decompiling and editing, couldn't get it to work

tried decompressing and editing, then re-compressing the apk - apk kept force-closing

I'm probably missing something basic but can't figure out what it is.

Did you zipalign the apk ? Sac23 posted a modded SecMms_Blue in the MOAR thread.

Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes