ov_test.html 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <html>
  2. <head>
  3. <title>Tremor - function - ov_test</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>Tremor documentation</p></td>
  10. <td align=right><p class=tiny>Tremor version 1.0 - 20020403</p></td>
  11. </tr>
  12. </table>
  13. <h1>ov_test</h1>
  14. <p><i>declared in "ivorbisfile.h";</i></p>
  15. <p>
  16. This partially opens a vorbis file to test for Vorbis-ness. It loads
  17. the headers for the first chain, and tests for seekability (but does not seek).
  18. Use <a href="ov_test_open.html">ov_test_open()</a> to finish opening the file
  19. or <a href="ov_clear.html">ov_clear</a> to close/free it.
  20. <p>
  21. <table border=0 color=black cellspacing=0 cellpadding=7>
  22. <tr bgcolor=#cccccc>
  23. <td>
  24. <pre><b>
  25. int ov_test(FILE *f,<a href="OggVorbis_File.html">OggVorbis_File</a> *vf,char *initial,long ibytes);
  26. </b></pre>
  27. </td>
  28. </tr>
  29. </table>
  30. <h3>Parameters</h3>
  31. <dl>
  32. <dt><i>f</i></dt>
  33. <dd>File pointer to an already opened file
  34. or pipe (it need not be seekable--though this obviously restricts what
  35. can be done with the bitstream).</dd>
  36. <dt><i>vf</i></dt>
  37. <dd>A pointer to the OggVorbis_File structure--this is used for ALL the externally visible libvorbisidec
  38. functions. Once this has been called, the same <tt>OggVorbis_File</tt>
  39. struct should be passed to all the libvorbisidec functions.</dd>
  40. <dt><i>initial</i></dt>
  41. <dd>Typically set to NULL. This parameter is useful if some data has already been
  42. read from the file and the stream is not seekable. It is used in conjunction with <tt>ibytes</tt>. In this case, <tt>initial</tt>
  43. should be a pointer to a buffer containing the data read.</dd>
  44. <dt><i>ibytes</i></dt>
  45. <dd>Typically set to 0. This parameter is useful if some data has already been
  46. read from the file and the stream is not seekable. In this case, <tt>ibytes</tt>
  47. should contain the length (in bytes) of the buffer. Used together with <tt>initial</tt></dd>
  48. </dl>
  49. <h3>Return Values</h3>
  50. <blockquote>
  51. <li>0 for success</li>
  52. <li>less than zero for failure:</li>
  53. <ul>
  54. <li>OV_EREAD - A read from media returned an error.</li>
  55. <li>OV_ENOTVORBIS - Bitstream is not Vorbis data.</li>
  56. <li>OV_EVERSION - Vorbis version mismatch.</li>
  57. <li>OV_EBADHEADER - Invalid Vorbis bitstream header.</li>
  58. <li>OV_EFAULT - Internal logic fault; indicates a bug or heap/stack corruption.</li>
  59. </ul>
  60. </blockquote>
  61. <p>
  62. <br><br>
  63. <hr noshade>
  64. <table border=0 width=100%>
  65. <tr valign=top>
  66. <td><p class=tiny>copyright &copy; 2002 Xiph.org</p></td>
  67. <td align=right><p class=tiny><a href="http://www.xiph.org/ogg/vorbis/">Ogg Vorbis</a></p></td>
  68. </tr><tr>
  69. <td><p class=tiny>Tremor documentation</p></td>
  70. <td align=right><p class=tiny>Tremor version 1.0 - 20020403</p></td>
  71. </tr>
  72. </table>
  73. </body>
  74. </html>