[ICS Roms] Image compression

billobob

Senior Member
Apr 2, 2009
76
2
0
Is there any way to make the Sense ICS camera compress images less? None of my images ever seem to top 2MB, even if they're taken in broad daylight in a setting with lots of different colors. Fiddling around with build.prop does nothing
 

Zico 10

Senior Member
Feb 27, 2010
249
79
48
It's for both video and still pics.

Either way, be careful with it because I have been playing around with it and have managed to make the camera freeze upon taking a shot.

FYI, these changes used to be enough to remove image processing, at least in my experience on Gingerbread ROMs. However it doesn't seem to work for me now on ICS (though feel free to test and report your findings).

1 - changing this,

<!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED>

to

<!ATTLIST ImageEncoding quality (100|80|70|60|50|40) #REQUIRED>

(or just adding 100 in front of 90, either way).

2 - changing these lines (which appear twice),

<ImageEncoding quality="90" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />

<ImageDecoding memCap="20000000" />

to

<ImageEncoding quality="100" />
<ImageEncoding quality="100" />
<ImageEncoding quality="100" />

<ImageDecoding memCap="500000000" />
 
Last edited:

tibere86

Senior Member
Feb 14, 2009
1,425
272
0
Rockville, MD
It's for both video and still pics.

Either way, be careful with it because I have been playing around with it and have managed to make the camera freeze upon taking a shot.

FYI, these changes used to be enough to remove image processing, at least in my experience on Gingerbread ROMs. However it doesn't seem to work for me now on ICS (though feel free to test and report your findings).

1 - changing this,

<!ATTLIST ImageEncoding quality (90|80|70|60|50|40) #REQUIRED>

to

<!ATTLIST ImageEncoding quality (100|80|70|60|50|40) #REQUIRED>

(or just adding 100 in front of 90, either way).

2 - changing these lines (which appear twice),

<ImageEncoding quality="90" />
<ImageEncoding quality="80" />
<ImageEncoding quality="70" />

<ImageDecoding memCap="500000000" />

to

<ImageEncoding quality="100" />
<ImageEncoding quality="100" />
<ImageEncoding quality="100" />

<ImageDecoding memCap="500000000" />
Worked! Many thanks! I had been struggling with this issue all weekend.
 

Zico 10

Senior Member
Feb 27, 2010
249
79
48
Worked! Many thanks! I had been struggling with this issue all weekend.
Which ROM are you running?

I tried on the Ultimite ICS ROM and it caused the camera to crash. I will try on Virtuous Inquisition soon.

How about uploading the files you changed?
Come on, it's a matter of editing ONE file for a total of 9 small changes, it's not going to take much longer to make the changes yourself than it is to download the file, make a back-up of the original, move it in place of the original and set file permissions.
 

Zico 10

Senior Member
Feb 27, 2010
249
79
48
Just tried with Virtuous, no good.

Some indoor, low light shots work but when taking outdoor shots it crashes the camera.
 

AleyKsi

Senior Member
Dec 31, 2011
54
14
0
Strasbourg
I made the changes but with 99 as max quality.
Doesn't seem to crash but the image quality isn't as good as i used to have with the AmazeCamera mod
Will continy to experiment
 

billobob

Senior Member
Apr 2, 2009
76
2
0
I made the changes but with 99 as max quality.
Doesn't seem to crash but the image quality isn't as good as i used to have with the AmazeCamera mod
Will continy to experiment
I tried this and while there's an improvement, it still isn't as good as the mod I had on gingerbread

setting it to 99 also makes it still periodically crash for me, but I can get some pictures off
 

krogoth

Senior Member
Jun 9, 2008
661
84
58
Warsaw
95 seems to be stable... Still experimenting.

I've also decompiled HTCCamera.apk and tried to increase bitrate, but with no succes.
I've changed bitrate under 0x780 to 18mb. As result camera is recording at 14mbps but there is no video when I'm trying to play it.

Anyone with some camera modding exp?
 

zerozoneice

Senior Member
Dec 18, 2010
1,846
223
0
I've changed bitrate under 0x780 to 18mb. As result camera is recording at 14mbps but there is no video when I'm trying to play it.

Anyone with some camera modding exp?
try contacting cdtdroid or baadnews, they pulled out the amaze camera mod with improved bitrates. maybe contacting a kernel dev would help too, dunno if they can do much w/o the leaked kernel source but it's worth a try