ov_time_seek.html 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <html>
  2. <head>
  3. <title>Vorbisfile - function - ov_time_seek</title>
  4. <link rel=stylesheet href="style.css" type="text/css">
  5. </head>
  6. <body bgcolor=white text=black link="#5555ff" alink="#5555ff" vlink="#5555ff">
  7. <table border=0 width=100%>
  8. <tr>
  9. <td><p class=tiny>Vorbisfile documentation</p></td>
  10. <td align=right><p class=tiny>vorbisfile version 1.2.0 - 20070723</p></td>
  11. </tr>
  12. </table>
  13. <h1>ov_time_seek</h1>
  14. <p><i>declared in "vorbis/vorbisfile.h";</i></p>
  15. <p>For seekable
  16. streams, this seeks to the given time. For implementing seeking in a player,
  17. this is the only function generally needed. This also updates everything needed within the
  18. decoder, so you can immediately call <a href="ov_read.html">ov_read()</a> and get data from
  19. the newly seeked to position. This function does not work for unseekable streams.
  20. <br><br>
  21. <table border=0 color=black cellspacing=0 cellpadding=7>
  22. <tr bgcolor=#cccccc>
  23. <td>
  24. <pre><b>
  25. int ov_time_seek(<a href="OggVorbis_File.html">OggVorbis_File</a> *vf, double s);
  26. </b></pre>
  27. </td>
  28. </tr>
  29. </table>
  30. <h3>Parameters</h3>
  31. <dl>
  32. <dt><i>vf</i></dt>
  33. <dd>Pointer to our already opened and initialized OggVorbis_File structure.</dd>
  34. <dt><i>ms</i></dt>
  35. <dd>Location to seek to within the file, specified in seconds.</dd>
  36. </dl>
  37. <h3>Return Values</h3>
  38. <blockquote>
  39. <ul>
  40. <li>0 for success</li>
  41. <li>
  42. nonzero indicates failure, described by several error codes:
  43. <ul>
  44. <li>OV_ENOSEEK - Bitstream is not seekable.
  45. </li>
  46. <li>OV_EINVAL - Invalid argument value; possibly called with an OggVorbis_File structure that isn't open.
  47. </li>
  48. <li>OV_EREAD - A read from media returned an error.
  49. </li>
  50. <li>OV_EFAULT - Internal logic fault; indicates a bug or heap/stack
  51. corruption.
  52. </li>
  53. <li>OV_EBADLINK - Invalid stream section supplied to libvorbisfile, or the requested link is corrupt.
  54. </li>
  55. </ul></li>
  56. </ul></blockquote>
  57. <br><br>
  58. <hr noshade>
  59. <table border=0 width=100%>
  60. <tr valign=top>
  61. <td><p class=tiny>copyright &copy; 2007 Xiph.org</p></td>
  62. <td align=right><p class=tiny><a href="http://www.xiph.org/ogg/vorbis/">Ogg Vorbis</a></p></td>
  63. </tr><tr>
  64. <td><p class=tiny>Vorbisfile documentation</p></td>
  65. <td align=right><p class=tiny>vorbisfile version 1.2.0 - 20070723</p></td>
  66. </tr>
  67. </table>
  68. </body>
  69. </html>