Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7836253
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T14:03:16+00:00 2026-06-02T14:03:16+00:00

I’m trying to write an app that uploads videos from Android phones as they

  • 0

I’m trying to write an app that uploads videos from Android phones as they are being recorded by reading from .mp4 file and uploading the bytes as they are written to the file. The problem is that, as far as I can tell, the moov atom and some other assorted data do not seem to be written to file until the video recording has finished and the video file has been closed. Is there any way to process the video file and add these metadata on the server-side assuming either

  1. The full video file has been uploaded (but without the moov atom or any other data that does not get written on the first pass)
  2. Only part of the video has been uploaded (e.g. the first 10 seconds) and I want to convert this into a valid mp4 file containing the uploaded segment of video.

I’ve seen links like http://www.mattakis.com/blog/kisg/20090708/broadcasting-video-with-android-without-writing-to-the-file-system but they gloss over the problem by simply stating

So the received stream will have to be fixed up after the recording is finished, or the raw video / audio frames have to be processed by the server.

without explaining exactly how to go about doing that.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T14:03:18+00:00Added an answer on June 2, 2026 at 2:03 pm

    As you’ve noticed, the MP4 format can be difficult to use in such situations. I suspect the linked blog post doesn’t go into detail about the “fixing up” because it can be quite involved. In addition to writing the missing size field of the mdat box, you’ll need to generate the ftyp and moov boxes. If you really need an end-to-end MP4 solution, ISO 14496-12 and ISO 14496-14 will tell you more than you ever wanted to know about how to build these data structures.

    However, you might find that a much more elegant solution is to use a format that is actually suited for real-time processing. In other words, on the Android side, remux the video stream into a real-time format and send that to the server. On the server side, you then have great flexibility for processing the video: You can remux the whole video back into MP4, you can slice-and-dice, make 10-second chunks, or whatever. The open-source Sipdroid project contains some code that demonstrates remuxing live video into RTP. (You may prefer a reliable transmission format — RTP over TCP, or whatever — the principle is the same.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using Paperclip to handle profile photo uploads in my app. They upload
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I'm trying to create an if statement in PHP that prevents a single post
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.