Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><strong>Update for 2017:</strong></p> <p>You can do streaming Video and Audio now by using the <code>VideoToolbox</code> API. Read the documentation here: <a href="https://developer.apple.com/reference/videotoolbox/vtcompressionsession-7bn" rel="nofollow noreferrer">VTCompressionSession</a></p> <p><strong>Original answer (from 2013):</strong></p> <p>That is currently not possible, you'll have to write to a file or compress the video stream with a software-encoder (you won't get HD and very bad battery times though). All possibilities to get a hand on the hardware-encoder have to write to the disk. I think this is because of memory shortage on the devices.</p> <p>Methods to get hardware accelerated h264 compression:</p> <ul> <li><a href="http://developer.apple.com/library/ios/#documentation/AVFoundation/Reference/AVAssetWriter_Class/Reference/Reference.html" rel="nofollow noreferrer">AVAssetWriter</a></li> <li><a href="https://developer.apple.com/library/mac/#documentation/AVFoundation/Reference/AVCaptureMovieFileOutput_Class/Reference/Reference.html" rel="nofollow noreferrer">AVCaptureMovieFileOutput</a></li> </ul> <p>As you can see both write to a file, writing to a pipe does not work as the encoder updates header information after a frame or GOP has been fully written. So you better don't touch the file while the encoder writes to it as it does randomly rewrite header information. Without this header information the video file will not be playable (it updates the size field, so the first header written says the file is 0 bytes).</p> <p>You can, however, record 5 seconds and then switch the output-file, transmit the now "old" 5 seconds snippet and delete it afterwards. You'll have to demux the *.mov or *.mp4 container though to get to the h264 video data to send.</p> <p>If you need audio: if you switch the file you'll loose some audio samples, so you'll have to roll your own buffer management for that (or just record audio separately).</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload