Zrythm
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
port.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: © 2018-2023 Alexandros Theodotou <alex@zrythm.org>
2// SPDX-License-Identifier: LicenseRef-ZrythmLicense
3
11#ifndef __AUDIO_PORTS_H__
12#define __AUDIO_PORTS_H__
13
14#include "zrythm-config.h"
15
16#include <stdbool.h>
17
18#include "dsp/port_identifier.h"
19#include "plugins/lv2/lv2_evbuf.h"
20#include "utils/types.h"
21
22#include "zix/sem.h"
23#include <lilv/lilv.h>
24
25#ifdef HAVE_JACK
26# include "weak_libjack.h"
27#endif
28
29#ifdef HAVE_RTMIDI
30# include <rtmidi_c.h>
31#endif
32
33#ifdef HAVE_RTAUDIO
34# include <rtaudio_c.h>
35#endif
36
37typedef struct Plugin Plugin;
38typedef struct MidiEvents MidiEvents;
39typedef struct Fader Fader;
40typedef struct ZixRingImpl ZixRing;
41typedef struct WindowsMmeDevice WindowsMmeDevice;
42typedef struct Channel Channel;
43typedef struct AudioEngine AudioEngine;
44typedef struct Track Track;
45typedef struct PortConnection PortConnection;
46typedef struct TrackProcessor TrackProcessor;
48typedef struct RtMidiDevice RtMidiDevice;
49typedef struct RtAudioDevice RtAudioDevice;
50typedef struct AutomationTrack AutomationTrack;
51typedef struct TruePeakDsp TruePeakDsp;
52typedef struct ExtPort ExtPort;
53typedef struct AudioClip AudioClip;
54typedef struct ChannelSend ChannelSend;
55typedef struct Transport Transport;
58typedef enum PanAlgorithm PanAlgorithm;
59typedef enum PanLaw PanLaw;
60
67#define PORT_SCHEMA_VERSION 1
68#define STEREO_PORTS_SCHEMA_VERSION 1
69
70#define PORT_MAGIC 456861194
71#define IS_PORT(_p) (((Port *) (_p))->magic == PORT_MAGIC)
72#define IS_PORT_AND_NONNULL(x) ((x) && IS_PORT (x))
73
74#define TIME_TO_RESET_PEAK 4800000
75
80#define PORT_NOT_OWNED -1
81
82#define port_is_owner_active(self, _owner_type, owner) \
83 ((self->id.owner_type == _owner_type) \
84 && (self->owner != NULL) \
85 && owner##_is_in_active_project (self->owner))
86
87#define port_is_in_active_project(self) \
88 (port_is_owner_active ( \
89 self, PORT_OWNER_TYPE_AUDIO_ENGINE, engine) \
90 || port_is_owner_active ( \
91 self, PORT_OWNER_TYPE_PLUGIN, plugin) \
92 || port_is_owner_active ( \
93 self, PORT_OWNER_TYPE_TRACK, track) \
94 || port_is_owner_active ( \
95 self, PORT_OWNER_TYPE_CHANNEL, track) \
96 || port_is_owner_active ( \
97 self, PORT_OWNER_TYPE_FADER, fader) \
98 || port_is_owner_active ( \
99 self, PORT_OWNER_TYPE_CHANNEL_SEND, channel_send) \
100 || port_is_owner_active ( \
101 self, PORT_OWNER_TYPE_TRACK_PROCESSOR, track) \
102 || port_is_owner_active ( \
103 self, PORT_OWNER_TYPE_MODULATOR_MACRO_PROCESSOR, \
104 modulator_macro_processor) \
105 || port_is_owner_active ( \
106 self, PORT_OWNER_TYPE_HW, ext_port))
107
127
131typedef struct PortScalePoint
132{
133 float val;
134 char * label;
136
137PURE int
138port_scale_point_cmp (const void * _a, const void * _b);
139
140NONNULL PortScalePoint *
141port_scale_point_new (const float val, const char * label);
142
143NONNULL void
144port_scale_point_free (PortScalePoint * self);
145
149typedef struct Port
150{
151 int schema_version;
152
154
160
167 float * buf;
168
173
176 struct Port ** srcs;
177 int num_srcs;
178 size_t srcs_size;
179
182 struct Port ** dests;
183 int num_dests;
184 size_t dests_size;
185
189 int num_src_connections;
190 size_t src_connections_size;
191
195 int num_dest_connections;
196 size_t dest_connections_size;
197
203
211 float minf;
212 float maxf;
213
221 float zerof;
222
224 float deff;
225
229
238 void * data;
239
240#ifdef _WOE32
249 WindowsMmeDevice * mme_connections[40];
250 int num_mme_connections;
251#else
252 void * mme_connections[40];
253 int num_mme_connections;
254#endif
255
259
267
268#ifdef HAVE_RTMIDI
275 RtMidiDevice * rtmidi_ins[128];
276 int num_rtmidi_ins;
277
279 RtMidiDevice * rtmidi_outs[128];
280 int num_rtmidi_outs;
281#else
282 void * rtmidi_ins[128];
283 int num_rtmidi_ins;
284 void * rtmidi_outs[128];
285 int num_rtmidi_outs;
286#endif
287
288#ifdef HAVE_RTAUDIO
294 RtAudioDevice * rtaudio_ins[128];
295 int num_rtaudio_ins;
296#else
297 void * rtaudio_ins[128];
298 int num_rtaudio_ins;
299#endif
300
303 int num_scale_points;
304
316 float control;
317
320
324
332
335
338
341
344
347
355
359
360 /* ====== flags to indicate port owner ====== */
361
368
371
381
390
399
402
412
415 volatile int has_midi_events;
416
420
431 ZixRing * audio_ring;
432
446 ZixRing * midi_ring;
447
450 float peak;
451
454
464
465 /* --- ported from Lv2Port --- */
466
468 const LilvPort * lilv_port;
469
472 LV2_URID value_type;
473
475 LV2_Evbuf * evbuf;
476
483
491
495
506
517
520
523
524 /* --- end Lv2Port --- */
525
532
535
538 int magic;
539
543} Port;
544
545static const cyaml_schema_field_t port_fields_schema[] = {
546 YAML_FIELD_INT (Port, schema_version),
548 Port,
549 id,
550 port_identifier_fields_schema),
551 YAML_FIELD_INT (Port, exposed_to_backend),
552 YAML_FIELD_FLOAT (Port, control),
553 YAML_FIELD_FLOAT (Port, minf),
554 YAML_FIELD_FLOAT (Port, maxf),
555 YAML_FIELD_FLOAT (Port, zerof),
556 YAML_FIELD_FLOAT (Port, deff),
557 YAML_FIELD_INT (Port, carla_param_id),
558
559 CYAML_FIELD_END
560};
561
562static const cyaml_schema_value_t port_schema = {
563 YAML_VALUE_PTR_NULLABLE (Port, port_fields_schema),
564};
565
571typedef struct StereoPorts
572{
573 int schema_version;
574 Port * l;
575 Port * r;
577
578static const cyaml_schema_field_t stereo_ports_fields_schema[] = {
579 YAML_FIELD_INT (StereoPorts, schema_version),
580 YAML_FIELD_MAPPING_PTR (StereoPorts, l, port_fields_schema),
581 YAML_FIELD_MAPPING_PTR (StereoPorts, r, port_fields_schema),
582
583 CYAML_FIELD_END
584};
585
586static const cyaml_schema_value_t stereo_ports_schema = {
587 YAML_VALUE_PTR (StereoPorts, stereo_ports_fields_schema),
588};
589
597NONNULL void
598port_init_loaded (Port * self, void * owner);
599
600void
601port_set_owner (
602 Port * self,
603 PortOwnerType owner_type,
604 void * owner);
605
606NONNULL Port *
607port_find_from_identifier (const PortIdentifier * const id);
608
609NONNULL static inline void
610stereo_ports_init_loaded (StereoPorts * sp, void * owner)
611{
612 port_init_loaded (sp->l, owner);
613 port_init_loaded (sp->r, owner);
614}
615
616NONNULL_ARGS (1)
617static inline void stereo_ports_set_owner (
618 StereoPorts * sp,
619 PortOwnerType owner_type,
620 void * owner)
621{
622 port_set_owner (sp->l, owner_type, owner);
623 port_set_owner (sp->r, owner_type, owner);
624}
625
629WARN_UNUSED_RESULT NONNULL Port *
631 PortType type,
632 PortFlow flow,
633 const char * label);
634
635WARN_UNUSED_RESULT NONNULL Port *
636port_new_with_type_and_owner (
637 PortType type,
638 PortFlow flow,
639 const char * label,
640 PortOwnerType owner_type,
641 void * owner);
642
649NONNULL void
651
658NONNULL void
660
664NONNULL StereoPorts *
666
676 int in,
677 const char * name,
678 const char * symbol,
679 PortOwnerType owner_type,
680 void * owner);
681
690NONNULL void
692 StereoPorts * src,
693 StereoPorts * dest,
694 int locked);
695
696NONNULL void
697stereo_ports_disconnect (StereoPorts * self);
698
700stereo_ports_clone (const StereoPorts * src);
701
702NONNULL void
703stereo_ports_free (StereoPorts * self);
704
713const void *
715 const char * port_sym,
716 void * user_data,
717 uint32_t * size,
718 uint32_t * type);
719
720#ifdef HAVE_JACK
725NONNULL void
726port_receive_midi_events_from_jack (
727 Port * self,
728 const nframes_t start_frames,
729 const nframes_t nframes);
730
735NONNULL void
736port_receive_audio_data_from_jack (
737 Port * self,
738 const nframes_t start_frames,
739 const nframes_t nframes);
740#endif
741
747NONNULL bool
749
755NONNULL void
756port_get_full_designation (Port * const self, char * buf);
757
758NONNULL void
759port_print_full_designation (Port * const self);
760
765void
766port_get_all (GPtrArray * ports);
767
768NONNULL Track *
769port_get_track (const Port * const self, int warn_if_fail);
770
771NONNULL Plugin *
772port_get_plugin (Port * const self, const bool warn_if_fail);
773
786void
788 Port * self,
789 const PortIdentifier * prev_id,
790 Track * track,
791 bool update_automation_track);
792
793#ifdef HAVE_RTMIDI
798NONNULL void
799port_prepare_rtmidi_events (Port * self);
800
805NONNULL void
806port_sum_data_from_rtmidi (
807 Port * self,
808 const nframes_t start_frame,
809 const nframes_t nframes);
810#endif
811
812#ifdef HAVE_RTAUDIO
817NONNULL void
818port_prepare_rtaudio_data (Port * self);
819
824NONNULL void
825port_sum_data_from_rtaudio (
826 Port * self,
827 const nframes_t start_frame,
828 const nframes_t nframes);
829#endif
830
834NONNULL void
836
844NONNULL void
845port_set_expose_to_backend (Port * self, int expose);
846
850NONNULL PURE static inline bool
851port_is_exposed_to_backend (const Port * self)
852{
853 return self->internal_type == INTERNAL_JACK_PORT
855 || self->id.owner_type == PORT_OWNER_TYPE_AUDIO_ENGINE
856 || self->exposed_to_backend;
857}
858
862NONNULL void
864
865#ifdef HAVE_ALSA
866
871Port *
872port_find_by_alsa_seq_id (const int id);
873#endif
874
892NONNULL void
894 Port * self,
895 const float val,
896 const bool is_normalized,
897 const bool forward_event);
898
906NONNULL HOT float
907port_get_control_value (Port * self, const bool normalize);
908
915#define port_connect(a, b, locked) \
916 port_connections_manager_ensure_connect ( \
917 PORT_CONNECTIONS_MGR, &((a)->id), &((b)->id), 1.f, \
918 locked, true)
919
923#define port_disconnect(a, b) \
924 port_connections_manager_ensure_disconnect ( \
925 PORT_CONNECTIONS_MGR, &((a)->id), &((b)->id))
926
931NONNULL int
933
938NONNULL int
940
948void
950 Port * self,
951 Track * track,
952 unsigned int new_hash);
953
961NONNULL static inline void
962port_apply_fader (
963 Port * port,
964 float amp,
965 nframes_t start_frame,
966 const nframes_t nframes)
967{
968 nframes_t end = start_frame + nframes;
969 while (start_frame < end)
970 {
971 port->buf[start_frame++] *= amp;
972 }
973}
974
982HOT NONNULL void
984 Port * port,
985 const EngineProcessTimeInfo time_nfo,
986 const bool noroll);
987
988#define ports_connected(a, b) \
989 (port_connections_manager_find_connection ( \
990 PORT_CONNECTIONS_MGR, &(a)->id, &(b)->id) \
991 != NULL)
992
998NONNULL bool
999ports_can_be_connected (const Port * src, const Port * dest);
1000
1004NONNULL void
1005ports_disconnect (Port ** ports, int num_ports, int deleting);
1006
1014NONNULL void
1016 Port * self,
1017 Port * project_port);
1018
1026NONNULL void
1027port_copy_values (Port * self, const Port * other);
1028
1039NONNULL void
1041
1048#define port_clear_buffer(_port) \
1049 { \
1050 if (_port->id.type == TYPE_AUDIO || _port->id.type == TYPE_CV) \
1051 { \
1052 if (_port->buf) \
1053 { \
1054 dsp_fill ( \
1055 _port->buf, DENORMAL_PREVENTION_VAL, \
1056 AUDIO_ENGINE->block_length); \
1057 } \
1058 } \
1059 else if (_port->id.type == TYPE_EVENT) \
1060 { \
1061 if (_port->midi_events) \
1062 _port->midi_events->num_events = 0; \
1063 } \
1064 }
1065
1069HOT NONNULL OPTIMIZE_O3 void
1071
1075NONNULL int
1077
1081NONNULL void
1083 Port * l,
1084 Port * r,
1085 float pan,
1086 PanLaw pan_law,
1087 PanAlgorithm pan_algo);
1088
1096NONNULL void
1098 Port * port,
1099 float pan,
1100 PanLaw pan_law,
1101 PanAlgorithm pan_algo,
1102 nframes_t start_frame,
1103 const nframes_t nframes);
1104
1108NONNULL uint32_t
1109port_get_hash (const void * ptr);
1110
1114Port *
1115port_clone (const Port * src);
1116
1120NONNULL void
1122
1127#endif
NONNULL void port_init_loaded(Port *self, void *owner)
This function finds the Ports corresponding to the PortIdentifiers for srcs and dests.
NONNULL void port_set_expose_to_backend(Port *self, int expose)
Sets whether to expose the port to the backend and exposes it or removes it.
NONNULL int port_disconnect_all(Port *port)
Disconnects all srcs and dests from port.
NONNULL bool ports_can_be_connected(const Port *src, const Port *dest)
Returns whether the Port's can be connected (if the connection will be valid and won't break the acyc...
HOT NONNULL OPTIMIZE_O3 void port_clear_external_buffer(Port *port)
Clears the backend's port buffer.
NONNULL void port_copy_values(Port *self, const Port *other)
Copies the port values from other to self.
NONNULL void port_apply_pan(Port *port, float pan, PanLaw pan_law, PanAlgorithm pan_algo, nframes_t start_frame, const nframes_t nframes)
Applies the pan to the given port.
NONNULL int port_get_num_unlocked_srcs(const Port *self)
Returns the number of unlocked (user-editable) sources.
HOT NONNULL void port_process(Port *port, const EngineProcessTimeInfo time_nfo, const bool noroll)
First sets port buf to 0, then sums the given port signal from its inputs.
NONNULL StereoPorts * stereo_ports_new_from_existing(Port *l, Port *r)
Creates blank stereo ports.
void port_update_identifier(Port *self, const PortIdentifier *prev_id, Track *track, bool update_automation_track)
To be called when the port's identifier changes to update corresponding identifiers.
Port * port_clone(const Port *src)
To be used during serialization.
PortType
Type of signals the Port handles.
void port_get_all(GPtrArray *ports)
Gathers all ports in the project and appends them in the given array.
NONNULL void port_apply_pan_stereo(Port *l, Port *r, float pan, PanLaw pan_law, PanAlgorithm pan_algo)
Applies the pan to the given L/R ports.
NONNULL void stereo_ports_connect(StereoPorts *src, StereoPorts *dest, int locked)
Connects the internal ports using port_connect().
PortFlow
Direction of the signal.
PortInternalType
What the internal data is.
Definition port.h:112
NONNULL void port_allocate_bufs(Port *self)
Allocates buffers used during DSP.
NONNULL void port_free_bufs(Port *self)
Frees buffers.
void port_update_track_name_hash(Port *self, Track *track, unsigned int new_hash)
Updates the track name hash on a track port and all its source/destination identifiers.
StereoPorts * stereo_ports_new_generic(int in, const char *name, const char *symbol, PortOwnerType owner_type, void *owner)
Creates stereo ports for generic use.
NONNULL void ports_disconnect(Port **ports, int num_ports, int deleting)
Disconnects all the given ports.
NONNULL void port_restore_from_non_project(Port *self, Port *non_project)
Reverts the data on the corresponding project port for the given non-project port.
PortOwnerType
Type of owner.
NONNULL HOT float port_get_control_value(Port *self, const bool normalize)
Gets the given control value from the corresponding underlying structure in the Port.
NONNULL void port_get_full_designation(Port *const self, char *buf)
Copies a full designation of self in the format "Track/Port" or "Track/Plugin/Port" in buf.
NONNULL bool port_has_sound(Port *self)
If MIDI port, returns if there are any events, if audio port, returns if there is sound in the buffer...
NONNULL void port_copy_metadata_from_project(Port *self, Port *project_port)
Copies the metadata from a project port to the given port.
NONNULL void port_rename_backend(Port *self)
Renames the port on the backend side.
NONNULL void port_free(Port *port)
Deletes port, doing required cleanup and updating counters.
NONNULL int port_get_num_unlocked_dests(const Port *self)
Returns the number of unlocked (user-editable) destinations.
COLD NONNULL_ARGS(1) void automation_track_init_loaded(AutomationTrack *self
Inits a loaded AutomationTracklist.
const void * port_get_value_from_symbol(const char *port_sym, void *user_data, uint32_t *size, uint32_t *type)
Function to get a port's value from its string symbol.
NONNULL void port_disconnect_hw_inputs(Port *self)
Disconnects all hardware inputs from the port.
NONNULL void port_set_control_value(Port *self, const float val, const bool is_normalized, const bool forward_event)
Sets the given control value to the corresponding underlying structure in the Port.
WARN_UNUSED_RESULT NONNULL Port * port_new_with_type(PortType type, PortFlow flow, const char *label)
Creates port.
NONNULL uint32_t port_get_hash(const void *ptr)
Generates a hash for a given port.
@ INTERNAL_PA_PORT
TODO.
Definition port.h:122
@ INTERNAL_LV2_PORT
Pointer to Lv2Port.
Definition port.h:116
@ INTERNAL_JACK_PORT
Pointer to jack_port_t.
Definition port.h:119
@ INTERNAL_ALSA_SEQ_PORT
Pointer to snd_seq_port_info_t.
Definition port.h:125
#define YAML_FIELD_MAPPING_EMBEDDED(owner, member, schema)
Mapping embedded inside the struct.
Definition yaml.h:32
uint32_t nframes_t
Frame count.
Definition types.h:34
uint8_t midi_byte_t
MIDI byte.
Definition types.h:31
#define YAML_FIELD_MAPPING_PTR(owner, member, schema)
Mapping pointer to a struct.
Definition yaml.h:39
#define YAML_VALUE_PTR(cc, fields_schema)
Schema to be used as a pointer.
Definition yaml.h:221
#define YAML_VALUE_PTR_NULLABLE(cc, fields_schema)
Schema to be used as a pointer that can be NULL.
Definition yaml.h:228
PanAlgorithm
See https://www.harmonycentral.com/articles/the-truth-about-panning-laws.
Definition pan.h:52
PanLaw
These are only useful when changing mono to stereo.
Definition pan.h:29
Port identifier.
Audio clips for the pool.
Definition clip.h:33
The audio engine.
Definition engine.h:375
Channel send.
A Channel is part of a Track (excluding Tracks that don't have Channels) and contains information rel...
Definition channel.h:63
Common struct to pass around during processing to avoid repeating the data in function arguments.
Definition types.h:140
External port.
Definition ext_port.h:78
A Fader is a processor that is used for volume controls and pan.
Definition fader.h:118
Container for passing midi events through ports.
Definition midi_event.h:68
Modulator macro button processor.
Widget for a control.
Definition plugin_gtk.h:27
The base plugin Inheriting plugins must have this as a child.
Definition plugin.h:72
A connection between two ports.
Struct used to identify Ports in the project.
PortOwnerType owner_type
Owner type.
Scale point.
Definition port.h:132
Must ONLY be created via port_new()
Definition port.h:150
int initialized
used when loading projects FIXME needed?
Definition port.h:370
int exposed_to_backend
Flag to indicate that this port is exposed to the backend.
Definition port.h:159
ExtPort * ext_port
Pointer to ExtPort, if hw.
Definition port.h:534
ZixRing * midi_ring
Ring buffer for saving MIDI events to be used in the UI instead of directly accessing the events.
Definition port.h:446
float minf
Minimum, maximum and zero values for this port.
Definition port.h:211
ZixSem mme_connections_sem
Semaphore for changing the connections atomically.
Definition port.h:258
gint64 last_midi_event_time
Used by the UI to detect when unprocessed MIDI events exist.
Definition port.h:419
int magic
Magic number to identify that this is a Port.
Definition port.h:538
midi_byte_t last_midi_status
Last known MIDI status byte received.
Definition port.h:463
AudioEngine * engine
Pointer to owner engine, if any.
Definition port.h:343
gint64 last_change
Last timestamp the control changed.
Definition port.h:331
float * buf
Buffer to be reallocated every time the buffer size changes.
Definition port.h:167
MidiEvents * midi_events
Contains raw MIDI data (MIDI ports only)
Definition port.h:172
PortInternalType internal_type
Indicates whether data or lv2_port should be used.
Definition port.h:202
const PortConnection ** dest_connections
Caches filled when recalculating the graph.
Definition port.h:194
Transport * transport
Pointer to owner transport, if any.
Definition port.h:337
float base_value
For control ports, when a modulator is attached to the port the previous value will be saved here.
Definition port.h:380
bool old_api
True for event, false for atom.
Definition port.h:522
size_t last_buf_sz
Last allocated buffer size (used for audio ports).
Definition port.h:542
ModulatorMacroProcessor * modulator_macro_processor
Pointer to owner modulator macro processor, if any.
Definition port.h:358
LV2_URID value_type
Float for LV2 control ports, declared type for LV2 parameters.
Definition port.h:472
ZixRing * audio_ring
Ring buffer for saving the contents of the audio buffer to be used in the UI instead of directly acce...
Definition port.h:431
float control
The control value if control port, otherwise 0.0f.
Definition port.h:316
AutomationTrack * at
Automation track this port is attached to.
Definition port.h:531
const PortConnection ** src_connections
Caches filled when recalculating the graph.
Definition port.h:188
gint64 last_midi_dequeue
Last time the port finished dequeueing MIDI events.
Definition port.h:266
Fader * fader
Pointer to owner fader, if any.
Definition port.h:346
volatile int has_midi_events
Whether the port has midi events not yet processed by the UI.
Definition port.h:415
ChannelSend * channel_send
Pointer to owner channel send, if any.
Definition port.h:340
size_t min_buf_size
Minimum buffer size that the port wants, or 0.
Definition port.h:490
long playback_latency
Playback latency.
Definition port.h:398
float unsnapped_control
Unsnapped value, used by widgets.
Definition port.h:319
Plugin * plugin
Pointer to owner plugin, if any.
Definition port.h:334
struct Port ** srcs
Caches filled when recalculating the graph.
Definition port.h:176
float zerof
The zero position of the port.
Definition port.h:221
int lilv_port_index
Port index in the lilv plugin, if non-parameter.
Definition port.h:494
struct Port ** dests
Caches filled when recalculating the graph.
Definition port.h:182
PluginGtkController * widget
Control widget, if applicable.
Definition port.h:482
bool received_ui_event
Whether the port received a UI event from the plugin UI in this cycle.
Definition port.h:505
const LilvPort * lilv_port
LV2 port.
Definition port.h:468
int carla_param_id
Index of the control parameter (for Carla plugin ports).
Definition port.h:228
bool write_ring_buffers
Flag to indicate if the ring buffers below should be filled or not.
Definition port.h:411
bool automating
Whether this value was set via automation.
Definition port.h:519
Plugin * tmp_plugin
Temporary plugin pointer (used when the plugin doesn't exist yet in its supposed slot).
Definition port.h:367
long capture_latency
Capture latency.
Definition port.h:389
float last_sent_control
The last known control value sent to the UI (if control).
Definition port.h:516
Track * track
Pointer to owner track, if any.
Definition port.h:354
LV2_Evbuf * evbuf
For MIDI ports, otherwise NULL.
Definition port.h:475
int deleting
Port undergoing deletion.
Definition port.h:401
float deff
Default value, only used for controls.
Definition port.h:224
gint64 peak_timestamp
Last time Port.max_amp was set.
Definition port.h:453
PortScalePoint ** scale_points
Scale points.
Definition port.h:302
bool value_changed_from_reading
Flag that the value of the port changed from reading automation.
Definition port.h:323
float peak
Max amplitude during processing, if audio (fabsf).
Definition port.h:450
void * data
Pointer to arbitrary data.
Definition port.h:238
L & R port, for convenience.
Definition port.h:572
A TrackProcessor is a processor that is used as the first entry point when processing a track.
Track to be inserted into the Project's Tracklist.
Definition track.h:193
The transport.
Definition transport.h:195
Custom types.