summaryrefslogtreecommitdiff
path: root/opcodes/mp3in.xml
blob: b79b53f4c1a062eefc0d8a6709c800c4816fe547 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
<refentry id="mp3in">
<indexterm id="IndexMp3in"><primary>mp3in</primary></indexterm>
  <refentryinfo><title>Signal I/O:Signal Input</title></refentryinfo>
  <refmeta>
    <refentrytitle>mp3in</refentrytitle>
  </refmeta>

  <refnamediv>
    <refname>mp3in</refname>
    <refpurpose>
      Reads stereo audio data from an external MP3 file.
    </refpurpose>
  </refnamediv>

  <refsect1>
    <title>Description</title>
    <para>
      Reads stereo audio data from an external MP3 file.
    </para>
  </refsect1>

  <refsect1>
    <title>Syntax</title>
    <synopsis>ar1, ar2 <command>mp3in</command> ifilcod[, iskptim, iformat, iskipinit, ibufsize]</synopsis>
  </refsect1>

   <refsect1>
    <title>Initialization</title>
    <para>
      <emphasis>ifilcod</emphasis> -- integer or character-string
      denoting the source soundfile name. An integer denotes the file
      soundin.filcod ; a character-string (in double quotes, spaces
      permitted) gives the filename itself, optionally a full
      pathname. If not a full path, the named file is sought first in
      the current directory, then in that given by the environment
      variable <link linkend="CommandEnvironment"><citetitle>SSDIR</citetitle></link> (if defined) then by <link linkend="CommandEnvironment"><citetitle>SFDIR</citetitle></link>.
    </para>

    <para>
      <emphasis>iskptim</emphasis> (optional) -- time in seconds of input sound to be skipped. The default value is 0.
    </para>

    <para>
      <emphasis>iformat</emphasis> (optional) -- specifies the audio
      data file format:  currently not implemented and always defaults
      to stereo.
    </para>

    <para>
     <emphasis>iskipinit</emphasis> (optional) -- switches off all 
     initialisation if non zero (default =0).
    </para>

    <para>
     <emphasis>ibuffersize</emphasis> (optional) -- sets the internal buffer size
     for reading.  If the value is omitted, zero or negative it defaults to
     4096 bytes.
    </para>
  </refsect1>

 <refsect1>
    <title>Performance</title>
    <para>
      Reads stereo audio data from an external MP3 file. 
    </para>
  </refsect1>

  <refsect1>
    <title>Examples</title>
    <para>
      Here is an example of the mp3in opcode. It uses the file <ulink url="examples/mp3in.csd"><citetitle>mp3in.csd</citetitle></ulink>.

      <example>
        <title>Example of the mp3in opcode.</title>
        <para>See the sections <link linkend="UsingRealTime"><citetitle>Real-time Audio</citetitle></link> and <link linkend="CommandFlags"><citetitle>Command Line Flags</citetitle></link> for more information on using command line flags.</para>
          <xi:include href="examples-xml/mp3in.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
      </example>
    </para>
  </refsect1>

  <refsect1>
    <title>See Also</title>
    <para>
      <link linkend="diskin"><citetitle>diskin</citetitle></link>,
      <link linkend="ins"><citetitle>ins</citetitle></link>,
      <link linkend="in"><citetitle>in</citetitle></link>,
      <link linkend="inch"><citetitle>inh</citetitle></link>,
      <link linkend="inh"><citetitle>inh</citetitle></link>,
      <link linkend="ino"><citetitle>ino</citetitle></link>,
      <link linkend="inq"><citetitle>inq</citetitle></link>,
      <link linkend="mp3len"><citetitle>mp3len</citetitle></link>,
      <link linkend="soundin"><citetitle>soundin</citetitle></link>
     </para>
  </refsect1>
 
  <refsect1>
    <title>Credits</title>
    <para>
      <simplelist>
        <member>Author: &namejohn;</member>
        <member>Codemist Ltd</member>
        <member>2009</member>
      </simplelist>
    </para>
    <para>New in version 5.11</para>
  </refsect1>
</refentry>