Androidphan, Thanks,
Also, i am using kernel version 2.6.29 and using v4l2, now-a-days i see of lot of applications seems to be working only if u do preloading of libv4l2convert , otherwise the pixel format or the conversion is not happening, the display screen is black. Whether i need to do anything like that in android. Thanks and Regards, HarishKumar.V 2009/6/26 Androidphan <[email protected]> > > Your input frames for the camera are jpeg? Then you should change > pixel format to V4L2_PIX_FMT_JPEG probably. Also you need to change > the size of the buffers. At the moment they are 2 bytes per pixel: > width * height * 2. > > On Jun 26, 1:03 pm, Harishkumar V <[email protected]> wrote: > > Hi Androidphan, > > > > I have one doubt, i have one logitech QuickCam Connect which supports > jpeg > > as raw pixel format unlike other camera's which support RGB or yuv as raw > > pixel format. > > > > whether i needs to change anything in v4l2-camera.patch to make this work > > with android or it straight forward works. > > > > Because, in ur camera module, u are doing conversion fro yuv to jpeg > during > > saving the picture. i need to modify this. > > > > Thanks and Regards, > > HarishKumar.V > > > > > > > > On Fri, Jun 26, 2009 at 2:52 PM, crazygenie <[email protected]> wrote: > > > > > It's working! Thanks Androidphan :-) > > > > > On Jun 24, 7:04 pm, Ravishankar Haranath <[email protected]> wrote: > > > > Hi Androidphan, > > > > > > Thanks for this great effort. I will re-build with the changes > included > > > and > > > > test it again on my netbook. > > > > > > 2009/6/24 Harishkumar V <[email protected]> > > > > > > > Thats gr8... > > > > > > > As per Atsuo mail, we have working Standard V4l2 HAL Implementation > for > > > > > android on x-86 and ARM-based BB. > > > > > > > Thanks to Androidplan for achieving this milestone. > > > > > > > Thanks and Regards, > > > > > HarishKumar.V > > > > > > > 2009/6/24 Androidphan <[email protected]> > > > > > > >> I got a patch that fixes the permissions for the video device and > the > > > > >> sound device files: > > > > >>http://android-m912.googlecode.com/files/device_permissions.patch > > > > > > >> I knew that already. > > > > > > >> The resolution is a fixed and can only be changed by recompiling > in > > > > >> CameraHardware.cpp. > > > > > > >> It is indeed a standard implementation of v4l2 using mmap. Feel > free > > > > >> to change the code, I'm not going anything more on that code, > because > > > > >> my internship and my Android assignment ends this week :) :( > > > > > > >> On Jun 24, 7:59 am, Atsuo Igarashi <[email protected]> > wrote: > > > > >> > Hi Androidphan, > > > > > > >> > My Beagle(ARM based board) is working camcorder and camera app > with > > > > >> > your v4l2 camera. > > > > > > >> > Points in my environment, > > > > > > >> > 1. change permission of video device. (or change owner?) > > > > > > >> > chmod 666 /dev/video0 > > > > > > >> > 2. free space of 1st dos partition on the SD card is made 4Gbyte > or > > > > >> > less. > > > > > > >> > AuthorDriver and MediaRecorder are failed with max-filesize > error. > > > > > > >> > 3. change resolution to 352x288 in CameraHardware.cpp. > > > > > > >> > Thank you Androidphan! > > > > > > >> > Regards, > > > > >> > Atsuo > > > > > > >> > On 6ζ24ζ₯, εεΎ2:07, Harishkumar V <[email protected]> > wrote: > > > > > > >> > > Hi Androidplan, > > > > > > >> > > My BB got damaged, i do not have hardware for now, it will > come in > > > a > > > > >> week's > > > > >> > > time. > > > > > > >> > > But, ur code looks like standard v4l2 interface using mmap. It > > > should > > > > >> work > > > > >> > > with any normal usb webcam with the resolution alone changing. > > > > > > >> > > Anyway, i test it and confirm u. > > > > > > >> > > Thanks and Regards, > > > > >> > > HarishKumar.V > > > > > > >> > > On Tue, Jun 23, 2009 at 8:01 PM, Androidphan < > > > [email protected]> > > > > >> wrote: > > > > > > >> > > > And does it work for your camera? > > > > > > >> > > > On Jun 23, 3:20 pm, Harishkumar V <[email protected]> > > > wrote: > > > > >> > > > > Hi Androidplan, > > > > > > >> > > > > The libcamera.so and libcameraservice.so got created. > > > > > > >> > > > > In V4l2Camera.cpp, adding this solves the linking problem, > > > > > > >> > > > > extern "C" { > > > > >> > > > > #include "jpeglib.h" > > > > > > >> > > > > } > > > > > > >> > > > > instead of <jpeglib.h> > > > > > > >> > > > > Thanks and Regards, > > > > >> > > > > HarishKumar.V > > > > > > >> > > > > On Tue, Jun 23, 2009 at 6:45 PM, Harishkumar V < > > > > >> [email protected] > > > > >> > > > >wrote: > > > > > > >> > > > > > Hi Androidplan, > > > > > > >> > > > > > I think its problem with the linking of static library > with > > > the > > > > >> > > > android. > > > > > > >> > > > > > but, in the same android source, the skia includes local > > > static > > > > >> > > > libraries > > > > >> > > > > > like jpeg. > > > > > > >> > > > > > Its mystery. > > > > > > >> > > > > > Thanks and Regards, > > > > >> > > > > > HarishKumar.V > > > > > > >> > > > > > On Tue, Jun 23, 2009 at 6:39 PM, Androidphan < > > > > >> [email protected]> > > > > >> > > > wrote: > > > > > > >> > > > > >> It can be found here > > > > >> > > > > >>http://android-m912.googlecode.com/files/Android.mk > > > > > > >> > > > > >> On Jun 23, 2:57 pm, Harishkumar V < > [email protected] > > > > > > >> wrote: > > > > >> > > > > >> > Hi Androidplan, > > > > > > >> > > > > >> > can u send ur Android.mk file. > > > > > > >> > > > > >> > Thanks and Regards, > > > > >> > > > > >> > HarishKumar.V > > > > > > >> > > > > >> > On Tue, Jun 23, 2009 at 6:25 PM, Androidphan < > > > > >> [email protected]> > > > > >> > > > > >> wrote: > > > > > > >> > > > > >> > > Hmm, the Android.mk does says to include the static > > > library > > > > >> > > > libjpeg... > > > > > > >> > > > > >> > > On Jun 23, 2:51 pm, Harishkumar V < > > > [email protected] > > > > > > >> > > > wrote: > > > > >> > > > > >> > > > Hi Androidplan, > > > > > > >> > > > > >> > > > I am able to provide jpeg headers and its > compiling, > > > > >> during > > > > >> > > > linking > > > > >> > > > > >> it > > > > >> > > > > >> > > > reports errors, > > > > > > >> > > > > >> > > > 1) external/jpeg instead of external/jpeg/include > > > solved > > > > >> the > > > > >> > > > jpeg > > > > >> > > > > >> header > > > > >> > > > > >> > > > problem. > > > > >> > > > > >> > > > 2) As recording_callback was not defined and > > > > >> Start_recording was > > > > >> > > > not > > > > >> > > > > >> > > used, > > > > >> > > > > >> > > > it returns only Error, i commented out that part. > > > > > > >> > > > > >> > > > after doing the above things, it compiled, during > > > > >> linking, it > > > > >> > > > > >> reports the > > > > >> > > > > >> > > > following, > > > > > > >> > > > > >> > > > target SharedLib: libcamera > > > > > > (out/target/product/beagle/obj/SHARED_LIBRARIES/libcamera_intermediates/LIN > > > > >> > > > > >> > > KED/libcamera.so) > > > > > > out/target/product/beagle/obj/SHARED_LIBRARIES/libcamera_intermediates/V4L2 > > > > >> > > > > >> > > Camera.o: > > > > >> > > > > >> > > > In function > > > `android::V4L2Camera::saveYUYVtoJPEG(unsigned > > > > >> char*, > > > > >> > > > > >> int, > > > > >> > > > > >> > > int, > > > > >> > > > > >> > > > __sFILE*, int)': > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:320: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to `jpeg_std_error(jpeg_error_mgr*)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:321: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > `jpeg_CreateCompress(jpeg_compress_struct*, > > > > >> int, > > > > >> > > > > >> unsigned > > > > >> > > > > >> > > int)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:322: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > `jpeg_stdio_dest(jpeg_compress_struct*, > > > > >> __sFILE*)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:331: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > `jpeg_set_defaults(jpeg_compress_struct*)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:332: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > `jpeg_set_quality(jpeg_compress_struct*, > > > > >> int, int)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:334: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > `jpeg_start_compress(jpeg_compress_struct*, > > > > >> int)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:368: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > `jpeg_write_scanlines(jpeg_compress_struct*, > > > > >> > > > unsigned > > > > >> > > > > >> > > char**, > > > > >> > > > > >> > > > unsigned int)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:371: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > > >> `jpeg_finish_compress(jpeg_compress_struct*)' > > > > > > >> frameworks/base/camera/libcameraservice/V4L2Camera.cpp:373: > > > > >> > > > > >> undefined > > > > >> > > > > >> > > > reference to > > > > >> `jpeg_destroy_compress(jpeg_compress_struct*)' > > > > >> > > > > >> > > > collect2: ld returned 1 exit status > > > > > > >> > > > > >> > > > Thanks and Regards, > > > > >> > > > > >> > > > HarishKumar.V > > > > > > >> > > > > >> > > > On Tue, Jun 23, 2009 at 6:01 PM, Harishkumar V < > > > > >> > > > > >> [email protected] > > > > >> > > > > >> > > >wrote: > > > > > > >> > > > > >> > > > > Hi Androidplan, > > > > > > >> > > > > >> > > > > I downloaded and during compiling its showing > > > > >> errors,arget > > > > >> > > > thumb > > > > >> > > > > >> C++: > > > > >> > > > > >> > > > > libcamera <= > > > > >> > > > > >> > frameworks/base/camera/libcameraservice/CameraHardware.cpp > > > > >> > > > > >> > > > > In file included from > > > > > > >> frameworks/base/camera/libcameraservice/CameraHardware.cpp:21: > > > > > > >> > > > > frameworks/base/camera/libcameraservice/CameraHardware.h:28:21: > > > > >> > > > > >> error: > > > > >> > > > > >> > > > > jpeglib.h: No such file or directory > > > > >> > > > > >> > > > > In file included from > > > > > > >> frameworks/base/camera/libcameraservice/CameraHardware.cpp:21: > > > > > > >> frameworks/base/camera/libcameraservice/CameraHardware.h:42: > > > > >> > > > > >> error: > > > > >> > > > > >> > > > > 'recording_callback' has not been declared > > > > > > >> > > > > frameworks/base/camera/libcameraservice/CameraHardware.cpp:162: > > > > >> > > > > >> error: > > > > >> > > > > >> > > > > 'android::status_t > > > > >> android::CameraHardware::startRecording' is > > > > >> > > > not > > > > >> > > > > >> a > > > > >> > > > > >> > > static > > > > >> > > > > >> > > > > member of 'class android::CameraHardware' > > > > > > >> > > > > frameworks/base/camera/libcameraservice/CameraHardware.cpp:162: > > > > >> > > > > >> error: > > > > >> > > > > >> > > > > 'recording_callback' was not declared in this > scope... > > > > read more >> > > > --~--~---------~--~----~------------~-------~--~----~ unsubscribe: [email protected] website: http://groups.google.com/group/android-porting -~----------~----~----~----~------~----~------~--~---
