我的拍照代码挂在 takePicture 上。该代码在运行 Android 2.2 或 4.0 的设备上运行良好。它不能在运行 2.3 的华为上运行。目前我不确定是设备还是 API。我怀疑该设备,但发现这很奇怪,因为系统相机应用程序可以正常工作。这是我在执行 takePicture 方法时记录的 LogCat 条目。有没有人能够在其中发现一些可能给出提示的东西?
01-10 13:09:42.589: I/QualcommCameraHardware(113): Found a matching camera info for ID 0
01-10 13:09:42.589: I/QualcommCameraHardware(113): HAL_getCameraInfo: orientation = 90
01-10 13:09:42.589: I/QualcommCameraHardware(113): HAL_getCameraInfo: modes supported = 5
01-10 13:09:42.599: I/QualcommCameraHardware(113): openCameraHardware: call createInstance
01-10 13:09:42.599: I/QualcommCameraHardware(113): openCameraHardware:Valid camera ID 0
01-10 13:09:42.599: I/QualcommCameraHardware(113): openCameraHardware:camera mode 1
01-10 13:09:42.599: I/QualcommCameraHardware(113): HAL_openCameraHardware: HAL_currentSnapshotMode = 4
01-10 13:09:42.599: I/QualcommCameraHardware(113): createInstance: E
01-10 13:09:42.599: I/QualcommCameraHardware(113): QualcommCameraHardware constructor E
01-10 13:09:42.619: I/QualcommCameraHardware(113): createInstance: created hardware=0x10a68
01-10 13:09:42.759: E/CAM_FD(113): sensor_load_chromatix: Sensor name: s5k5ca cnt=3
01-10 13:09:42.759: E/mm-camera(113): s5k5ca_setup_camctrl_tbl:get af supported false!
01-10 13:09:42.769: E/mm-camera(113): camera_query_parms: pict_max_size max_width 2048 max_height 1536
01-10 13:09:42.769: E/QualcommCameraHardware(113): startCamera X: max pic width:2048 height:1536
01-10 13:09:42.769: I/QualcommCameraHardware(113): initDefaultParameters E
01-10 13:09:42.859: I/QualcommCameraHardware(113): AutoFocus is not supported
01-10 13:09:42.859: E/QualcommCameraHardware(113): filterPictureSizes picture_sizes[3].width:2048 picture_sizes[3].height:1536 .
01-10 13:09:42.869: E/QualcommCameraHardware(113): Maximum zoom value is 61
01-10 13:09:42.869: I/QualcommCameraHardware(113): initDefaultParameters: setting num-snaps-per-shutter to 1
01-10 13:09:42.869: I/QualcommCameraHardware(113): setRecordSize: preview dimensions: 640x480
01-10 13:09:42.869: I/QualcommCameraHardware(113): setRecordSize: video dimensions: 640x480
01-10 13:09:42.869: I/QualcommCameraHardware(113): Parameter Rolloff is not supported for this sensor
01-10 13:09:42.869: I/QualcommCameraHardware(113): Parameter MCE is not supported for this sensor
01-10 13:09:42.869: I/QualcommCameraHardware(113): Sharpness not supported for this sensor
01-10 13:09:42.869: I/QualcommCameraHardware(113): Saturation not supported for this sensor
01-10 13:09:42.869: E/QualcommCameraHardware(113): Parameter Scenemode is not supported for this sensor
01-10 13:09:42.869: I/QualcommCameraHardware(113): Contrast not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): Parameter AntiBanding is not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): setRedeyeReduction: setting Redeye Reduction value of disable
01-10 13:09:42.879: E/CAM_FD(113): config_proc_CAMERA_SET_REDEYE_REDUCTION: mode =0
01-10 13:09:42.879: E/CAM_FD(113): config_proc_CAMERA_SET_REDEYE_REDUCTION: FAILED
01-10 13:09:42.879: E/QualcommCameraHardware(113): native_set_parms failed: type 50 length 1 error No such file or directory
01-10 13:09:42.879: E/QualcommCameraHardware(113): Wavelet Denoise is not supported for this sensor
01-10 13:09:42.879: E/QualcommCameraHardware(113): FPS Range Values: 5000x31000
01-10 13:09:42.879: I/QualcommCameraHardware(113): Set fps is not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): set fps mode is not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): Auto Exposure not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): Exposure Compensation is not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): setFlash: flash not supported
01-10 13:09:42.879: I/QualcommCameraHardware(113): Set Brightness not supported for this sensor
01-10 13:09:42.879: E/QualcommCameraHardware(113): Parameter ISO Value is not supported for this sensor
01-10 13:09:42.879: I/QualcommCameraHardware(113): setHighFrameRate: setting HFR value of off(1)
01-10 13:09:42.879: I/QualcommCameraHardware(113): initDefaultParameters X
01-10 13:09:42.879: I/QualcommCameraHardware(113): createInstance: X
01-10 13:09:42.879: I/QualcommCameraHardware(113): Found a matching camera info for ID 0
01-10 13:09:42.879: I/QualcommCameraHardware(113): HAL_getCameraInfo: orientation = 90
01-10 13:09:42.879: I/QualcommCameraHardware(113): HAL_getCameraInfo: modes supported = 5
01-10 13:09:42.879: E/CameraService(113): takePicture return mHardware->takePicture(mSurface)
01-10 13:09:42.879: E/QualcommCameraHardware(113): takePicture(2511)
01-10 13:09:42.879: E/mm-camera(113): PROFILE Camera_interface pre_prepare snap : 1357819782.890308291
01-10 13:09:42.879: E/mm-camera(113): PROFILE Camera_interface post prepare_snap: 1357819782.890339957
01-10 13:09:42.879: I/QualcommCameraHardware(113): stopPreviewInternal E: 0
01-10 13:09:42.879: I/QualcommCameraHardware(113): stopPreviewInternal X: 0
01-10 13:09:42.899: D/MediaPlayer(113): setDataSource(/system/media/audio/ui/camera_click.ogg)
01-10 13:09:42.899: E/QualcommCameraHardware(113): initRaw getPictureSize mPictureWidth:640 mPictureHeight:480
01-10 13:09:42.899: E/mm-camera(113): camera_set_parms CAMERA_PARM_NEED_TO_RESIZE *((bool*)p_value):0
01-10 13:09:42.909: E/mm-camera(113): snapshot_set_need_resize: exit status 0, is_need_resize:0
01-10 13:09:42.909: E/QualcommCameraHardware(113): rawsize = 460800 cbcr offset =307200
01-10 13:09:42.909: V/MediaPlayerService(113): Client(1) constructor
01-10 13:09:42.909: V/MediaPlayerService(113): Create new client(1) from pid 113, url=/system/media/audio/ui/camera_click.ogg, connId=1, audioSessionId=3
01-10 13:09:42.909: D/MediaPlayerService(113): setDataSource(/system/media/audio/ui/camera_click.ogg)
01-10 13:09:42.929: V/MediaPlayerService(113): usePVPlayer: did not detect file to be with LPA implementation
01-10 13:09:42.929: I/MediaPlayerService(113): The Default player that is returned is STAGEFRIGHT**************
01-10 13:09:42.929: V/MediaPlayerService(113): player type = 4
01-10 13:09:42.929: V/MediaPlayerService(113): create StagefrightPlayer
01-10 13:09:42.939: V/AudioSink(113): AudioOutput(3)
01-10 13:09:42.939: V/MediaPlayerService(113): setDataSource
01-10 13:09:42.939: V/MediaPlayerService(113): [1] setAudioStreamType(10)
01-10 13:09:42.939: V/MediaPlayerService(113): [1] prepareAsync
01-10 13:09:42.989: V/MediaPlayerService(113): [1] notify (0x16e78, 5, 0, 0)
01-10 13:09:42.989: V/MediaPlayerService(113): [1] notify (0x16e78, 1, 0, 0)
01-10 13:09:42.989: D/MediaPlayer(113): setDataSource(/system/media/audio/ui/VideoRecord.ogg)
01-10 13:09:42.989: V/MediaPlayerService(113): Client(2) constructor
01-10 13:09:42.989: V/MediaPlayerService(113): Create new client(2) from pid 113, url=/system/media/audio/ui/VideoRecord.ogg, connId=2, audioSessionId=4
01-10 13:09:42.989: D/MediaPlayerService(113): setDataSource(/system/media/audio/ui/VideoRecord.ogg)
01-10 13:09:42.989: V/MediaPlayerService(113): usePVPlayer: did not detect file to be with LPA implementation
01-10 13:09:42.989: I/MediaPlayerService(113): The Default player that is returned is STAGEFRIGHT**************
01-10 13:09:42.989: V/MediaPlayerService(113): player type = 4
01-10 13:09:42.989: V/MediaPlayerService(113): create StagefrightPlayer
01-10 13:09:42.999: V/AudioSink(113): AudioOutput(4)
01-10 13:09:42.999: V/MediaPlayerService(113): setDataSource
01-10 13:09:42.999: V/MediaPlayerService(113): [2] setAudioStreamType(10)
01-10 13:09:42.999: V/MediaPlayerService(113): [2] prepareAsync
01-10 13:09:43.009: V/MediaPlayerService(113): [2] notify (0x254e8, 5, 0, 0)
01-10 13:09:43.009: V/MediaPlayerService(113): [2] notify (0x254e8, 1, 0, 0)
01-10 13:09:48.909: E/CAM_FD(113): ...config thread select timeout...
01-10 13:09:48.969: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=SyncManagerHandleSyncAlarm
01-10 13:09:48.979: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=AlarmManager
01-10 13:09:48.979: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=AlarmManager
01-10 13:09:48.979: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=SyncManagerHandleSyncAlarm
01-10 13:09:54.919: E/CAM_FD(113): ...config thread select timeout...
01-10 13:09:59.999: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=AlarmManager
01-10 13:10:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver onReceive
01-10 13:10:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver actionandroid.intent.action.TIME_TICK
01-10 13:10:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver msg.what=1001
01-10 13:10:00.039: I/WeatherMediumWidgetProvider(732): updateUI(Context context)
01-10 13:10:00.049: D/WeatherMediumWidgetProvider(732): updateUI(Context context, AppWidgetManager widgetManager, int[] appWidgetId)
01-10 13:10:00.059: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:10:00.059: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=AlarmManager
01-10 13:10:00.069: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:10:00.069: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:10:00.069: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:10:00.069: D/WidgetUtils(732): setWeatherUpdateClickListener
01-10 13:10:00.069: D/WidgetUtils(732): setAccuWeatherCickListener
01-10 13:10:00.069: E/WidgetUtils(732): cityCode=cityId:167705
01-10 13:10:00.069: D/WidgetUtils(732): updateWeatherInfo
01-10 13:10:00.069: D/Utils(732): isDataOK
01-10 13:10:00.069: D/Utils(732): dataOverdue
01-10 13:10:00.069: D/WidgetUtils(732): updateWeatherInfo temperature =3.3333333,time1357482579481,weatherDes=Mostly Cloudy,invalidDay=4
01-10 13:10:00.069: D/WidgetUtils(732): updateWeatherInfo weatherDayDataInfo =HighTemperature =3.3333333 LowTemperature =-0.5555556 WeatherIcon =7 TextShort=Cloudy and colder TextLong=Cloudy and colder with a rain and snow shower possible WindSpeed=5 WindDirection=W
01-10 13:10:00.079: D/WidgetUtils(732): updateCityDateTime
01-10 13:10:00.079: D/WidgetUtils(732): getCurCityCalendar
01-10 13:10:00.079: D/WidgetUtils(732): builder=2013/01/10 Thursday,dayOfWeek=Thursday,dayFormat=2013/01/10
01-10 13:10:00.079: D/WidgetUtils(732): calender2ClockImgIdx
01-10 13:10:00.079: D/WidgetUtils(732): updateRefreshTime
01-10 13:10:00.079: D/Utils(732): isUpdating
01-10 13:10:00.079: D/Utils(732): isDataOK
01-10 13:10:00.079: D/Utils(732): dataOverdue
01-10 13:10:00.089: D/WidgetUtils(732): getUpdateTime relativeDay=4
01-10 13:10:00.929: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:06.929: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:12.939: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:18.939: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:24.939: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:30.949: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:36.959: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:42.959: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:48.969: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:54.979: E/CAM_FD(113): ...config thread select timeout...
01-10 13:10:59.999: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=AlarmManager
01-10 13:11:00.029: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver onReceive
01-10 13:11:00.029: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver actionandroid.intent.action.TIME_TICK
01-10 13:11:00.029: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver msg.what=1001
01-10 13:11:00.029: I/WeatherMediumWidgetProvider(732): updateUI(Context context)
01-10 13:11:00.029: D/WeatherMediumWidgetProvider(732): updateUI(Context context, AppWidgetManager widgetManager, int[] appWidgetId)
01-10 13:11:00.039: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:11:00.039: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:11:00.049: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:11:00.049: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:11:00.059: D/WidgetUtils(732): setWeatherUpdateClickListener
01-10 13:11:00.059: D/WidgetUtils(732): setAccuWeatherCickListener
01-10 13:11:00.059: E/WidgetUtils(732): cityCode=cityId:167705
01-10 13:11:00.059: D/WidgetUtils(732): updateWeatherInfo
01-10 13:11:00.059: D/Utils(732): isDataOK
01-10 13:11:00.059: D/Utils(732): dataOverdue
01-10 13:11:00.059: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=AlarmManager
01-10 13:11:00.069: D/WidgetUtils(732): updateWeatherInfo temperature =3.3333333,time1357482579481,weatherDes=Mostly Cloudy,invalidDay=4
01-10 13:11:00.069: D/WidgetUtils(732): updateWeatherInfo weatherDayDataInfo =HighTemperature =3.3333333 LowTemperature =-0.5555556 WeatherIcon =7 TextShort=Cloudy and colder TextLong=Cloudy and colder with a rain and snow shower possible WindSpeed=5 WindDirection=W
01-10 13:11:00.069: D/WidgetUtils(732): updateCityDateTime
01-10 13:11:00.069: D/WidgetUtils(732): getCurCityCalendar
01-10 13:11:00.069: D/WidgetUtils(732): builder=2013/01/10 Thursday,dayOfWeek=Thursday,dayFormat=2013/01/10
01-10 13:11:00.069: D/WidgetUtils(732): calender2ClockImgIdx
01-10 13:11:00.069: D/WidgetUtils(732): updateRefreshTime
01-10 13:11:00.069: D/Utils(732): isUpdating
01-10 13:11:00.069: D/Utils(732): isDataOK
01-10 13:11:00.069: D/Utils(732): dataOverdue
01-10 13:11:00.069: D/WidgetUtils(732): getUpdateTime relativeDay=4
01-10 13:11:00.979: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:06.989: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:12.989: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:18.999: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:24.999: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:31.009: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:37.009: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:43.009: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:49.019: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:55.019: E/CAM_FD(113): ...config thread select timeout...
01-10 13:11:59.999: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=AlarmManager
01-10 13:12:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver onReceive
01-10 13:12:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver actionandroid.intent.action.TIME_TICK
01-10 13:12:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver msg.what=1001
01-10 13:12:00.039: I/WeatherMediumWidgetProvider(732): updateUI(Context context)
01-10 13:12:00.049: D/WeatherMediumWidgetProvider(732): updateUI(Context context, AppWidgetManager widgetManager, int[] appWidgetId)
01-10 13:12:00.049: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:12:00.049: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:12:00.049: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:12:00.049: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:12:00.049: D/WidgetUtils(732): setWeatherUpdateClickListener
01-10 13:12:00.059: D/WidgetUtils(732): setAccuWeatherCickListener
01-10 13:12:00.059: E/WidgetUtils(732): cityCode=cityId:167705
01-10 13:12:00.069: D/WidgetUtils(732): updateWeatherInfo
01-10 13:12:00.069: D/Utils(732): isDataOK
01-10 13:12:00.069: D/Utils(732): dataOverdue
01-10 13:12:00.069: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=AlarmManager
01-10 13:12:00.069: D/WidgetUtils(732): updateWeatherInfo temperature =3.3333333,time1357482579481,weatherDes=Mostly Cloudy,invalidDay=4
01-10 13:12:00.069: D/WidgetUtils(732): updateWeatherInfo weatherDayDataInfo =HighTemperature =3.3333333 LowTemperature =-0.5555556 WeatherIcon =7 TextShort=Cloudy and colder TextLong=Cloudy and colder with a rain and snow shower possible WindSpeed=5 WindDirection=W
01-10 13:12:00.069: D/WidgetUtils(732): updateCityDateTime
01-10 13:12:00.069: D/WidgetUtils(732): getCurCityCalendar
01-10 13:12:00.069: D/WidgetUtils(732): builder=2013/01/10 Thursday,dayOfWeek=Thursday,dayFormat=2013/01/10
01-10 13:12:00.069: D/WidgetUtils(732): calender2ClockImgIdx
01-10 13:12:00.069: D/WidgetUtils(732): updateRefreshTime
01-10 13:12:00.069: D/Utils(732): isUpdating
01-10 13:12:00.069: D/Utils(732): isDataOK
01-10 13:12:00.069: D/Utils(732): dataOverdue
01-10 13:12:00.079: D/WidgetUtils(732): getUpdateTime relativeDay=4
01-10 13:12:01.029: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:07.029: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:13.039: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:19.039: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:25.049: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:31.049: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:37.059: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:43.069: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:49.069: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:55.069: E/CAM_FD(113): ...config thread select timeout...
01-10 13:12:59.999: D/PowerManagerService(199): acquireWakeLock flags=0x1 tag=AlarmManager
01-10 13:13:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver onReceive
01-10 13:13:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver actionandroid.intent.action.TIME_TICK
01-10 13:13:00.039: D/WeatherWidgetServerLite(732): WeatherWidgetReceiver msg.what=1001
01-10 13:13:00.039: I/WeatherMediumWidgetProvider(732): updateUI(Context context)
01-10 13:13:00.039: D/WeatherMediumWidgetProvider(732): updateUI(Context context, AppWidgetManager widgetManager, int[] appWidgetId)
01-10 13:13:00.039: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:13:00.039: D/WidgetUtils(732): setWeatherHomeClickListener
01-10 13:13:00.049: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:13:00.059: D/WidgetUtils(732): setAlarmClockClickListener
01-10 13:13:00.059: D/WidgetUtils(732): setWeatherUpdateClickListener
01-10 13:13:00.059: D/WidgetUtils(732): setAccuWeatherCickListener
01-10 13:13:00.059: E/WidgetUtils(732): cityCode=cityId:167705
01-10 13:13:00.059: D/WidgetUtils(732): updateWeatherInfo
01-10 13:13:00.059: D/Utils(732): isDataOK
01-10 13:13:00.059: D/Utils(732): dataOverdue
01-10 13:13:00.059: D/PowerManagerService(199): releaseWakeLock flags=0x1 tag=AlarmManager
01-10 13:13:00.069: D/WidgetUtils(732): updateWeatherInfo temperature =3.3333333,time1357482579481,weatherDes=Mostly Cloudy,invalidDay=4
01-10 13:13:00.069: D/WidgetUtils(732): updateWeatherInfo weatherDayDataInfo =HighTemperature =3.3333333 LowTemperature =-0.5555556 WeatherIcon =7 TextShort=Cloudy and colder TextLong=Cloudy and colder with a rain and snow shower possible WindSpeed=5 WindDirection=W
01-10 13:13:00.069: D/WidgetUtils(732): updateCityDateTime
01-10 13:13:00.069: D/WidgetUtils(732): getCurCityCalendar
01-10 13:13:00.069: D/WidgetUtils(732): builder=2013/01/10 Thursday,dayOfWeek=Thursday,dayFormat=2013/01/10
01-10 13:13:00.069: D/WidgetUtils(732): calender2ClockImgIdx
01-10 13:13:00.069: D/WidgetUtils(732): updateRefreshTime
01-10 13:13:00.069: D/Utils(732): isUpdating
01-10 13:13:00.069: D/Utils(732): isDataOK
01-10 13:13:00.069: D/Utils(732): dataOverdue
01-10 13:13:00.069: D/WidgetUtils(732): getUpdateTime relativeDay=4