shaka-packager/docs/dc/df2/classshaka_1_1media_1_1WebV...

270 lines
16 KiB
HTML
Raw Normal View History

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>DASH Media Packaging SDK: shaka::media::WebVttMediaParser Class Reference</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript">
$(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">DASH Media Packaging SDK
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
<li><a href="../../namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="../../annotated.html"><span>Classes</span></a></li>
<li><a href="../../files.html"><span>Files</span></a></li>
<li>
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<img id="MSearchSelect" src="../../search/mag_sel.png"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
alt=""/>
<input type="text" id="MSearchField" value="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="../../annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="../../classes.html"><span>Class&#160;Index</span></a></li>
<li><a href="../../hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="../../functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="../../d8/daf/namespaceshaka.html">shaka</a></li><li class="navelem"><b>media</b></li><li class="navelem"><a class="el" href="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.html">WebVttMediaParser</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="../../d4/d14/classshaka_1_1media_1_1WebVttMediaParser-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">shaka::media::WebVttMediaParser Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<div class="dynheader">
Inheritance diagram for shaka::media::WebVttMediaParser:</div>
<div class="dyncontent">
<div class="center">
<img src="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.png" usemap="#shaka::media::WebVttMediaParser_map" alt=""/>
<map id="shaka::media::WebVttMediaParser_map" name="shaka::media::WebVttMediaParser_map">
<area href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html" alt="shaka::media::MediaParser" shape="rect" coords="0,0,203,24"/>
</map>
</div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a4f65f95cba83fe1aca052bd7415d488b"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4f65f95cba83fe1aca052bd7415d488b"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><b>InjectWebVttSampleConvertForTesting</b> (std::unique_ptr&lt; <a class="el" href="../../de/ddd/classshaka_1_1media_1_1WebVttSampleConverter.html">WebVttSampleConverter</a> &gt; converter)</td></tr>
<tr class="separator:a4f65f95cba83fe1aca052bd7415d488b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr><td colspan="2"><div class="groupHeader">MediaParser implementation overrides.</div></td></tr>
<tr class="memitem:af6c0fb7de806cccd0e1f9dd92b5310f3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.html#af6c0fb7de806cccd0e1f9dd92b5310f3">Init</a> (const <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#aef5795d2b3df2526c6e8afe1e4d072bf">InitCB</a> &amp;init_cb, const <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#a3a1f87fb3ed95a9cbd2b6873326a1a4c">NewSampleCB</a> &amp;new_sample_cb, <a class="el" href="../../d1/d1f/classshaka_1_1media_1_1KeySource.html">KeySource</a> *decryption_key_source) override</td></tr>
<tr class="separator:af6c0fb7de806cccd0e1f9dd92b5310f3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa666cb1b9ee2ff940d9fc7efda4b50d7"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.html#aa666cb1b9ee2ff940d9fc7efda4b50d7">Flush</a> () override WARN_UNUSED_RESULT</td></tr>
<tr class="separator:aa666cb1b9ee2ff940d9fc7efda4b50d7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5295c061b251726d1525cefc091101a2"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.html#a5295c061b251726d1525cefc091101a2">Parse</a> (const uint8_t *buf, int size) override WARN_UNUSED_RESULT</td></tr>
<tr class="separator:a5295c061b251726d1525cefc091101a2"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="inherited"></a>
Additional Inherited Members</h2></td></tr>
<tr class="inherit_header pub_types_classshaka_1_1media_1_1MediaParser"><td colspan="2" onclick="javascript:toggleInherit('pub_types_classshaka_1_1media_1_1MediaParser')"><img src="../../closed.png" alt="-"/>&#160;Public Types inherited from <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html">shaka::media::MediaParser</a></td></tr>
<tr class="memitem:aef5795d2b3df2526c6e8afe1e4d072bf inherit pub_types_classshaka_1_1media_1_1MediaParser"><td class="memItemLeft" align="right" valign="top">typedef base::Callback&lt; void(const <br class="typebreak"/>
std::vector&lt; std::shared_ptr<br class="typebreak"/>
&lt; <a class="el" href="../../d5/db1/classshaka_1_1media_1_1StreamInfo.html">StreamInfo</a> &gt; &gt; &amp;stream_info)&gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#aef5795d2b3df2526c6e8afe1e4d072bf">InitCB</a></td></tr>
<tr class="separator:aef5795d2b3df2526c6e8afe1e4d072bf inherit pub_types_classshaka_1_1media_1_1MediaParser"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3a1f87fb3ed95a9cbd2b6873326a1a4c inherit pub_types_classshaka_1_1media_1_1MediaParser"><td class="memItemLeft" align="right" valign="top">typedef base::Callback&lt; bool(uint32_t <br class="typebreak"/>
track_id, const <br class="typebreak"/>
std::shared_ptr&lt; <a class="el" href="../../d7/d6d/classshaka_1_1media_1_1MediaSample.html">MediaSample</a> &gt;<br class="typebreak"/>
&amp;media_sample)&gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#a3a1f87fb3ed95a9cbd2b6873326a1a4c">NewSampleCB</a></td></tr>
<tr class="separator:a3a1f87fb3ed95a9cbd2b6873326a1a4c inherit pub_types_classshaka_1_1media_1_1MediaParser"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock">
<p>Definition at line <a class="el" href="../../db/d64/webvtt__media__parser_8h_source.html#l00026">26</a> of file <a class="el" href="../../db/d64/webvtt__media__parser_8h_source.html">webvtt_media_parser.h</a>.</p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="aa666cb1b9ee2ff940d9fc7efda4b50d7"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool shaka::media::WebVttMediaParser::Flush </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Flush data currently in the parser and put the parser in a state where it can receive data for a new seek point. </p>
<dl class="section return"><dt>Returns</dt><dd>true if successful, false otherwise. </dd></dl>
<p>Implements <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#a26752164d7e8ae6a9a894512291ad9cd">shaka::media::MediaParser</a>.</p>
<p>Definition at line <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html#l00202">202</a> of file <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html">webvtt_media_parser.cc</a>.</p>
</div>
</div>
<a class="anchor" id="af6c0fb7de806cccd0e1f9dd92b5310f3"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void shaka::media::WebVttMediaParser::Init </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#aef5795d2b3df2526c6e8afe1e4d072bf">InitCB</a> &amp;&#160;</td>
<td class="paramname"><em>init_cb</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#a3a1f87fb3ed95a9cbd2b6873326a1a4c">NewSampleCB</a> &amp;&#160;</td>
<td class="paramname"><em>new_sample_cb</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="../../d1/d1f/classshaka_1_1media_1_1KeySource.html">KeySource</a> *&#160;</td>
<td class="paramname"><em>decryption_key_source</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Initialize the parser with necessary callbacks. Must be called before any data is passed to <a class="el" href="../../dc/df2/classshaka_1_1media_1_1WebVttMediaParser.html#a5295c061b251726d1525cefc091101a2">Parse()</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">init_cb</td><td>will be called once enough data has been parsed to determine the initial stream configurations. </td></tr>
<tr><td class="paramname">new_sample_cb</td><td>will be called each time a new media sample is available from the parser. May be NULL, and caller retains ownership. </td></tr>
</table>
</dd>
</dl>
<p>Implements <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#adc7c91bebe75879abba91a56dae52153">shaka::media::MediaParser</a>.</p>
<p>Definition at line <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html#l00195">195</a> of file <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html">webvtt_media_parser.cc</a>.</p>
</div>
</div>
<a class="anchor" id="a5295c061b251726d1525cefc091101a2"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool shaka::media::WebVttMediaParser::Parse </td>
<td>(</td>
<td class="paramtype">const uint8_t *&#160;</td>
<td class="paramname"><em>buf</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&#160;</td>
<td class="paramname"><em>size</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Should be called when there is new data to parse. </p>
<dl class="section return"><dt>Returns</dt><dd>true if successful. </dd></dl>
<p>Implements <a class="el" href="../../d3/d0a/classshaka_1_1media_1_1MediaParser.html#a0c85f3cb0591f67c036276be82a1ba9d">shaka::media::MediaParser</a>.</p>
<p>Definition at line <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html#l00227">227</a> of file <a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html">webvtt_media_parser.cc</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>media/formats/webvtt/<a class="el" href="../../db/d64/webvtt__media__parser_8h_source.html">webvtt_media_parser.h</a></li>
<li>media/formats/webvtt/<a class="el" href="../../d1/d2f/webvtt__media__parser_8cc_source.html">webvtt_media_parser.cc</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Thu Apr 27 2017 19:44:13 for DASH Media Packaging SDK by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="../../doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>