View Source ExMP4.FragDataWriter behaviour (MP4 Reader and Writer v0.6.0)
A behaviour module for implementing fragmented mp4 data writer.
Summary
Callbacks
Close the output.
Initialize the output.
Invoked to handle writing while seeking into the file.
Invoked to handle writing the whole fragment (sidx
[optional] + moof
+ mdat
).
Invoked to handle writing media header initialization.
Types
@type location() :: :file.location() | nil
@type state() :: any()
Callbacks
@callback close(state()) :: :ok
Close the output.
Initialize the output.
The returned state
will be the first argument on the other callbacks.
Invoked to handle writing while seeking into the file.
This is an optional callback, only called by the ExMP4.FWriter
to
update the fragments duration in case mehd
is present.
Invoked to handle writing the whole fragment (sidx
[optional] + moof
+ mdat
).
Invoked to handle writing media header initialization.