pianyu / 0xdroid

Automatically exported from code.google.com/p/0xdroid
0 stars 0 forks source link

How to porting the usb camera with jpg stream #159

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi All,
    I had modify the camera hal for camera with zc301 chip .The camera'output format is jpg. So I 'm confused about how to decompress the jpeg stream for preview in camera application.

Thanks!

Original issue reported on code.google.com by wuyiz...@gmail.com on 21 Dec 2010 at 8:43

GoogleCodeExporter commented 9 years ago
Hi All,
     I had portinged the camera HAL for camera with zc301 chip ,Now it's support picture ,preview ,but when it starts record ,the application crash. Logcat is :
I/ActivityManager(  900): Displayed activity com.android.camera/.VideoCamera: 
2927 ms (total 2927 ms)
V/videocamera( 1186): initializeRecorder
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraHardware( 1178): mCamera->convert is called
E/audio_input( 1178): unsupported parameter: 
x-pvmf/media-input-node/cap-config-interface;valtype=key_specific_value
D/CameraService( 1178): Client::connect E (pid 1178, client 0x5983c)
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraService( 1178): Connect to the new client (pid 1178, client 0x5983c)
E/CameraInput( 1178): Unsupported 
parameter(x-pvmf/media-input-node/cap-config-interface;valtype=key_specific_valu
e)
D/CameraHardware( 1178): mCamera->convert is called
E/CameraInput( 1178): VerifiyAndSetParameter failed on parameter #0
V/videocamera( 1186): Current camera video filename: 
/sdcard/DCIM/Camera/video-2000-01-01-00-04-14.3gp
D/AuthorDriver( 1178): setParamVideoEncodingBitrate() 360000
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraHardware( 1178): mCamera->convert is called
W/AuthorDriver( 1178): Use default video fps range [5 20]
W/AuthorDriver( 1178): Use default video width range [176 352]
W/AuthorDriver( 1178): Use default video height range [144 288]
W/AuthorDriver( 1178): Use default video bps range [192000 420000]
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraHardware( 1178): mCamera->convert is called
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraHardware( 1178): mCamera->convert is called
E/SurfaceFlinger(  900): LayerBuffer::BufferSource::postBuffer() invalid buffer 
(offset=0, size=202752, heap-size=155648
D/CameraHardware( 1178): mCamera->convert is called
[  268.334259] binder: release 1178:1183 transaction 6941 in, still active
[  268.340972] binder: send failed reply for transaction 6941 to 1186:1186
W/AudioSystem( 1186): AudioFlinger server died!
W/Camera  ( 1186): Camera server died!
W/AudioSystem( 1186): AudioPolicyService server died!
W/Camera  ( 1186): ICamera died
W/AudioSystem(  900): AudioFlinger server died!
W/AudioSystem(  900): AudioPolicyService server died!
I/ServiceManager(  880): service 'media.audio_flinger' died
I/ServiceManager(  880): service 'media.player' died
I/ServiceManager(  880): service 'media.camera' died
I/ServiceManager(  880): service 'media.audio_policy' died
I/MediaRecorderJNI( 1186): prepare: surface=0x2bea50 (id=3)
E/Camera  ( 1186): Error 100
V/camera  ( 1186): media server died
I/        ( 1202): ServiceManager: 0xad08
W/AudioHardwareALSA( 1202): Unable to attach mixer to device AndroidOut: 
Invalid argument
W/AudioHardwareALSA( 1202): Unable to attach mixer to device AndroidIn: Invalid 
argument
I/CameraService( 1202): CameraService started: pid=1202

I have no idea about it ,anybody could give me some advices?

Original comment by wuyiz...@gmail.com on 30 Dec 2010 at 2:09

GoogleCodeExporter commented 9 years ago
Could you attach your patch?  Instead, you can consider to discuss in 
mailing-list: http://groups.google.com/group/0xlab-devel

Original comment by jserv.tw@gmail.com on 5 Jan 2011 at 2:05

GoogleCodeExporter commented 9 years ago
ok, but  may I attach my patch on issue 159 or anywhere?

Original comment by wuyiz...@gmail.com on 5 Jan 2011 at 4:40

GoogleCodeExporter commented 9 years ago
Hi All ,my patch can be check in attachement. Now ,I found two problem . 
1 ,Maybe I did't transform the rgb16 bit to yuv420sp .
2 ,The audio flinger died .Maybe the auido did't work for camera video mode?

Original comment by wuyiz...@gmail.com on 5 Jan 2011 at 4:58

Attachments:

GoogleCodeExporter commented 9 years ago
anybody could give me some advices?

Original comment by wuyiz...@gmail.com on 5 Jan 2011 at 5:00

GoogleCodeExporter commented 9 years ago
camera HAL modify for android 2.3  
develop from 0xdroid camera hardware.

Original comment by greatma...@gmail.com on 2 Feb 2011 at 11:30

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by jserv.tw@gmail.com on 2 Feb 2011 at 5:28