ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    voxl-camer-server's hires snapshot produce huge files

    Ask your questions right here!
    1
    3
    232
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Dong LiuD
      Dong Liu
      last edited by

      I tried to use hires' snapshot to capture 4K images. But because the size of the image produced is huge, the disk filled up very quickly.

      The size of jpeg file is around 48M. If I use imagemagic to convert it to png, the size reduced to 3.7M. I then use imagemagic again to convert it to jpeg, the size is only 740K.

      Browsing through the code of hal3_camera_mgr.cpp, in WriteSnapshot() just writes the whole allocated buffer to file. Is there any variable indicates the real size of data produced by the camera module?

      Thanks!

      1 Reply Last reply Reply Quote 0
      • Dong LiuD
        Dong Liu
        last edited by

        I found out this https://android.googlesource.com/platform/frameworks/av/+/master/services/camera/libcameraservice/device3/Camera3OutputStream.cpp#1337

        Is function android::camera2::JpegProcessor::findJpegSize() available on voxl?

        Thanks!

        1 Reply Last reply Reply Quote 0
        • Dong LiuD
          Dong Liu
          last edited by

          I extract the findJpegSize function, add to voxl-camera-server. Now it will produce the correct size snapshot.

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          Powered by NodeBB | Contributors