2 Copyright (C) 2001 Paul Davis
3 Copyright (C) 2004-2006 Grame
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
25 #include "JackConstants.h"
30 #define ALL_PORTS 0xFFFF
31 #define NO_PORT 0xFFFE
34 \brief Base class for port.
40 friend class JackGraphManager
;
44 enum JackPortFlags fFlags
;
45 char fName
[JACK_PORT_NAME_SIZE
+ 2];
48 jack_nframes_t fLatency
;
49 uint8_t fMonitorRequests
;
53 jack_port_id_t fTied
; // Locally tied source port
55 float fBuffer
[BUFFER_SIZE_MAX
];
59 static void MixBuffer(float* mixbuffer
, float* buffer
, jack_nframes_t frames
);
66 void Allocate(int refnum
, const char* port_name
, JackPortFlags flags
);
68 const char* GetName() const;
69 const char* GetShortName() const;
70 int SetName(const char * name
);
73 const char* Type() const;
78 int Tie(jack_port_id_t port_index
);
81 jack_nframes_t
GetLatency() const;
82 void SetLatency(jack_nframes_t latency
);
84 int RequestMonitor(bool onoff
);
85 int EnsureMonitor(bool onoff
);
86 bool MonitoringInput();
89 int GetRefNum() const;