root/branches/libfreebob-2.0/src/libstreaming/AmdtpPort.h

Revision 207, 2.5 kB (checked in by pieterpalmers, 18 years ago)

- temp commit

Line 
1 /* $Id$ */
2
3 /*
4  *   FreeBob Streaming API
5  *   FreeBob = Firewire (pro-)audio for linux
6  *
7  *   http://freebob.sf.net
8  *
9  *   Copyright (C) 2005,2006 Pieter Palmers <pieterpalmers@users.sourceforge.net>
10  *
11  *   This program is free software {} you can redistribute it and/or modify
12  *   it under the terms of the GNU General Public License as published by
13  *   the Free Software Foundation {} either version 2 of the License, or
14  *   (at your option) any later version.
15  *
16  *   This program is distributed in the hope that it will be useful,
17  *   but WITHOUT ANY WARRANTY {} without even the implied warranty of
18  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19  *   GNU General Public License for more details.
20  *
21  *   You should have received a copy of the GNU General Public License
22  *   along with this program {} if not, write to the Free Software
23  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
24  *
25  *
26  *
27  */
28 #ifndef __FREEBOB_AMDTPPORT__
29 #define __FREEBOB_AMDTPPORT__
30
31 /**
32  * This file implements the AMDTP ports as used in the BeBoB's
33  */
34
35 #include "../debugmodule/debugmodule.h"
36 #include "Port.h"
37 #include "AmdtpPortInfo.h"
38
39 namespace FreebobStreaming {
40
41 class AmdtpAudioPort
42         : public AudioPort, public AmdtpPortInfo
43 {
44
45 public:
46
47         AmdtpAudioPort(std::string name,
48                            enum E_DataType datatype,
49                            enum E_BufferType buffertype,
50                            int buffsize,
51                            int position,
52                            int location,
53                            int format,
54                            int type)
55         : AudioPort(name, datatype,     buffertype, buffsize),
56           AmdtpPortInfo(name, position, location, format, type)
57         {};
58
59         AmdtpAudioPort(std::string name,
60                            enum E_DataType datatype,
61                            enum E_BufferType buffertype,
62                            int buffsize,
63                        void *externalbuffer,
64                            int position,
65                            int location,
66                            int format,
67                            int type)
68         : AudioPort(name, datatype,     buffertype, buffsize, externalbuffer),
69           AmdtpPortInfo(name, position, location, format, type)
70         {};
71
72         virtual ~AmdtpAudioPort();
73
74 protected:
75     DECLARE_DEBUG_MODULE;
76
77 };
78
79 class AmdtpMidiPort
80         : public MidiPort, public AmdtpPortInfo
81 {
82
83 public:
84
85         AmdtpMidiPort(std::string name,
86                            int buffsize,
87                            int position,
88                            int location,
89                            int format,
90                            int type)
91         : MidiPort(name, buffsize),
92           AmdtpPortInfo(name, position, location, format, type)
93         {};
94
95         virtual ~AmdtpMidiPort();
96
97 protected:
98     DECLARE_DEBUG_MODULE;
99
100 };
101
102 } // end of namespace FreebobStreaming
103
104 #endif /* __FREEBOB_AMDTPPORT__ */
105
106
Note: See TracBrowser for help on using the browser.