How to get raw preview data from Camera object at least 15 frames per second in Android?

后端 未结 6 1346
忘了有多久
忘了有多久 2020-11-30 19:32

I need to obtain raw preview data from Camera object at least 15 frame per second, but I can only get a frame in 110 milliseconds which means I can get only

6条回答
  •  南笙
    南笙 (楼主)
    2020-11-30 20:28

    This should not be a problem. My androangelo (it's in the market) app get's up to 30 frames per second (at least I implemented a rate-brake to slow it down).

    Please check carefully, whether Your log is filled with garbage-collector statements. This is the case if too few buffers are added. This had be the trick for me. At least I came up to add 20! buffers to the camera.

    Then the processing of each frame should take place in a separate thread. While an image is in the thread for processing, the callback should skip the current frame.

提交回复
热议问题