📄 media.html
字号:
<DL><DD>This method returns you the input map of the media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/REF/refMovieToolbox.48.htm#refMov157">QuickTime::GetMediaInputMap()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Returns:</B><DD>an AtomContainer object for media's input map.</DL></DD></DL><HR><A NAME="setInputMap(quicktime.std.movies.AtomContainer)"><!-- --></A><H3>setInputMap</H3><PRE>public final void <B>setInputMap</B>(<A HREF="../../../../quicktime/std/movies/AtomContainer.html">AtomContainer</A> inputMap) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows you to set a new input map for a media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/REF/refMovieToolbox.48.htm#refMov160">QuickTime::SetMediaInputMap()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>inputMap</CODE> - Specifies the new input map.</DL></DD></DL><HR><A NAME="beginEdits()"><!-- --></A><H3>beginEdits</H3><PRE>public final void <B>beginEdits</B>() throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method starts a media-editing session. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1061">QuickTime::BeginMediaEdits()</a> </b><BR><BR></DL></DD></DL><HR><A NAME="endEdits()"><!-- --></A><H3>endEdits</H3><PRE>public final void <B>endEdits</B>() throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method ends a media-editing session. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1064">QuickTime::EndMediaEdits()</a> </b><BR><BR></DL></DD></DL><HR><A NAME="setDefaultDataRefIndex(int)"><!-- --></A><H3>setDefaultDataRefIndex</H3><PRE>public final void <B>setDefaultDataRefIndex</B>(int index) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows your application to determine the default index for a media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/REF/refMovieToolbox.42.htm#refMov122">QuickTime::SetMediaDefaultDataRefIndex()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - Specifies the index of the data ref.</DL></DD></DL><HR><A NAME="getDataHandlerDescription(int)"><!-- --></A><H3>getDataHandlerDescription</H3><PRE>public final <A HREF="../../../../quicktime/std/movies/media/HandlerInfo.html">HandlerInfo</A> <B>getDataHandlerDescription</B>(int index) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows your application to retrieve information about a media's data handler. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.46.htm#iqMovi1089">QuickTime::GetMediaDataHandlerDescription()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>index</CODE> - Identifies the data reference.<DT><B>Returns:</B><DD>a HandlerInfo object.</DL></DD></DL><HR><A NAME="getSampleDescriptionCount()"><!-- --></A><H3>getSampleDescriptionCount</H3><PRE>public final int <B>getSampleDescriptionCount</B>() throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method returns the number of sample descriptions in a media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.3c.htm#iqMovi900">QuickTime::GetMediaSampleDescriptionCount()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Returns:</B><DD>the number of sample descriptions in a media.</DL></DD></DL><HR><A NAME="getSampleCount()"><!-- --></A><H3>getSampleCount</H3><PRE>public final int <B>getSampleCount</B>() throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows you to determine the number of samples in a media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.3c.htm#iqMovi897">QuickTime::GetMediaSampleCount()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Returns:</B><DD>an integer that specifies the number of samples in the specified media.</DL></DD></DL><HR><A NAME="getSyncSampleCount()"><!-- --></A><H3>getSyncSampleCount</H3><PRE>public final int <B>getSyncSampleCount</B>() throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows you to determine the number of samples in a media. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/REF/ref_undocfuncs.htm#pgfId=16959">QuickTime::GetMediaSyncSampleCount()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Returns:</B><DD>an integer that specifies the number of samples in the specified media.</DL></DD></DL><HR><A NAME="sampleNumToMediaTime(int)"><!-- --></A><H3>sampleNumToMediaTime</H3><PRE>public final <A HREF="../../../../quicktime/std/movies/TimeInfo.html">TimeInfo</A> <B>sampleNumToMediaTime</B>(int logicalSampleNum) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows you to find the time at which a specified sample plays. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.3c.htm#iqMovi915">QuickTime::SampleNumToMediaTime()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>logicalSampleNum</CODE> - Specifies the sample number.<DT><B>Returns:</B><DD>a TimeInfo object that contains the time and duration of the sample.</DL></DD></DL><HR><A NAME="timeToSampleNum(int)"><!-- --></A><H3>timeToSampleNum</H3><PRE>public final <A HREF="../../../../quicktime/std/movies/media/SampleTimeInfo.html">SampleTimeInfo</A> <B>timeToSampleNum</B>(int time) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows you to find the sample that contains the data for a specified time. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.3c.htm#iqMovi911">QuickTime::MediaTimeToSampleNum()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>time</CODE> - Specifies the time for which you are retrieving sample information.<DT><B>Returns:</B><DD>a SampleTimeInfo object that contains the sample time and sample duration for the specified sample.</DL></DD></DL><HR><A NAME="addSample(quicktime.util.QTHandleRef, int, int, int, quicktime.std.movies.media.SampleDescription, int, int)"><!-- --></A><H3>addSample</H3><PRE>public final int <B>addSample</B>(<A HREF="../../../../quicktime/util/QTHandleRef.html">QTHandleRef</A> data, int dataOffset, int dataSize, int durationPerSample, <A HREF="../../../../quicktime/std/movies/media/SampleDescription.html">SampleDescription</A> sampleDesc, int numberOfSamples, int sampleFlags) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method adds sample data and a description to a media object. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1067">QuickTime::AddMediaSample()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>data</CODE> - Specifies media sample's data handle.<DD><CODE>dataOffset</CODE> - an offset into the sample data.<DD><CODE>dataSize</CODE> - Specifies media sample's data size.<DD><CODE>durationPerSample</CODE> - Specifies media sample's duration.<DD><CODE>sampleDesc</CODE> - Specifies media sample's sample description.<DD><CODE>numberOfSamples</CODE> - Specifies the number of samples.<DD><CODE>sampleFlags</CODE> - Specifies flags for samples.<DT><B>Returns:</B><DD>the time where the sample was inserted.</DL></DD></DL><HR><A NAME="getSample(int, int, int)"><!-- --></A><H3>getSample</H3><PRE>public final <A HREF="../../../../quicktime/std/movies/media/MediaSample.html">MediaSample</A> <B>getSample</B>(int maxSizeToGrow, int time, int maxNumberOfSamples) throws <A HREF="../../../../quicktime/QTException.html">QTException</A></PRE><DL><DD>This method returns a sample from a movie data file. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1074">QuickTime::GetMediaSample()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>maxSizeToGrow</CODE> - Specifies the maximum number of bytes of sample data to be returned.<DD><CODE>time</CODE> - Specifies the starting time of the sample to be retrieved.<DD><CODE>maxNumberOfSamples</CODE> - Specifies the maximum number of samples to be returned.<DT><B>Returns:</B><DD>a MediaSample object specifying the media sample.</DL></DD></DL><HR><A NAME="addSampleReference(int, int, int, quicktime.std.movies.media.SampleDescription, int, int)"><!-- --></A><H3>addSampleReference</H3><PRE>public final int <B>addSampleReference</B>(int dataOffset, int dataSize, int durationPerSample, <A HREF="../../../../quicktime/std/movies/media/SampleDescription.html">SampleDescription</A> sampleDesc, int numberOfSamples, int sampleFlags) throws <A HREF="../../../../quicktime/std/StdQTException.html">StdQTException</A></PRE><DL><DD>This method allows your application to work with samples that have already been added to a movie data file. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1070">QuickTime::AddMediaSampleReference()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>dataOffset</CODE> - an offset into the sample data.<DD><CODE>dataSize</CODE> - Specifies media sample's data size.<DD><CODE>durationPerSample</CODE> - Specifies media sample's duration.<DD><CODE>sampleDesc</CODE> - Specifies media sample's sample description.<DD><CODE>numberOfSamples</CODE> - Specifies the number of samples.<DD><CODE>sampleFlags</CODE> - Specifies flags for samples.<DT><B>Returns:</B><DD>the time where the reference was inserted</DL></DD></DL><HR><A NAME="getSampleReference(int, int)"><!-- --></A><H3>getSampleReference</H3><PRE>public final <A HREF="../../../../quicktime/std/movies/media/SampleInfo.html">SampleInfo</A> <B>getSampleReference</B>(int time, int maxNumberOfSamples) throws <A HREF="../../../../quicktime/QTException.html">QTException</A></PRE><DL><DD>This method allows your application to obtain reference information about samples that are stored in a movie data file. <BR><BR><b> <a href="http://developer.apple.com/techpubs/quicktime/qtdevdocs/INMAC/QT/iqMovieToolbox.44.htm#iqMovi1076">QuickTime::GetMediaSampleReference()</a> </b><BR><BR></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>time</CODE> - Specifies the starting time of the sample reference to be retrieved.<DD><CODE>maxNumberOfSamples</CODE> - Specifies the maximum number of samples to be returned.<DT><B>Returns:</B><DD>a SampleInfo object.</DL></DD></DL><HR><A NAME="addSampleReference(quicktime.std.movies.media.SampleDescription, int, quicktime.std.movies.media.SampleReferenceVector)"><!-- --></A><H3>addSampleReference</H3><PRE>public final int <B>addSampleReference</B>(<A HREF="../../../../quicktime/std/movies/media/SampleDescription.html">SampleDescription</A> sampleDescription, int numOfSamples, <A HREF="../../../../quicktime/std/movies/media/SampleReferenceVector.html">SampleReferenceVector</A> s
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -