Streamline Android Theme Customization with Graphic Porter

I dont have a custom theme on my Android phone, and the reason for this is because … more

Boost the Brightness of Your Sony Xperia Z1’s LED

I think the last time anyone has ever used a physical torch to find their earphones, … more

XDA Xposed Tuesday: Modify the Look of Your Volume Control – XDA TV

How many screenshots have you seen with a volume status bar in the … more

Prepare Your Nokia X2 for Battle with Nokia X2 Tools

Unveiled in June this year, the Nokia X2 is the Finnish companys second crack at an … more
Post Reply

[WIP] - JB Camera HAL for 2.6 kernel

23rd August 2012, 11:02 PM   |  #1  
Rashed97's Avatar
OP Recognized Contributor / Recognized Developer
Thanks Meter: 9,036
 
1,476 posts
Join Date:Joined: May 2012
Donate to Me
More
Hello everyone!!!
This is a continuation of rapmv78's ICS Camera HAL for 2.6 kernel. Great thanks to nobodyAtall who helped get this working

THINGS YOU WILL NEED:
A working ICS ROM for your device
A lot of time

Now this can be adapted to any phone, but it is designed for the LG Optimus One (P500)
I will upload the panorama fix to my GitHub as soon as I finish porting the code for it

SOURCES:
https://github.com/androidarmv6/andr...vice_libcamera
Camera app changes coming soon!
Frameworks changes coming soon!

TO FIX VIDEO RECORDING AND PLAYBACK:
To fix video you will need the lib/libstagefright_soft_aacdec.so file from your ICS ROM. Setup a vendor pregenerated lib by adding that .so to your COMMONFOLDERNAME/proprietary/lib/libstagefright_soft_aacdec.so

TO INSTALL:
1. Follow the instructions in the READMEs in the repos
2. In your BoardConfigCommon.mk, delete the following lines IF THEY EXIST:
(Note: these are scattered all over the file, so look for them)
  • COMMON_GLOBAL_CFLAGS += -DICS_CAMERA_BLOB
  • TARGET_USE_OVERLAY := false
  • TARGET_HAVE_BYPASS := false
  • TARGET_USES_C2D_COMPOSITION := false
  • COMMON_GLOBAL_CFLAGS += -DREFRESH_RATE=60
3. Now add these lines to your BoardConfigCommon.mk
  • TARGET_DISABLE_ARM_PIE := true
  • TARGET_BOOTANIMATION_USE_RGB565 := true
  • TARGET_BOOTANIMATION_TEXTURE_CACHE := true
  • Note that the following 2 might not be needed based on your device, but most devices will need them
  • TARGET_NO_HW_VSYNC := true
  • COMMON_GLOBAL_CFLAGS += -DQCOM_NO_SECURE_PLAYBACK
4. Edit the files in the DEVICE/libcamera folder to suit your device

Again, thanks to nobodyAtall for getting this to work!!!
Last edited by Rashed97; 26th August 2012 at 07:45 PM.
The Following 22 Users Say Thank You to Rashed97 For This Useful Post: [ View ]
23rd August 2012, 11:14 PM   |  #2  
stelios97's Avatar
Recognized Developer
Flag Famagusta
Thanks Meter: 4,387
 
1,462 posts
Join Date:Joined: Feb 2011
Donate to Me
More
are you sure that this line need to be removed?
COMMON_GLOBAL_CFLAGS += -DREFRESH_RATE=60
23rd August 2012, 11:37 PM   |  #3  
Rashed97's Avatar
OP Recognized Contributor / Recognized Developer
Thanks Meter: 9,036
 
1,476 posts
Join Date:Joined: May 2012
Donate to Me
More
Yes
Or else you get weird issues with the screen
24th August 2012, 04:59 AM   |  #4  
a2441918's Avatar
Recognized Contributor
Flag New York
Thanks Meter: 3,434
 
1,437 posts
Join Date:Joined: Jan 2011
Donate to Me
More
How to do this "Setup a vendor pregenerated lib by adding that .so to your COMMONFOLDERNAME/proprietary/lib/libstagefright_soft_aacdec.so"??

I have an x10 and camera works but with small grey bar at the bottom in 8 Mpx but 6MPx works fine.. No video recording nd panaroma..
25th August 2012, 01:54 AM   |  #5  
Senior Member
Thanks Meter: 55
 
214 posts
Join Date:Joined: Aug 2012
Quote:
Originally Posted by Rashed97

Hello everyone!!!
This is a continuation of rapmv78's ICS Camera HAL for 2.6 kernel. Great thanks to nobodyAtall who helped get this working

