twrock, on 26 January 2012 - 04:05 AM, said:
Are you saying that you tested the modifications you made to the libcamera.so and camera.so files in the TXG rom and it solved the camera issues we have been having with all the CM6.1 based roms?
Not exactly. I was trying to figure out if my wrapper crashes in any environment. So I tried it in eclair which is the most native environment for our camera libs. If it would crash there, it could only be the wrapper because any other things were completely stock. But it didn't crash. So I tried going the way from eclair to gingerbread. Regarding the camera environment, the way is
eclair -> cm6 (all Tom G based roms with partially working camera) -> real froyo -> gingerbread
With regard to camera, your CM6 is not froyo but eclair. That's because it was compiled to act like eclair in certain aspects (libs, heap management; that's the reason these roms do not have libcamera_client and libsurfaceflinger_client by default). Real froyo would be a (CM6) rom compiled without said "eclair emulator" option.
Using the wrapper on eclair or CM6 (Tom G based) does not make sense. It is like having someone translate english into english. I just did that to see if the wrapper passes all function calls correctly (i.e, if it can read and write english if you want). It does. But in that environments, it cannot be expected to modify any functionality. Most likely, taking pictures with your rom just worked because I left the modified camera app untouched.
twrock, on 26 January 2012 - 04:05 AM, said:
Edit: Apparently I really do not understand. I pulled those two files out of the CM7.2 rom Pier uploaded and put them into TXG. (And I replaced the Camera.apk with the original from TomG's port.) The resulting rom build hangs on boot. So any help you can give would be appreciated.
That is expected behaviour. Because the wrapper files you extracted are those that expect a real froyo environment. One could say the wrapper is built to translate english into french. For the wrapper to work with your rom, you need to modify camera.so (to let it translate into english instead of french). You can easily do this yourself. Get a hex editor, search for the string libcamera_client.so inside camera.so. Then overwrite 'libcamer' with 'libui.so' at the beginning of that string, and after 'libui.so' you have to add a zero (not '0' on keyboard, but a 0x00 hexadecimal, to terminate the string. Then you get the modified wrapper - but as I already said - I don't expect that to fix any issues.
By the way - without anegins camera app - how many 3MP pictures do I need to take in order to reproduce the crashing bug? Is this like 3 pics or like 30+?
Edited by dr.flo, 26 January 2012 - 08:16 AM.