• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

frameworks/base


Commit MetaInfo

Revisão05753be9945cea27d3ceb754dd6486fabdf0e9a1 (tree)
Hora2010-03-17 16:16:23
AutorWallace Wang <wallage@qq.c...>
CommiterChih-Wei Huang

Mensagem de Log

Fix the Camera bug on using USB disk

Change /sdcard/tmp.jpg to /data/tmp.jpg

Mudança Sumário

Diff

--- a/camera/libcameraservice/V4L2Camera.cpp
+++ b/camera/libcameraservice/V4L2Camera.cpp
@@ -31,6 +31,8 @@
3131
3232 #include <linux/videodev.h>
3333
34+#define CAMERA_FILE "/data/tmp.jpg"
35+
3436 extern "C" {
3537 #include <jpeglib.h>
3638 }
@@ -351,7 +353,7 @@ sp<IMemory> V4L2Camera::GrabJpegFrame ()
351353 }
352354 nDequeued++;
353355
354- fileSize = savePicture((unsigned char *)videoIn->mem[videoIn->buf.index], "/sdcard/tmp.jpg");
356+ fileSize = savePicture((unsigned char *)videoIn->mem[videoIn->buf.index], CAMERA_FILE);
355357
356358 /* Enqueue buffer */
357359 ret = ioctl(fd, VIDIOC_QBUF, &videoIn->buf);
@@ -361,7 +363,7 @@ sp<IMemory> V4L2Camera::GrabJpegFrame ()
361363 }
362364 nQueued++;
363365
364- input = fopen("/sdcard/tmp.jpg", "rb");
366+ input = fopen(CAMERA_FILE, "rb");
365367
366368 if (input == NULL)
367369 LOGE("GrabJpegFrame: Input file == NULL");