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 109 110 111 112 113 114 115 116
|
<html>
<head>
<title>Camstream: CamStream API documentation</title>
<link rel="stylesheet" href="../../tech.css" type="text/css">
</head>
<body>
<!-- Generated by Doxygen 1.3.7 -->
<div class="qindex"><a class="qindex" href="index.html">Main Page</a> | <a class="qindex" href="hierarchy.html">Class Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical List</a> | <a class="qindex" href="annotated.html">Class List</a> | <a class="qindex" href="files.html">File List</a> | <a class="qindex" href="functions.html">Class Members</a> | <a class="qindex" href="globals.html">File Members</a></div>
<h1>SoundAttributes.h</h1><a href="_sound_attributes_8h.html">Go to the documentation of this file.</a><pre class="fragment"><div>00001 <span class="comment">/* audiodevs: Abstraction layer for audio hardware & samples</span>
00002 <span class="comment"> Copyright (C) 2003-2004 Nemosoft Unv.</span>
00003 <span class="comment"></span>
00004 <span class="comment"> This program is free software; you can redistribute it and/or modify</span>
00005 <span class="comment"> it under the terms of the GNU General Public License as published by</span>
00006 <span class="comment"> the Free Software Foundation; either version 2 of the License, or</span>
00007 <span class="comment"> (at your option) any later version.</span>
00008 <span class="comment"></span>
00009 <span class="comment"> This program is distributed in the hope that it will be useful,</span>
00010 <span class="comment"> but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
00011 <span class="comment"> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
00012 <span class="comment"> GNU General Public License for more details.</span>
00013 <span class="comment"></span>
00014 <span class="comment"> You should have received a copy of the GNU General Public License</span>
00015 <span class="comment"> along with this program; if not, write to the Free Software</span>
00016 <span class="comment"> Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</span>
00017 <span class="comment"></span>
00018 <span class="comment"> For questions, remarks, patches, etc. for this program, the author can be</span>
00019 <span class="comment"> reached at camstream@smcc.demon.nl.</span>
00020 <span class="comment">*/</span>
00021
00022 <span class="preprocessor">#ifndef SOUNDATTRS_H</span>
00023 <span class="preprocessor"></span><span class="preprocessor">#define SOUNDATTRS_H</span>
00024 <span class="preprocessor"></span>
00025 <span class="preprocessor">#include <sys/types.h></span>
00026
00027 <span class="preprocessor">#ifdef _WIN32</span>
00028 <span class="preprocessor"></span><span class="keyword">typedef</span> <span class="keywordtype">char</span> int8_t;
00029 <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> u_int8_t;
00030 <span class="keyword">typedef</span> __int16 int16_t;
00031 <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">short</span> u_int16_t;
00032 <span class="keyword">typedef</span> <span class="keywordtype">long</span> int32_t;
00033 <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> u_int32_t;
00034 <span class="preprocessor">#endif</span>
00035 <span class="preprocessor"></span>
<a name="l00036"></a><a class="code" href="struct_sound_attributes.html">00036</a> <span class="keyword">struct </span><a class="code" href="struct_sound_attributes.html">SoundAttributes</a>
00037 {
<a name="l00039"></a><a class="code" href="struct_sound_attributes.html#w28">00039</a> <span class="keyword">enum</span> <a class="code" href="struct_sound_attributes.html#w28">Format</a>
00040 {
00041 <a class="code" href="struct_sound_attributes.html#w28w0">Unknown</a>,
00042 <a class="code" href="struct_sound_attributes.html#w28w1">Signed8</a>,
00043 <a class="code" href="struct_sound_attributes.html#w28w2">Signed16</a>,
00044 <a class="code" href="struct_sound_attributes.html#w28w3">Signed24</a>,
00045 <a class="code" href="struct_sound_attributes.html#w28w4">Signed32</a>,
00046 <a class="code" href="struct_sound_attributes.html#w28w5">Unsigned8</a>,
00047 <a class="code" href="struct_sound_attributes.html#w28w6">Unsigned16</a>,
00048 <a class="code" href="struct_sound_attributes.html#w28w7">Unsigned24</a>,
00049 <a class="code" href="struct_sound_attributes.html#w28w8">Unsigned32</a>,
00050 <a class="code" href="struct_sound_attributes.html#w28w9">Float</a>,
00051 };
00052
<a name="l00054"></a><a class="code" href="struct_sound_attributes.html#w29">00054</a> <span class="keyword">enum</span> <a class="code" href="struct_sound_attributes.html#w29">Position</a>
00055 {
00056 <a class="code" href="struct_sound_attributes.html#w29w10">NotUsed</a> = -1,
00057 <a class="code" href="struct_sound_attributes.html#w29w11">Mono</a> = 32,
00058 <a class="code" href="struct_sound_attributes.html#w29w12">Left</a>,
00059 <a class="code" href="struct_sound_attributes.html#w29w13">Right</a>,
00060 <a class="code" href="struct_sound_attributes.html#w29w14">Center</a>,
00061 <a class="code" href="struct_sound_attributes.html#w29w15">LeftRear</a>,
00062 <a class="code" href="struct_sound_attributes.html#w29w16">RightRear</a>,
00063 <a class="code" href="struct_sound_attributes.html#w29w17">LFE</a>,
00064 <a class="code" href="struct_sound_attributes.html#w29w18">LeftCenter</a>,
00065 <a class="code" href="struct_sound_attributes.html#w29w19">RightCenter</a>,
00066 <a class="code" href="struct_sound_attributes.html#w29w20">Top</a>,
00067 <a class="code" href="struct_sound_attributes.html#w29w21">MaxPosition</a> = 64
00068 };
00069
<a name="l00071"></a><a class="code" href="struct_sound_attributes.html#w30">00071</a> <span class="keyword">enum</span> <a class="code" href="struct_sound_attributes.html#w30">Preset</a>
00072 {
00073 <a class="code" href="struct_sound_attributes.html#w30w22">Speech</a>,
00074 <a class="code" href="struct_sound_attributes.html#w30w23">Radio</a>,
00075 <a class="code" href="struct_sound_attributes.html#w30w24">CD</a>,
00076 <a class="code" href="struct_sound_attributes.html#w30w25">DAT</a>,
00077 <a class="code" href="struct_sound_attributes.html#w30w26">Dolby51</a>,
00078
00079 };
00080
<a name="l00081"></a><a class="code" href="struct_sound_attributes.html#w31">00081</a> <span class="keyword">enum</span> <a class="code" href="struct_sound_attributes.html#o2">Channels</a>
00082 {
00083 <a class="code" href="struct_sound_attributes.html#w31w27">MaxChannel</a> = 32
00084 };
00085
<a name="l00086"></a><a class="code" href="struct_sound_attributes.html#o0">00086</a> <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="struct_sound_attributes.html#o0">SampleRate</a>;
<a name="l00087"></a><a class="code" href="struct_sound_attributes.html#o1">00087</a> <a class="code" href="struct_sound_attributes.html#w28">Format</a> <a class="code" href="struct_sound_attributes.html#o1">SampleFormat</a>;
<a name="l00088"></a><a class="code" href="struct_sound_attributes.html#o2">00088</a> <span class="keywordtype">unsigned</span> <span class="keywordtype">short</span> <a class="code" href="struct_sound_attributes.html#o2">Channels</a>;
<a name="l00089"></a><a class="code" href="struct_sound_attributes.html#o3">00089</a> <a class="code" href="struct_sound_attributes.html#w29">Position</a> <a class="code" href="struct_sound_attributes.html#o3">ChannelPosition</a>[<a class="code" href="struct_sound_attributes.html#w31w27">MaxChannel</a>];
00090
00091 <a class="code" href="struct_sound_attributes.html#a0">SoundAttributes</a>();
00092
00093 <span class="keywordtype">void</span> <a class="code" href="struct_sound_attributes.html#a1">Reset</a>();
00094 <span class="keywordtype">void</span> <a class="code" href="struct_sound_attributes.html#a2">SetPreset</a>(Preset);
00095
00096 <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="struct_sound_attributes.html#a3">FormatWidth</a>() const;
00097 <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> BytesPerSample() const;
00098
00099 <span class="keywordtype">bool</span> operator ==(const <a class="code" href="struct_sound_attributes.html">SoundAttributes</a> &comp) const;
00100 <span class="keywordtype">bool</span> operator !=(const <a class="code" href="struct_sound_attributes.html">SoundAttributes</a> &comp) const;
00101
00102 static <a class="code" href="struct_sound_attributes.html">SoundAttributes</a> GetFormat(Preset fmt);
00103 };
00104
00105 #endif
</div></pre><hr size="1"><address style="align: right;"><small>Generated on Wed Dec 13 23:38:46 2006 for CamStream by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border=0 ></a> 1.3.7 </small></address>
</body>
</html>
|