Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse
Brand Logo

ModalAI Forum

  1. ModalAI Support Forum
  2. General Questions
  3. voxl-camer-server's hires snapshot produce huge files

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

Scheduled Pinned Locked Moved Unsolved General Questions
3 Posts 1 Posters 762 Views
  • 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 Offline
    Dong LiuD Offline
    Dong Liu
    Contributor
    wrote on last edited by
    #1

    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
    0
    • Dong LiuD Offline
      Dong LiuD Offline
      Dong Liu
      Contributor
      wrote on last edited by
      #2

      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
      0
      • Dong LiuD Offline
        Dong LiuD Offline
        Dong Liu
        Contributor
        wrote on last edited by
        #3

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

        1 Reply Last reply
        0

        Reading along? Create a free ModalAI Forum account to join in.

        With an account you can reply, ask your own question, get an email when a ModalAI engineer answers, and mark the reply that solved it. Your place in each thread is saved between visits.

        Questions about VOXL, Flight Core, ESCs and ModalAI drones are answered here by the engineers who build them.

        Register Login
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        ModalAI
        Categories Recent Tags ModalAI.com Docs
        © 2026 ModalAI® · Accelerating autonomy for smaller, smarter, safer drones · Powered by NodeBB
        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups