summaryrefslogtreecommitdiff
path: root/libs/ardour/bundle.cc
AgeCommit message (Collapse)Author
2017-08-29Compare bundle ports per-typeJulien "_FrnchFrgg_" RIVAUD
This addresses the XXX comment in Bundle::has_same_ports()
2017-08-29Make Bundle::disconnect() more robustJulien "_FrnchFrgg_" RIVAUD
Instead of asserting or crashing if the number of channels of both bundles don't match, just try to disconnect as much as possible.
2017-08-28Make Bundle::connected_to() optionally check for exclusivityJulien "_FrnchFrgg_" RIVAUD
If the new optional argument is true, then the first bundle will also check if it has other connections than to the given bundle.
2017-08-28Make Bundle::connected_to() able to check only a single DataTypeJulien "_FrnchFrgg_" RIVAUD
Also use the same iteration logic than in Bundle::connect to avoid mismatched port types.
2017-08-23Make Bundle::connect able to connect only some DataTypesJulien "_FrnchFrgg_" RIVAUD
When |allow_partial| is true, only when the number of channels of a given DataType is the same for both bundles are the corresponding channels connected together. When |allow_partial| is false (the default), the number of channels must match for each DataType (the ChanCounts must be equal) for the connection to be attempted. This also fixes the logic in case two bundles have the same number of channels, or even the same ChanCounts, but not with the DataTypes in the same order (so connecting the ith channel of the bundle to the ith channel of the other bundle makes no sense).
2017-08-23Improve getting a Bundle total channel countJulien "_FrnchFrgg_" RIVAUD
|Bundle::nchannels()| creates a ChanCount on demand, by iterating over the |_channel| member variable. The sum of all |nchannels().n(t)| over all non-NIL DataTypes |t| is thus equal to |_channel.size()|. Consequently, calling |nchannels().n_total()| is a convoluted (and slow) way of getting |_channel.size()|. Add a method |Bundle::n_total()| that directly returns the latter.
2016-07-14enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.hPaul Davis
2015-10-05NOOP, remove trailing tabs/whitespace.Robin Gareus
2014-11-14add abort() to non-reached codeRobin Gareus
This cleans up a lot of false-positives in static analysis and also helps compilers to optimize code paths in general. (tagging the fatal stingstream operator as ‘noreturn’ is far less trivial)
2013-08-09remove another naming that refers to JACKPaul Davis
2013-08-01full compilation and linking (coding not finished, will not run)Paul Davis
2013-07-30remove compile errors (still will not link and JACKPortEngine is not close ↵Paul Davis
to done)
2013-07-24part-way through getting the audioengine changes to compilePaul Davis
2013-07-10amend to 212d2ac5d (port add/remove signals)Robin Gareus
fix deadlock when updating audio/midi connection matrix during session-close or on exit. (Note: this still can cause a crash if the route goes away while the iterator in the connection-matrix still has an index of it)
2013-07-10fix [some] issues when adding/removing output portsRobin Gareus
2012-07-25convert from Glib:: to Glib::Threads for all thread-related APIPaul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@13084 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-24Remove over 500 unnecessary includes (including 54 of session.h).David Robillard
It's slightly possible that this causes trivial build failures on different configurations, but otherwise shouldn't cause any problems (i.e. no actual changes other than include/naming/namespace stuff). I deliberately avoided removing libardour-config.h since this can mysteriously break things, though a few of those do seem to be unnecessary. This commit only targets includes of ardour/*.h. There is also a very large number of unnecessary includes of stuff in gtk2_ardour; tackling that should also give a big improvement in build time when things are modified. git-svn-id: svn://localhost/ardour2/branches/3.0@12420 d708f5d6-7413-0410-9779-e7cbd77b26cf
2012-05-21Slightly hacky improvement to embolden the labels ofCarl Hetherington
connection matrix tabs when they have connections. git-svn-id: svn://localhost/ardour2/branches/3.0@12371 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-11-08Fix a few SNAFUs in the port matrix related to multi-type bundles (#4454).Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@10494 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-11-08Attempt to fix some confusions caused by bundles containingCarl Hetherington
different types of port; if we loop over N MIDI channels of a mixed bundle, for example, we must convert 0...N to the indices of the channels within the bundle. Also remove the hack of creating new bundles to contain a subset of another bundle's ports; if you do this, any signals emitted by the other bundle are ignored. Should fix #4454. git-svn-id: svn://localhost/ardour2/branches/3.0@10490 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-11-03Don't offer inputs to things as possible output connections, and vice versa ↵Carl Hetherington
(part of #4432). git-svn-id: svn://localhost/ardour2/branches/3.0@10410 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-10-28Use shared_ptr for Port in the AudioEngine; improves thread-safety of the ↵Carl Hetherington
audio engine's port list as a writer cannot destroy a port in one thread while the port list is being iterated in another. git-svn-id: svn://localhost/ardour2/branches/3.0@10327 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-06-01Fix broken whitespace. I'd apologize for the compile times if it was my ↵David Robillard
fault :D git-svn-id: svn://localhost/ardour2/branches/3.0@9654 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-01-29Add operator<< for bundles.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@8606 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-07-30Put Mackie surface ports into the Ardour tab of the port matrix.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7522 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-07-29Don't display empty tabs in the port matrix.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@7521 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-06-30Basic tweaks to make the bundles and the port matrix accept that MIDI tracks ↵Carl Hetherington
may have audio IO, and vice versa. Allows connection of instrument tracks using the global port matrix. git-svn-id: svn://localhost/ardour2/branches/3.0@7335 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-11-10Various adjustments to user bundle handling, with the general aim of ↵Carl Hetherington
allowing the user to create meaningful bundles with respect to their sound card an outboard setup, and having those user bundles take priority over ardour-generated ones. git-svn-id: svn://localhost/ardour2/branches/3.0@6050 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-11-07Various tweaks to the bundle manager.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@6030 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-10-14Strip trailing whitespace and fix other whitespace errors (e.g. space/tab ↵David Robillard
mixing). Whitespace changes only. Vimmers, try let c_space_errors = 1 in your .vimrc to highlight this kind of stuff in red. I don't know the emacs equivalent... git-svn-id: svn://localhost/ardour2/branches/3.0@5773 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-05-12Remove most using declarations from header files.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@5069 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-25*** NEW CODING POLICY ***David Robillard
All #include statements that include a header that is a part of a library bundled with ardour MUST use quotes, not angle brackets. Do this: #include "ardour/types.h" NOT this: #include <ardour/types.h> Rationale: This is best practice in general, to ensure we include the local version and not the system version. That quotes mean "local" (in some sense) and angle brackets mean "system" (in some sense) is a ubiquitous convention and IIRC right in the C spec somewhere. More pragmatically, this is required by (my) waf (stuff) for dependencies to work correctly. That is: !!! FAILURE TO DO THIS CAN RESULT IN BROKEN BUILDS !!! Failure to comply is punishable by death by torture. :) P.S. It's not that dramatic in all cases, but this (in combination with some GCC flags specific to the include type) is the best way I have found to be absolutely 100% positive the local ones are being used (and we definitely want to be absolutely 100% positive on that one). git-svn-id: svn://localhost/ardour2/branches/3.0@4655 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-11Add connected_to ()Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@4527 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-09Fixes to bundle manager to make it vaguely usable.Carl Hetherington
Rework signal handling for bundles so that all changes should now be noticed by port matrices. git-svn-id: svn://localhost/ardour2/branches/3.0@4501 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-02Re-enable creation of stereo bundles for system IO, so that the mixer stripCarl Hetherington
connection menus for stereo tracks are populated again. Also enable disconnection via these menus. git-svn-id: svn://localhost/ardour2/branches/3.0@4481 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-01-27Make track sends etc. appear in the same bundle as the track. Tidy up ↵Carl Hetherington
bundle channel naming a bit. git-svn-id: svn://localhost/ardour2/branches/3.0@4448 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-01-24Gather all ardour: ports so that a few more things are found to put in the ↵Carl Hetherington
port matrix. git-svn-id: svn://localhost/ardour2/branches/3.0@4439 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-01-21Fix some confusion about relative / non-relative port names. Add some ↵Carl Hetherington
asserts to keep track of what is happening. git-svn-id: svn://localhost/ardour2/branches/3.0@4424 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-01-20New matrix-based editor for connections and bundles, based on thorwil's design.Carl Hetherington
Add Bundle Manager dialog. git-svn-id: svn://localhost/ardour2/branches/3.0@4415 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-01-14Make Bundles work a bit better. A few include optimisations.Carl Hetherington
git-svn-id: svn://localhost/ardour2/branches/3.0@4408 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-06-02rollback to 3428, before the mysterious removal of libs/* at 3431/3432Paul Davis
git-svn-id: svn://localhost/ardour2/branches/3.0@3435 d708f5d6-7413-0410-9779-e7cbd77b26cf
2008-06-02remove empty sigc++2 directoryDoug McLain
git-svn-id: svn://localhost/ardour2/branches/3.0@3432 d708f5d6-7413-0410-9779-e7cbd77b26cf
2007-05-18Rename ARDOUR::Connection to ARDOUR::Bundle, a few minor cleanups along the way.Carl Hetherington
git-svn-id: svn://localhost/ardour2/trunk@1882 d708f5d6-7413-0410-9779-e7cbd77b26cf