home *** CD-ROM | disk | FTP | other *** search
/ RISCWORLD 7 / RISCWORLD_VOL7.iso / Software / Issue4 / SDL / gcc346 / !SDL / man / SDL_CDPlayTracks.3 < prev    next >
Encoding:
Text File  |  2006-09-20  |  2.3 KB  |  72 lines

  1. <!-- manual page source format generated by PolyglotMan v3.0.8+X.Org, -->
  2. <!-- available at http://polyglotman.sourceforge.net/ -->
  3.  
  4. <html>
  5. <head>
  6. <title>"SDL_CDPlayTracks"("3") manual page</title>
  7. </head>
  8. <body bgcolor='#efefef' text='black' link='blue' vlink='#551A8B' alink='red'>
  9. <a href='#toc'>Table of Contents</a><p>
  10.  
  11. <h2><a name='sect0' href='#toc0'>Name</a></h2>
  12. SDL_CDPlayTracks- Play the given CD track(s) 
  13. <h2><a name='sect1' href='#toc1'>Synopsis</a></h2>
  14. <p>
  15. <b>#include "SDL.h"
  16. <p>
  17. </b><b>int <b>SDL_CDPlayTracks</b></b>(<b>SDL_CD *cdrom, int start_track, int start_frame, int
  18. ntracks, int nframes)</b>); 
  19. <h2><a name='sect2' href='#toc2'>Description</a></h2>
  20. <p>
  21. <b>SDL_CDPlayTracks</b> plays the given CD
  22. starting at track <b>start_track</b>, for <b>ntracks</b> tracks.  <p>
  23. <b>start_frame</b> is the frame
  24. offset, from the beginning of the <b>start_track</b>, at which to start. <b>nframes</b>
  25. is the frame offset, from the beginning of the last track (<b>start_track</b>+<b>ntracks</b>),
  26. at which to end playing. <p>
  27. <b>SDL_CDPlayTracks</b> should only be called after calling
  28. <i><b>SDL_CDStatus</b></i> to get track information about the CD. <p>
  29. <blockquote><b>Note:   <p>
  30. Data tracks
  31. are ignored. </blockquote>
  32.  
  33. <h2><a name='sect3' href='#toc3'></b>Return Value</a></h2>
  34. <p>
  35. Returns <b>0</b>, or <b>-1</b> if there was an error. 
  36. <h2><a name='sect4' href='#toc4'>Examples</a></h2>
  37. <p>
  38. <p>
  39. <br>
  40. <pre>CW/* assuming cdrom is a previously opened device */
  41. /* Play the entire CD */
  42. if(CD_INDRIVE(SDL_CDStatus(cdrom)))
  43.   SDL_CDPlayTracks(cdrom, 0, 0, 0, 0);
  44. /* Play the first track */
  45. if(CD_INDRIVE(SDL_CDStatus(cdrom)))
  46.   SDL_CDPlayTracks(cdrom, 0, 0, 1, 0);
  47. /* Play first 15 seconds of the 2nd track */
  48. if(CD_INDRIVE(SDL_CDStatus(cdrom)))
  49.   SDL_CDPlayTracks(cdrom, 1, 0, 0, CD_FPS*15);
  50. </pre><p>
  51.  <br>
  52.  
  53. <h2><a name='sect5' href='#toc5'>See Also</a></h2>
  54. <p>
  55. <i><b>SDL_CDPlay</b></i>, <i><b>SDL_CDStatus</b></i>, <i><b>SDL_CD</b></i> 
  56. <!--
  57.   
  58.  <p>
  59.  
  60. <hr><p>
  61. <a name='toc'><b>Table of Contents</b></a><p>
  62. <ul>
  63. <li><a name='toc0' href='#sect0'>Name</a></li>
  64. <li><a name='toc1' href='#sect1'>Synopsis</a></li>
  65. <li><a name='toc2' href='#sect2'>Description</a></li>
  66. <li><a name='toc3' href='#sect3'>Return Value</a></li>
  67. <li><a name='toc4' href='#sect4'>Examples</a></li>
  68. <li><a name='toc5' href='#sect5'>See Also</a></li>
  69. </ul>
  70. </body>
  71. </html>
  72.