root/trunk/libffado/src/libstreaming/motu/MotuPortInfo.h

Revision 742, 2.4 kB (checked in by ppalmers, 13 years ago)

- Remove some obsolete support files and dirs

- Clean up the license statements in the source files. Everything is

GPL version 3 now.

- Add license and copyright notices to scons scripts

- Clean up some other text files

Line 
1 /*
2  * Copyright (C) 2005-2007 by Jonathan Woithe
3  * Copyright (C) 2005-2007 by Pieter Palmers
4  *
5  * This file is part of FFADO
6  * FFADO = Free Firewire (pro-)audio drivers for linux
7  *
8  * FFADO is based upon FreeBoB.
9  *
10  * This program is free software: you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation, either version 3 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
22  *
23  */
24
25 #ifndef __FFADO_MOTUPORTINFO__
26 #define __FFADO_MOTUPORTINFO__
27
28 #include "debugmodule/debugmodule.h"
29 #include <string>
30
31 namespace Streaming {
32 /*!
33 \brief Class containing the stream information for a Motu channel
34
35  Contains the information that enables the decoding routine to find
36  this port's data in the ISO events
37
38 */
39 class MotuPortInfo {
40
41 public:
42     /**
43      * Sometimes a channel can have multiple formats, depending on the
44      * device configuration (e.g. an SPDIF port could be plain audio in 24bit integer
45      * or AC3 passthrough in IEC compliant frames.)
46      *
47      * This kind of enum allows to discriminate these formats when decoding
48      * If all channels always have the same format, you won't be needing this
49      */
50 //    enum E_Formats {
51 //        E_MBLA,     // Multibit linear audio
52 //        E_Midi,     // MIDI
53 //    };
54
55     /**
56      * Initialize Motu portinfo
57      * should not be called directly, is inherited by motu ports
58      *
59      * the position parameter is an example
60      * the name parameter is mandatory
61      *
62      * @param position Start position of port's data in iso event
63      * @param format Format of data in iso event
64      * @param size Size in bits of port's data in iso event
65      * @return
66      */
67     MotuPortInfo( int position, int size)
68       : m_position(position), m_size(size)
69     {};
70     virtual ~MotuPortInfo() {};
71
72
73     int getPosition()     {return m_position;};
74     int getSize()         {return m_size;};
75
76 protected:
77
78     int m_position;
79     int m_size;
80
81 };
82
83 } // end of namespace Streaming
84
85 #endif /* __FFADO_MOTUPORTINFO__ */
Note: See TracBrowser for help on using the browser.