FAQ
Hi,

Can anyone point me in the right direction for splitting a video into
frames? (export each frame to raw image data for processing)
I know OpenCV for android doesn't currently support video capture and other
video related processing, but maybe there's a workaround this for just
grabbing the frames.
I don't need to recreate the video after the frame processing is done, just
need to grab the frames.

Also, if this is not possible with OpenCV, how can I achieve this? (without
ffmpeg or native code)

Thanks in advance.

Search Discussions

  • Kirill Kornyakov at May 5, 2012 at 8:46 am
    1. If you want to just record a video, you can use the standard Android
    camera application. We do this sometimes for creation of test videos, after
    that you can copy them to the host and work on your algorithm.
    2. If you need a method to split a video into separate frames on
    desktop, you can use the following advice:
    http://stackoverflow.com/questions/3917601/ffmpeg-split-avi-into-frames-with-known-frame-rate
    .
    3. On Android you can create an application which gets frames from
    camera and then calls Highgui.imwrite OpenCV function. But most likely
    that FPS will not be sufficient. If so, you can keep Mat's in RAM and then
    write them to the SD card -- you should be able to keep several hundreds of
    images in memory (native memory is not visible for Dalvik).
    4. Or you can record a video with Java code (I don't know how to do
    this), then read it with Java code, and export individual frames as Bitmap,
    or convert Bitmaps to Mats and imwrite them.

    Regards,
    Kirill
    On Friday, May 4, 2012 2:12:29 PM UTC+4, Dragos Raducanu wrote:

    Hi,

    Can anyone point me in the right direction for splitting a video into
    frames? (export each frame to raw image data for processing)
    I know OpenCV for android doesn't currently support video capture and
    other video related processing, but maybe there's a workaround this for
    just grabbing the frames.
    I don't need to recreate the video after the frame processing is done,
    just need to grab the frames.

    Also, if this is not possible with OpenCV, how can I achieve this?
    (without ffmpeg or native code)

    Thanks in advance.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupandroid-opencv @
categoriesandroid
postedMay 4, '12 at 10:30a
activeMay 5, '12 at 8:46a
posts2
users2
websiteandroid.com

People

Translate

site design / logo © 2018 Grokbase