THINGS YOU WILL NEED:
A working ICS ROM for your device
A lot of time

Now this can be adapted to any phone, but it is designed for the LG Optimus One (P500)
I will upload the panorama fix to my GitHub as soon as I finish porting the code for it

SOURCES:
https://github.com/Rashed97/android_device_libcamera
Camera app changes coming soon!
Frameworks changes coming soon!

TO FIX VIDEO RECORDING AND PLAYBACK:
To fix video you will need the lib/libstagefright_soft_aacdec.so file from your ICS ROM. Setup a vendor pregenerated lib by adding that .so to your COMMONFOLDERNAME/proprietary/lib/libstagefright_soft_aacdec.so

TO INSTALL:
1. Follow the instructions in the READMEs in the repos
2. In your BoardConfigCommon.mk, delete the following lines IF THEY EXIST:
(Note: these are scattered all over the file, so look for them)

  • COMMON_GLOBAL_CFLAGS += -DICS_CAMERA_BLOB
  • TARGET_USE_OVERLAY := false
  • TARGET_HAVE_BYPASS := false
  • TARGET_USES_C2D_COMPOSITION := false
  • COMMON_GLOBAL_CFLAGS += -DREFRESH_RATE=60
3. Now add these lines to your BoardConfigCommon.mk
  • TARGET_DISABLE_ARM_PIE := true
  • TARGET_BOOTANIMATION_USE_RGB565 := true
  • TARGET_BOOTANIMATION_TEXTURE_CACHE := true
  • Note that the following 2 might not be needed based on your device, but most devices will need them
  • TARGET_NO_HW_VSYNC := true
  • COMMON_GLOBAL_CFLAGS += -DQCOM_NO_SECURE_PLAYBACK
4. Edit the files in the DEVICE/libcamera folder to suit your device

Again, thanks to nobodyAtall for getting this to work!!!

Read me only shows this message "This directory contains code for the Jelly Bean Camera HAL"
BTW where do we replace the files ? Where does BoardConfigCommon.mk file exist ?
Last edited by pluGinSz; 25th August 2012 at 02:08 AM.
25th August 2012, 03:51 AM   |  #6  
Rashed97's Avatar
OP Recognized Contributor / Recognized Developer
Thanks Meter: 9,036
 
1,476 posts
Join Date:Joined: May 2012
Donate to Me
More
Put the file in the /vendor/MANUFACTURER/DEVICE/proprietary/lib/
Add this line to your vendor-DEVICE-blobs.mk: (Note: Make sure it's the second to last line, not the last line)
vendor/COMPANY/DEVICE/proprietary/lib/libstagefright_soft_aacdec.so:system/lib/libstagefright_soft_aacdec.so \

Also here is an example of a common repo where you need to make all these changes:
https://github.com/lgics/cm_device_lge_msm7x27-common

And the vendor for the video:
https://github.com/lgics/cm_vendor_lge
The Following 2 Users Say Thank You to Rashed97 For This Useful Post: [ View ]
26th August 2012, 07:46 PM   |  #7  
Rashed97's Avatar
OP Recognized Contributor / Recognized Developer
Thanks Meter: 9,036
 
1,476 posts
Join Date:Joined: May 2012
Donate to Me
More
http://review.cyanogenmod.com/#/c/22147/
This should fix recording issues
I just added it to all of CM since its needed a lot
The Following 3 Users Say Thank You to Rashed97 For This Useful Post: [ View ]
29th August 2012, 03:22 PM   |  #8  
Senior Member
Thanks Meter: 55
 
214 posts
Join Date:Joined: Aug 2012
Quote:
Originally Posted by Rashed97

http://review.cyanogenmod.com/#/c/22147/
This should fix recording issues
I just added it to all of CM since its needed a lot

I use Xperia Ray running CM10 by FXP with FXP kernel. Should it work on it ? I can't find any file with extension .mk
30th August 2012, 08:17 AM   |  #9  
asdfzz's Avatar
Senior Member
Thanks Meter: 1,590
 
1,235 posts
Join Date:Joined: Mar 2012
Donate to Me
take credit to erikcas for vide LQ

For camera on LG p690/e510 it doesnt work..we cant take picts... pano works :s
31st August 2012, 09:27 PM   |  #10  
Crenshaw-PCGH's Avatar
Senior Member
Thanks Meter: 156
 
327 posts
Join Date:Joined: Mar 2012
How to open the readme??

I get just " This directory contains code for the Jelly Bean Camera HAL"

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

Advanced Search
Display Modes


Top Threads in Android Software and Hacking General [Developers Only] by ThreadRank