tizen 2.0 init
[framework/multimedia/gst-plugins-good0.10.git] / docs / plugins / html / gst-plugins-good-plugins-mj2mux.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>mj2mux</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
7 <link rel="home" href="index.html" title="GStreamer Good Plugins 0.10 Plugins Reference Manual">
8 <link rel="up" href="ch01.html" title="gst-plugins-good Elements">
9 <link rel="prev" href="gst-plugins-good-plugins-matroskademux.html" title="matroskademux">
10 <link rel="next" href="gst-plugins-good-plugins-monoscope.html" title="monoscope">
11 <meta name="generator" content="GTK-Doc V1.18 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
13 </head>
14 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
16 <tr valign="middle">
17 <td><a accesskey="p" href="gst-plugins-good-plugins-matroskademux.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
18 <td><a accesskey="u" href="ch01.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
19 <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
20 <th width="100%" align="center">GStreamer Good Plugins 0.10 Plugins Reference Manual</th>
21 <td><a accesskey="n" href="gst-plugins-good-plugins-monoscope.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
22 </tr>
23 <tr><td colspan="5" class="shortcuts">
24 <a href="#gst-plugins-good-plugins-mj2mux.synopsis" class="shortcut">Top</a>
25                    | 
26                   <a href="#gst-plugins-good-plugins-mj2mux.description" class="shortcut">Description</a>
27                    | 
28                   <a href="#gst-plugins-good-plugins-mj2mux.object-hierarchy" class="shortcut">Object Hierarchy</a>
29                    | 
30                   <a href="#gst-plugins-good-plugins-mj2mux.implemented-interfaces" class="shortcut">Implemented Interfaces</a>
31                    | 
32                   <a href="#gst-plugins-good-plugins-mj2mux.properties" class="shortcut">Properties</a>
33 </td></tr>
34 </table>
35 <div class="refentry">
36 <a name="gst-plugins-good-plugins-mj2mux"></a><div class="titlepage"></div>
37 <div class="refnamediv"><table width="100%"><tr>
38 <td valign="top">
39 <h2><span class="refentrytitle"><a name="gst-plugins-good-plugins-mj2mux.top_of_page"></a>mj2mux</span></h2>
40 <p>mj2mux — Muxer for Motion JPEG-2000 (.mj2) files</p>
41 </td>
42 <td valign="top" align="right"></td>
43 </tr></table></div>
44 <div class="refsynopsisdiv">
45 <a name="gst-plugins-good-plugins-mj2mux.synopsis"></a><h2>Synopsis</h2>
46 <a name="GstMJ2Mux"></a><pre class="synopsis">                    <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux-struct" title="GstMJ2Mux">GstMJ2Mux</a>;
47 </pre>
48 </div>
49 <div class="refsect1">
50 <a name="gst-plugins-good-plugins-mj2mux.object-hierarchy"></a><h2>Object Hierarchy</h2>
51 <pre class="synopsis">
52   <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
53    +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstObject.html">GstObject</a>
54          +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html">GstElement</a>
55                +----GstMJ2Mux
56 </pre>
57 </div>
58 <div class="refsect1">
59 <a name="gst-plugins-good-plugins-mj2mux.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
60 <p>
61 GstMJ2Mux implements
62  <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstTagSetter.html">GstTagSetter</a> and  GstTagXmpWriter.</p>
63 </div>
64 <div class="refsect1">
65 <a name="gst-plugins-good-plugins-mj2mux.properties"></a><h2>Properties</h2>
66 <pre class="synopsis">
67   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--dts-method" title='The "dts-method" property'>dts-method</a>"               <span class="type">GstQTMuxDtsMethods</span>    : Read / Write / Construct
68   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--faststart" title='The "faststart" property'>faststart</a>"                <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
69   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--faststart-file" title='The "faststart-file" property'>faststart-file</a>"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write / Construct
70   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--fragment-duration" title='The "fragment-duration" property'>fragment-duration</a>"        <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct
71   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--moov-recovery-file" title='The "moov-recovery-file" property'>moov-recovery-file</a>"       <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write / Construct
72   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--movie-timescale" title='The "movie-timescale" property'>movie-timescale</a>"          <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct
73   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--presentation-time" title='The "presentation-time" property'>presentation-time</a>"        <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write / Construct
74   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--streamable" title='The "streamable" property'>streamable</a>"               <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write / Construct
75   "<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--trak-timescale" title='The "trak-timescale" property'>trak-timescale</a>"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct
76 </pre>
77 </div>
78 <div class="refsect1">
79 <a name="gst-plugins-good-plugins-mj2mux.description"></a><h2>Description</h2>
80 <p>
81 This element merges streams (audio and video) into MJ2 (.mj2) files.
82 </p>
83 <p>
84 The following background intends to explain why various similar muxers
85 are present in this plugin.
86 </p>
87 <p>
88 The <a class="ulink" href="http://www.apple.com/quicktime/resources/qtfileformat.pdf" target="_top">
89 QuickTime file format specification</a> served as basis for the MP4 file
90 format specification (mp4mux), and as such the QuickTime file structure is
91 nearly identical to the so-called ISO Base Media file format defined in
92 ISO 14496-12 (except for some media specific parts).
93 In turn, the latter ISO Base Media format was further specialized as a
94 Motion JPEG-2000 file format in ISO 15444-3 (mj2mux)
95 and in various 3GPP(2) specs (gppmux).
96 The fragmented file features defined (only) in ISO Base Media are used by
97 ISMV files making up (a.o.) Smooth Streaming (ismlmux).
98 </p>
99 <p>
100 A few properties (<a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--movie-timescale" title='The "movie-timescale" property'>movie-timescale</a>,
101 <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--trak-timescale" title='The "trak-timescale" property'>trak-timescale</a>) allow adjusting
102 some technical parameters, which might be useful in (rare) cases to resolve
103 compatibility issues in some situations.
104 </p>
105 <p>
106 Some other properties influence the result more fundamentally.
107 A typical mov/mp4 file's metadata (aka moov) is located at the end of the file,
108 somewhat contrary to this usually being called "the header".
109 However, a <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--faststart" title='The "faststart" property'>faststart</a> file will
110 (with some effort) arrange this to be located near start of the file,
111 which then allows it e.g. to be played while downloading.
112 Alternatively, rather than having one chunk of metadata at start (or end),
113 there can be some metadata at start and most of the other data can be spread
114 out into fragments of <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--fragment-duration" title='The "fragment-duration" property'>fragment-duration</a>.
115 If such fragmented layout is intended for streaming purposes, then
116 <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--streamable" title='The "streamable" property'>streamable</a> allows foregoing to add
117 index metadata (at the end of file).
118 </p>
119 <p>
120 <a class="link" href="gst-plugins-good-plugins-mj2mux.html#GstMJ2Mux--dts-method" title='The "dts-method" property'>dts-method</a> allows selecting a
121 method for managing input timestamps (stay tuned for 0.11 to have this
122 automagically settled).  The default delta/duration method should handle nice
123 (aka perfect streams) just fine, but may experience problems otherwise
124 (e.g. input stream with re-ordered B-frames and/or with frame dropping).
125 The re-ordering approach re-assigns incoming timestamps in ascending order
126 to incoming buffers and offers an alternative in such cases.  In cases where
127 that might fail, the remaining method can be tried, which is exact and
128 according to specs, but might experience playback on not so spec-wise players.
129 Note that this latter approach also requires one to enable
130 presentation-timestamp.
131 </p>
132 <p>
133 </p>
134 <div class="refsect2">
135 <a name="idp16635456"></a><h3>Example pipelines</h3>
136 <div class="informalexample">
137   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
138     <tbody>
139       <tr>
140         <td class="listing_lines" align="right"><pre>1</pre></td>
141         <td class="listing_code"><pre class="programlisting">gst<span class="gtkdoc opt">-</span>launch v4l2src num<span class="gtkdoc opt">-</span>buffers<span class="gtkdoc opt">=</span><span class="number">50</span> <span class="gtkdoc opt">!</span> queue <span class="gtkdoc opt">!</span> jp2kenc <span class="gtkdoc opt">!</span> mj2mux <span class="gtkdoc opt">!</span> filesink location<span class="gtkdoc opt">=</span>video<span class="gtkdoc opt">.</span>mj2</pre></td>
142       </tr>
143     </tbody>
144   </table>
145 </div>
146
147 Records a video stream captured from a v4l2 device, encodes it into JPEG-2000
148 and muxes it into an mj2 file.
149 </div>
150 <p>
151 </p>
152 <p>
153 Documentation last reviewed on 2011-04-21
154 </p>
155 <div class="refsynopsisdiv">
156 <h2>Synopsis</h2>
157 <div class="refsect2">
158 <a name="idp14241984"></a><h3>Element Information</h3>
159 <div class="variablelist"><table border="0">
160 <col align="left" valign="top">
161 <tbody>
162 <tr>
163 <td><p><span class="term">plugin</span></p></td>
164 <td>
165             <a class="link" href="gst-plugins-good-plugins-plugin-isomp4.html#plugin-isomp4">isomp4</a>
166           </td>
167 </tr>
168 <tr>
169 <td><p><span class="term">author</span></p></td>
170 <td>Thiago Sousa Santos &lt;thiagoss@embedded.ufcg.edu.br&gt;</td>
171 </tr>
172 <tr>
173 <td><p><span class="term">class</span></p></td>
174 <td>Codec/Muxer</td>
175 </tr>
176 </tbody>
177 </table></div>
178 </div>
179 <hr>
180 <div class="refsect2">
181 <a name="idp12661712"></a><h3>Element Pads</h3>
182 <div class="variablelist"><table border="0">
183 <col align="left" valign="top">
184 <tbody>
185 <tr>
186 <td><p><span class="term">name</span></p></td>
187 <td>audio_%d</td>
188 </tr>
189 <tr>
190 <td><p><span class="term">direction</span></p></td>
191 <td>sink</td>
192 </tr>
193 <tr>
194 <td><p><span class="term">presence</span></p></td>
195 <td>request</td>
196 </tr>
197 <tr>
198 <td><p><span class="term">details</span></p></td>
199 <td>audio/x-raw-int, width=(int)8, depth=(int)8, channels=(int)[ 1, 2 ], rate=(int)[ 1, 2147483647 ], signed=(boolean){ true, false }</td>
200 </tr>
201 <tr>
202 <td><p><span class="term"></span></p></td>
203 <td> audio/x-raw-int, width=(int)16, depth=(int)16, endianness=(int){ 4321, 1234 }, channels=(int)[ 1, 2 ], rate=(int)[ 1, 2147483647 ], signed=(boolean)true</td>
204 </tr>
205 </tbody>
206 </table></div>
207 <div class="variablelist"><table border="0">
208 <col align="left" valign="top">
209 <tbody>
210 <tr>
211 <td><p><span class="term">name</span></p></td>
212 <td>video_%d</td>
213 </tr>
214 <tr>
215 <td><p><span class="term">direction</span></p></td>
216 <td>sink</td>
217 </tr>
218 <tr>
219 <td><p><span class="term">presence</span></p></td>
220 <td>request</td>
221 </tr>
222 <tr>
223 <td><p><span class="term">details</span></p></td>
224 <td>image/x-j2c, width=(int)[ 16, 4096 ], height=(int)[ 16, 4096 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
225 </tr>
226 <tr>
227 <td><p><span class="term"></span></p></td>
228 <td> image/x-jpc, width=(int)[ 16, 4096 ], height=(int)[ 16, 4096 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
229 </tr>
230 </tbody>
231 </table></div>
232 <div class="variablelist"><table border="0">
233 <col align="left" valign="top">
234 <tbody>
235 <tr>
236 <td><p><span class="term">name</span></p></td>
237 <td>src</td>
238 </tr>
239 <tr>
240 <td><p><span class="term">direction</span></p></td>
241 <td>source</td>
242 </tr>
243 <tr>
244 <td><p><span class="term">presence</span></p></td>
245 <td>always</td>
246 </tr>
247 <tr>
248 <td><p><span class="term">details</span></p></td>
249 <td>video/mj2</td>
250 </tr>
251 </tbody>
252 </table></div>
253 </div>
254 </div>
255 <p>
256 </p>
257 </div>
258 <div class="refsect1">
259 <a name="gst-plugins-good-plugins-mj2mux.details"></a><h2>Details</h2>
260 <div class="refsect2">
261 <a name="GstMJ2Mux-struct"></a><h3>GstMJ2Mux</h3>
262 <pre class="programlisting">typedef struct _GstMJ2Mux GstMJ2Mux;</pre>
263 <p>
264 </p>
265 </div>
266 </div>
267 <div class="refsect1">
268 <a name="gst-plugins-good-plugins-mj2mux.property-details"></a><h2>Property Details</h2>
269 <div class="refsect2">
270 <a name="GstMJ2Mux--dts-method"></a><h3>The <code class="literal">"dts-method"</code> property</h3>
271 <pre class="programlisting">  "dts-method"               <span class="type">GstQTMuxDtsMethods</span>    : Read / Write / Construct</pre>
272 <p>Method to determine DTS time.</p>
273 <p>Default value: reorder</p>
274 </div>
275 <hr>
276 <div class="refsect2">
277 <a name="GstMJ2Mux--faststart"></a><h3>The <code class="literal">"faststart"</code> property</h3>
278 <pre class="programlisting">  "faststart"                <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
279 <p>If the file should be formatted for faststart (headers first).</p>
280 <p>Default value: FALSE</p>
281 </div>
282 <hr>
283 <div class="refsect2">
284 <a name="GstMJ2Mux--faststart-file"></a><h3>The <code class="literal">"faststart-file"</code> property</h3>
285 <pre class="programlisting">  "faststart-file"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write / Construct</pre>
286 <p>File that will be used temporarily to store data from the stream when creating a faststart file. If null a filepath will be created automatically.</p>
287 <p>Default value: NULL</p>
288 </div>
289 <hr>
290 <div class="refsect2">
291 <a name="GstMJ2Mux--fragment-duration"></a><h3>The <code class="literal">"fragment-duration"</code> property</h3>
292 <pre class="programlisting">  "fragment-duration"        <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct</pre>
293 <p>Fragment durations in ms (produce a fragmented file if &gt; 0).</p>
294 <p>Default value: 0</p>
295 </div>
296 <hr>
297 <div class="refsect2">
298 <a name="GstMJ2Mux--moov-recovery-file"></a><h3>The <code class="literal">"moov-recovery-file"</code> property</h3>
299 <pre class="programlisting">  "moov-recovery-file"       <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write / Construct</pre>
300 <p>File to be used to store data for moov atom making movie file recovery possible in case of a crash during muxing. Null for disabled. (Experimental).</p>
301 <p>Default value: NULL</p>
302 </div>
303 <hr>
304 <div class="refsect2">
305 <a name="GstMJ2Mux--movie-timescale"></a><h3>The <code class="literal">"movie-timescale"</code> property</h3>
306 <pre class="programlisting">  "movie-timescale"          <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct</pre>
307 <p>Timescale to use in the movie (units per second).</p>
308 <p>Allowed values: &gt;= 1</p>
309 <p>Default value: 1000</p>
310 </div>
311 <hr>
312 <div class="refsect2">
313 <a name="GstMJ2Mux--presentation-time"></a><h3>The <code class="literal">"presentation-time"</code> property</h3>
314 <pre class="programlisting">  "presentation-time"        <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write / Construct</pre>
315 <p>Calculate and include presentation/composition time (in addition to decoding time).</p>
316 <p>Default value: TRUE</p>
317 </div>
318 <hr>
319 <div class="refsect2">
320 <a name="GstMJ2Mux--streamable"></a><h3>The <code class="literal">"streamable"</code> property</h3>
321 <pre class="programlisting">  "streamable"               <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write / Construct</pre>
322 <p>If set to true, the output should be as if it is to be streamed and hence no indexes written or duration written.</p>
323 <p>Default value: FALSE</p>
324 </div>
325 <hr>
326 <div class="refsect2">
327 <a name="GstMJ2Mux--trak-timescale"></a><h3>The <code class="literal">"trak-timescale"</code> property</h3>
328 <pre class="programlisting">  "trak-timescale"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a>                 : Read / Write / Construct</pre>
329 <p>Timescale to use for the tracks (units per second, 0 is automatic).</p>
330 <p>Default value: 0</p>
331 </div>
332 </div>
333 </div>
334 <div class="footer">
335 <hr>
336           Generated by GTK-Doc V1.18</div>
337 </body>
338 </html>