This situation occurs continuously when acting as Jack transport master, but
everything seems to work as expected, so we'll just assume it's fine until
proven otherwise.
git-svn-id: svn://localhost/ardour2/branches/3.0@14043 d708f5d6-7413-0410-9779-e7cbd77b26cf
This changes how things work a bit, but I am committing it for 3.0 since the
previous revision often crashed (and never worked), this one seems to work
fine, and the code is quite a bit more cogent.
I have tested the following use cases with live input and audible output:
* Non-loop recording, armed before roll
* Non-loop recording, arm while rolling
* Loop recording, armed before roll
* Loop recording, arm during roll
In the last case, the source/region is created starting at the loop start
rather than the current transport frame as usual so time makes sense when it
wraps around.
See the documentation added to the code for details, but the basic idea here is
to simply push MIDI events to the source with increasing monotonic time,
ignoring looping altogether. Essentially we pretend the loop does not exist,
but the source knows all the details so it can implement whatever behaviour is
appropriate.
Currently, this is simply recording a complete non-destructive copy of the
input, which is a good thing. Perhaps not what the user expects of loop
recording, but at least it works and is one sensible option. We will need to
add more later.
Display while recording is a little bit wacky, but whatever.
git-svn-id: svn://localhost/ardour2/branches/3.0@13940 d708f5d6-7413-0410-9779-e7cbd77b26cf
Previously, this calculation was based on the current transport frame and last
time, both absolute, with the effect that loop recording would flush the first
time and never again.
The fix is to keep track of the actual duration of the capture, ignoring the
transport position, and flush as that reaches the threshold.
git-svn-id: svn://localhost/ardour2/branches/3.0@13938 d708f5d6-7413-0410-9779-e7cbd77b26cf
Apologies for the noise, trying to dice a bunch of changes into reasonable commits...
git-svn-id: svn://localhost/ardour2/branches/3.0@13937 d708f5d6-7413-0410-9779-e7cbd77b26cf
Make midnam test suite pass again.
The Ardour test suite does not pass. I commented out old crossfade stuff, but
I am not familiar enough with the parts that fail to fix it. It might be a
good idea for someone to look into this. Ideally we'd have the test integrated
into everyone's workflow, but they add quite a few files to compile...
git-svn-id: svn://localhost/ardour2/branches/3.0@13931 d708f5d6-7413-0410-9779-e7cbd77b26cf
Completely eliminate static MIDI controller name code.
Reduce dependency on midnam_patch.h (which would have saved me several hours if I did it earlier).
Store controller name numbers as an integer.
Keep controller names in a map keyed by int instead of a list for fast lookup.
More cleanup of MIDI::Name code.
git-svn-id: svn://localhost/ardour2/branches/3.0@13927 d708f5d6-7413-0410-9779-e7cbd77b26cf
Use const references where appropriate.
Fix incorrect use of (either confusingly named or often abused) Patch tag Number attribute.
git-svn-id: svn://localhost/ardour2/branches/3.0@13923 d708f5d6-7413-0410-9779-e7cbd77b26cf
Support loading note names per ChannelNameSet (like GM) in addition to per Patch (like DM5).
git-svn-id: svn://localhost/ardour2/branches/3.0@13913 d708f5d6-7413-0410-9779-e7cbd77b26cf
Do this via a simple MasterDeviceNames::note_name() function. The same really
needs to be done for program names, this stuff is absolutely brutal to use.
Store note names in a vector indexed by number instead of a list with string
"numbers" for reasonable lookup time.
Make some references const that should be.
git-svn-id: svn://localhost/ardour2/branches/3.0@13908 d708f5d6-7413-0410-9779-e7cbd77b26cf
Give up trying to hide mode selector when it's useless.
Fix display of program names for default mode.
Abstract out (non-crashy) MidiTimeAxisView::get_device_names().
git-svn-id: svn://localhost/ardour2/branches/3.0@13903 d708f5d6-7413-0410-9779-e7cbd77b26cf
Accordingly, make "generic" MIDI truly generic, just numbered controllers.
Break up MIDI name UI stuff into manageable functions of reasonable size.
Add convenient method to MIDINameDocument for getting the names for a device.
Tolerate comments in MIDINameDocument ControlNameList.
Can't remove the MIDI name code just yet, since it's still erroneously used by
Automatable::describe_parameter(). This is the cause of a bug where the name
on the automation lane does not match that in the menu.
The plan is to make a very simple pure abstract interface for getting MIDI
names, and make it possible to set one for Automatable (or perhaps pass it to
describe_parameter()). Thus we'll be on the way to supporting names from
sources other than midnam files, namely plugins.
git-svn-id: svn://localhost/ardour2/branches/3.0@13895 d708f5d6-7413-0410-9779-e7cbd77b26cf
We really need some kind of more sophisticated assert macro that can be
switched to non-fatal logging mode for release builds. A log message, which is
often all that would happen, is a lot better than a trainwrecked performance...
git-svn-id: svn://localhost/ardour2/branches/3.0@13892 d708f5d6-7413-0410-9779-e7cbd77b26cf