13
0
Commit Graph

7727 Commits

Author SHA1 Message Date
17707b9674 fix some cast warnings 2014-12-10 18:13:12 -05:00
3e27a71c71 simpler approach for Apple setrlimit() compatibility issue 2014-12-10 15:59:11 -05:00
b91c7836de try some alternate, hard numbers when resetting open file limits on OS X 2014-12-10 15:27:32 -05:00
a0fcf2fc66 remove ugly and unnecessary debugging output 2014-12-10 13:37:03 -05:00
2f300085ea Use DEBUG_THREAD_SELF when using DEBUG_TRACE with pthread IDs
(supports both normal pthreads usage and PTW32)
2014-12-10 16:56:33 +00:00
635578b30b use correct conditional to choose between different DEBUG_THREAD_SELF macros 2014-12-10 11:07:18 -05:00
c06c15596b add DEBUG_THREAD_SELF to allow use of DEBUG_TRACE with thread IDs on both normal pthreads platforms and PTW32 2014-12-10 09:34:32 -05:00
e66752cec1 add set-session-extents-from-edit-range 2014-12-09 16:18:47 -06:00
1e0c1751a5 more DEBUG::Butler output, formatting corrections, and a warning on cerr if capture/playback buffers are too full/empty 2014-12-09 16:36:52 -05:00
724febc82c remove superfluous PBD/ARDOUR:: init calls
this reverts 339670b
2014-12-09 19:41:53 +01:00
8e44a0bff7 add DEBUG::Butler and use it 2014-12-09 10:18:29 -05:00
246a4f3018 correct install location for .mo files (i18n) and cleanup LOCALEDIR use a bit 2014-12-09 08:19:11 -05:00
624a86c39d lots more color work, closer and closer to being ready for ... being taken apart again 2014-12-08 22:02:38 -05:00
9ac7ddb31d remove all explicit button text colors; use contrasting_text_color() instead.
Also, use a slightly off-white rather than pure white, which should really be configurable
2014-12-07 13:55:40 -05:00
a81a79adce Add some newly introduced source files to our MSVC project (libardour) 2014-12-07 13:31:41 +00:00
bfbb0f6178 Add legatize and remove overlap MIDI operations.
We're going to need the ability to apply MIDI edit operations to a note/control
selection soon...
2014-12-06 23:42:11 -05:00
e1e2b919c3 Remove unnecessary includes. 2014-12-06 22:43:06 -05:00
eb86971d2d Invalidate iterator whenever model changes.
I suspect this is an underlying cause of several tricky to reproduce bugs, but
we'll have to wait around and see...
2014-12-06 22:43:06 -05:00
6f7ee67c71 midnam test: don't clutter up output. 2014-12-06 23:51:45 +01:00
60f4f5b9d8 Fix inappropriately massive flag font. 2014-12-06 16:07:32 -05:00
f9c74319a2 Fix seek in linearly interpolated control lists. 2014-12-06 15:44:10 -05:00
4650912ae3 Adapt range when copying between automation types.
For things like copying from pitch bender to a CC.

Also things like fader to pan, but that seems a bit funny.  The conversion
probably needs to be a bit smarter here, perhaps taking the normal into
consideration...
2014-12-06 13:40:35 -05:00
82be2325d9 Fix uninitialized members. 2014-12-06 12:06:48 -05:00
ddb7cc6d66 More potential SMF crash fixes. 2014-12-06 11:19:48 -05:00
2e92ae90a6 Possible half-fix for SMF crash. 2014-12-06 10:37:08 -05:00
9266e7524a experimental drawing optimization.
Q: is bounding_box(); etc more complex than queuing draw?

either way, canvas should eventually switch to
use an optimized OptimizingLookupTable.
2014-12-05 22:40:26 +01:00
587dc283ea Fix stuck faders on very fine adjustments.
I attempted to preserve the "don't draw unless different" by ditching rounding for more
precise display_span, but that didn't work.  An alternative solution would be
to draw on adjustment change if there's text, since then we need to redraw
regardless of slider position, but it seemed weird even just with respect to
the slider, so I opted for this, which really definitely redraws when the
adjustment changes, period.

If this proves to be a performance issue we'll have to figure that out.
2014-12-05 15:19:43 -05:00
fb406e5b36 fix small memory leak in the tests 2014-12-05 20:57:07 +01:00
8714fab1bc update to 'new' ControlList API
add (double when, double value, bool with_guards=true, bool with_default=true);
2014-12-05 20:57:07 +01:00
91d3e8ead0 if a Route's processor lock cannot be taken, fill buffers with silence (causing click) rather than abort() 2014-12-05 14:49:30 -05:00
cf3faf1b42 fix "expected" <> "actual" semantics in test-util 2014-12-05 18:32:16 +01:00
207fd04587 include alpha-delta computation in HSV::delta() 2014-12-05 09:01:55 -05:00
17ad6a5078 Add 'pbd/crossthread.cc' to the MSVC build 2014-12-05 08:40:47 +00:00
0bf778c847 Make recorded MIDI controls discrete, take 2.
Hopefully-desired behaviour is that controls created in the GUI are linear, so
clicking in stuff works like other automation, but controls that originated
from recording are set to discrete so Ardour plays back the input exactly,
instead of doing crazy things like linear interpolation of already high-rate
user input, hold pedals, and so on.

Hopefully that remains the desired behaviour, because we're basically screwed
for ever making any control discrete by default, since we only save the mode to
XML at all if it's not the default, which is currently linear.
2014-12-05 00:15:40 -05:00
ad340333f4 Revert "Create discrete lists for recorded MIDI controls."
This broke saving/restoring interpolation style.

This reverts commit 07a381a8f5.
2014-12-05 00:03:47 -05:00
124e54f01b Fix crash when twiddling MIDI controllers (#6050). 2014-12-04 22:23:16 -05:00
59af923b77 Fix steps for log controls with wide range. 2014-12-04 21:22:31 -05:00
55c4889c9a fix windows compilation 2014-12-04 17:13:43 +01:00
b996f07122 add required header 2014-12-04 11:05:33 -05:00
697c397f37 move WSAStartup() and WSACleanup() out of per-object methods into per-library init/cleanup methods 2014-12-04 10:07:11 -05:00
4e8dfda880 clean up whitespace 2014-12-04 09:11:46 -05:00
5f9e81b105 Include pbd/crossthread.cc in the mingw build 2014-12-04 16:16:06 +07:00
12acce0d0e Use correct name for windows.h 2014-12-04 16:15:07 +07:00
24727e65be Make gain controls step by roughly 1.0/0.1 dB.
Shoot for roughly 30 steps for all controls.

Always keep sensible step information in ParameterDescriptor and just convert
for the UI.

This is a little weird, but it's less weird than it was before, and works.
2014-12-04 00:30:47 -05:00
9b770c7aff actual expected test results:
We should not add an initial implicit value
at time ‘0’ to automations.
2014-12-04 03:55:03 +01:00
b437de714f make all tests pass 2014-12-04 03:53:26 +01:00
fb63b3ffc3 fix to follow changes to evoral/libardour split 2014-12-03 21:22:53 -05:00
602e390649 changes to Mackie Control support for new crossthreadchannel implementation 2014-12-03 21:22:34 -05:00
2f0c998210 adapt changes to async MIDI port to use new evoral/libardour split 2014-12-03 21:11:24 -05:00
7ab3da66b5 fix up BaseUI to use crossthreadchannel on all platforms 2014-12-03 21:11:02 -05:00
d3e2de8b4e modify Mackie surface code to use crossthreadchannel on all platforms 2014-12-03 20:57:58 -05:00
f4726cc6fa modify MidiUI code to use crossthreadchannel on all platforms 2014-12-03 20:55:44 -05:00
d762ed8c22 alter Async MIDI port implementation to use crossthreadchannel on all platforms 2014-12-03 20:53:49 -05:00
f72b87b448 new platform specific crossthreadchannel files 2014-12-03 20:47:59 -05:00
5c51b302ce manually merge new CrossThreadChannel implementation for windows from Tracks 2014-12-03 20:47:27 -05:00
888bf2d551 Test: update AutomationList properties for v3.5 2014-12-03 23:37:27 +01:00
40087eb378 Test: print assert message if XML property mismatch 2014-12-03 23:27:14 +01:00
b52d8e5151 fix audioengine use in unit-tests. 2014-12-03 20:47:29 +01:00
89d48f4459 fix MTDM test 2014-12-03 20:45:27 +01:00
339670b6fa Tests: ensure that libardour is initialized 2014-12-03 20:45:01 +01:00
32269f0c5a fix audio-engine dtor.
backends - once instantiated - keep a reference to the engine.
when audioengine is destroyed, the backends must be deinstantiated.
This fixes various unit-test cases.
2014-12-03 20:44:47 +01:00
9268d2e699 allow to auto-start dummy backend (needed for tests) 2014-12-03 18:24:56 +01:00
d45e19eda5 fix test segfault
whe XMLTree goes out of scope, the root-node is deleted
2014-12-03 16:03:57 +01:00
0d677f70b4 use Dummy backend for tests 2014-12-03 16:03:19 +01:00
0ec85a4164 Fix running libpbd unit tests when $TOP(in test scripts) is set as relative path
Add test for PBD::canonical_path that was used to track down silly mistake
in test code
2014-12-03 17:44:48 +07:00
dd976d8c7a Add DEBUG_TRACE output to PBD::canonical_path 2014-12-03 17:31:05 +07:00
81d47f5b8c Call PBD::init() from libmidi++ test runner
This is mostly just to be able to set PBD_DEBUG for testing if
necessary
2014-12-03 17:31:05 +07:00
d360bc3906 Add ability to set libpbd debug options via PBD_DEBUG environment var 2014-12-03 17:31:05 +07:00
9eb8b73b43 Call PBD::init from evoral testrunner
This is needed to set _fmode = O_BINARY for libsmf/fread and
fixes takeFiveTest on windows
2014-12-03 17:31:05 +07:00
4b751f9e87 Move setting _fmode flag on windows into PBD::init
This moves setting of _fmode slightly later in the initialization
of the application via Ardour::init.
2014-12-03 17:31:05 +07:00
dc4d76b1d4 Remove references in pbd test script to libs no longer in source tree 2014-12-03 17:31:04 +07:00
01a17f296f Make pbd test script consistant with other test scripts
remove running script from pwd limitation
2014-12-03 17:31:04 +07:00
4fe6bf3530 export MIDIPP_TEST_PATH in midi++ test script so test files can be located
Modify formatting of script to be consistant with other test scripts
2014-12-03 17:31:04 +07:00
23c0452e05 Add test_search_path to find test files in MidnamTest 2014-12-03 17:31:04 +07:00
aed58d6f39 Use test_output_directory() in pbd filesystem test
This prevents directory being created in pwd and means deletion of
directory is unnecessary
2014-12-03 17:31:04 +07:00
61f9ca9f3c Use test utility function to find evoral test files
either via EVORAL_TEST_PATH env var or on windows via directory relative
to dll
2014-12-03 17:31:04 +07:00
f6e15a3b6b Use PBD::tmp_writable_directory to write evoral test file into
no need to remove directory as it is temporary
2014-12-03 17:31:04 +07:00
929fc3d235 Use PBD::tmp_writable_directory in libardour test_util.cc 2014-12-03 17:31:04 +07:00
376340a29f Remove unnecessary comma in pbd wscript file 2014-12-03 17:31:04 +07:00
1c1eff8845 Use PBD::tmp_writable_directory in test_output_directory 2014-12-03 17:31:04 +07:00
1abe8f4e42 Add PBD::tmp_writable_directory utility function to pbd/file_utils.h/cc 2014-12-03 17:31:04 +07:00
2b03521ef9 Fixes for AudioEngine test 2014-12-03 17:31:04 +07:00
e83bb2f4e2 Remove unused test_common.h/cc files 2014-12-03 17:31:04 +07:00
f1b66b86b4 Move libardour test utility code into one source file 2014-12-03 17:31:04 +07:00
b9567b6d46 Use ardev_common.sh to setup environment for running libardour tests 2014-12-03 17:31:03 +07:00
7a3c54f031 Fix evoral test suite. 2014-12-02 23:30:16 -05:00
25efe5953c Fix range of pan controls.
Set default range to [0,1] since [0,0] is problematic and useless anyway.
2014-12-02 19:02:03 -05:00
94b26cd9af Make 'ARDOUR::ParameterDescriptor' exportable, so that it can get used outside of libardour 2014-12-02 18:59:43 +00:00
a13ff7b604 Remove accidentally committed file. 2014-12-02 12:15:54 -05:00
7aab4be5e4 alsa-backend: drop midi during freewheel processing. 2014-12-02 17:03:29 +01:00
db3d42d551 first pass at optimization for low-level canvas code 2014-12-02 05:32:34 -05:00
cf47d71761 Fix lost MIDI events due to broken range check. 2014-12-02 03:36:33 -05:00
07a381a8f5 Create discrete lists for recorded MIDI controls. 2014-12-02 00:21:52 -05:00
86de0386c9 Fix automation write/touch. 2014-12-01 23:35:24 -05:00
2b69fa6edf Factor out copy-paste code. 2014-12-01 23:35:24 -05:00
767c0238a3 Replace half-baked param metadata with descriptor.
Among other things, this means that automation controls/lists have the actual
min/max/normal/toggled of parameters, and not those inferred from the Parameter
ID, which is not correct for things like plugin parameters.

Pushing things down to the Evoral::ParmeterDescriptor may be useful in the
future to have lists do smarter things based on parameter range, but currently
I have just pushed down the above-mentioned currently used attributes.
2014-12-01 23:35:24 -05:00
Julien de Kozak
cb8abbe8d2 Make it compile with C++11 support.
Reference : https://bugs.webkit.org/show_bug.cgi?id=59249
2014-12-01 23:18:11 +01:00
43cc295a58 Tidy up comments in Evoral::coverage
Remove old (already #if 0'ed) implementation of Evoral::coverage() and its
comments.

Tidy up the comment enumerating all the possible ways in which two ranges
can overlap, note the Evoral::OverlapType corresponding to each one, and add
comments to the if()s in coverage corresponding to the cases in the list of
overlap types.

Remove some commented-out assert()s that actually do happen, and re-instate
one that really shouldn't.

Fix a small typo (with -> within)
2014-12-01 20:13:04 +00:00
dd5fc9432f Simplify Evoral::RangeList::subtract(), and make it pass amended tests
The various conditionals in Evoral::RangeList::subtract() appear to have
been there to work around
 (a) coverage() not always returning the correct value, &
 (b) the test suite assuming that the ->to point lies outside the range

Now that these are both fixed, the implementation of subtract() becomes
quite a bit clearer. I replaced the if()s with assert()s for now, but these
shouldn't trip if coverage() is working as I expect.

Also (attempt to) clarify the comments in subtract.
2014-12-01 20:13:04 +00:00
30a9c2d05b Comments in various call-sites of coverage()
Comments in various call sites of Evoral::coverage() marking things I think
are dubious (with XXX). Also straightened up the alignment of some ASCII
art in libs/ardour/diskstream.cc
2014-12-01 20:12:51 +00:00
d7cc7775f3 Rework Evoral::coverage() to pass unit tests
Rewrite Evoral::coverage() to (hopefully) do what it's supposed to.

Return OverlapNone for invalid ranges: if either of the ranges passed to
Evoral::coverage() have negative length (i.e.  start > end), return OverlapNone
- it seems reasonable to say that a negative-length range can't overlap
anything. Also return OverlapNone from the fallthrough case, though this should
never happen.
2014-12-01 20:03:22 +00:00
47d329ca40 Make tests of Evoral::Range functions include both endpoints in Range
Some of the tests for Evoral::RangeList::subtract() assume that ranges
don't contain their end (->to) point. This appears inconsistent with how
they are used elsewhere.

Add some ASCII art comments to the tests to try to clarify what they're
really testing for, and amend subtractTest1, subtractTest4, & subtractTest5
to incorporate the assumption that ranges include their end points.
2014-12-01 16:52:58 +00:00
0c7dd82239 exclude fader-reserve from range 2014-12-01 17:45:27 +01:00
0ffeaa6d6a Remove braindead Parameter inheritance abuse. 2014-11-30 23:56:20 -05:00
7eb4e5d22b Replace thinning static state with parameter. 2014-11-30 23:56:20 -05:00
b68fd1cc25 Remove dead code. 2014-11-30 23:56:20 -05:00
0b48eb68f8 Remove bogus test and noisy output. 2014-11-30 23:56:19 -05:00
2588b1cac9 Trim the include tree. 2014-11-30 23:56:19 -05:00
1693e57e0e Move EventRingBuffer to libardour.
This is not used anywhere in Evoral and is just a wrapper around the PBD
RingBuffer anyway.  Towards a (once again?) independently buildable/testable
Evoral and fewer cross-dependencies.
2014-11-30 23:56:19 -05:00
cf537b97f5 Add missing namespace qualifiers. 2014-11-30 23:56:19 -05:00
008bfceb77 Clean up state tracking of raw MIDI. 2014-11-30 23:56:19 -05:00
a0deb7c3bf Save mute automation state. 2014-11-30 23:56:19 -05:00
272c93db12 CLA approved consistent fine-grained scale modifier 2014-11-30 21:27:31 +01:00
2996e677c4 Process 'default_ui_config.in' when building with MSVC 2014-11-30 17:57:44 +00:00
18efe8f446 consistent step+page sizes for fader+spinbox 2014-11-30 15:05:40 +01:00
fb3f9033cf use update_steps() instead of custom function 2014-11-30 15:05:39 +01:00
0622fc9d4b update_steps(), properly handle integer ranges 2014-11-30 15:05:39 +01:00
bd85c8ec43 fix ladpsa default value.
because get_parameter_descriptor() is const, also wrap
default_value() in a const function.
2014-11-30 15:05:39 +01:00
cf859270e0 fix LV2 default port value. 2014-11-30 15:05:39 +01:00
77d5fb7a35 Fix write for boolean automation. 2014-11-29 14:32:12 -05:00
c77f4b7a18 don't move faders on click.
for one, it can mess up the value when switching to
numeric-entry. It is also rather useless and not
Fader-like (faders are not scrollbars).
Besides, "stepvalue" is way to large and causes jumps
(sometimes step-value is even negative, see
"fast lookahead limiter", "release time"
 -> some other bug)
2014-11-29 17:31:41 +01:00
58663db374 change ownership of processor window-proxy
fixes crashes:
* If the Editor-Mixer shows a channel with a plugin that
has been edited in the Mixer, double-clicking the plugin 
will try to bring up a 2nd instance of the plugin-UI.
* When closing Ardour both the Mixer and the Editor-Mixer try to delete the underlying plugin, resulting in a double free.
2014-11-29 10:06:25 +01:00
784b96e255 Set discrete by default for boolean parameters. 2014-11-29 01:40:23 -05:00
ed1bbefd19 Somewhat working gain automation.
This probably isn't correct in several ways, but it works more than it did, so
I figure it's push worthy.

Still not working:

 * Saving mute automation list
 * Dragged control points are not snapped to model restrictions
   (boolean, in this case, but general problem)
 * Line goes funny if you record mute automation
   (as opposed to drawing it which works)
2014-11-29 01:25:27 -05:00
f190e630ab Show discrete/toggled automation as stepped line. 2014-11-28 21:15:28 -05:00
e55b68298b Fix crash when deleting all points from a line. 2014-11-28 20:04:57 -05:00
358ebde106 Set the toggled default metadata of parameters.
This is so generic code looking at the Parameter for gain, solo, and
rec-enable will get the correct value for toggled.
2014-11-28 18:04:51 -05:00
ea35595370 Add some newly introduced source files to our MSVC project (cairocanvas) 2014-11-28 14:42:17 +00:00
16947f751b Remove dead code. 2014-11-27 04:17:15 -05:00
3d4b1d324e Fix calculation using uninitialized value.
Implicit "this" is the devil.
2014-11-27 04:15:30 -05:00
25e1eddc50 remove "port sources" management from MidiControlUI and Mackie support.
This was necessary due to a bug/design issue between Glibmm and Glib (see https://bugzilla.gnome.org/show_bug.cgi?id=561885)
 but the problem needs to be managed by the *creator* of the IOSource and that has now moved inside CrossThreadChannel.
2014-11-26 18:22:22 +02:00
6edd81e4f6 get correct ::distance() and ::delta() implementations for cases involving achromatics 2014-11-26 18:22:22 +02:00
318a9edab9 massive reworking of color selection implementation 2014-11-26 18:22:22 +02:00
c927eeb9ee ensure that Ardour recognizes its own MMC device ID as "all-call" when set to 0x7f (127) 2014-11-26 18:22:22 +02:00
b9be8d2652 Replace individual waf options for enabling backends with one --with-backends option 2014-11-26 22:47:05 +07:00
4358b8db79 Add test for Evoral::coverage()
Add a test function to test Evoral::coverage() with all possible overlap
types. The first test (line 161) that expects OverlapExternal will fail
with the current implementation of coverage().

There's possibly still a discussion to be had about what the overlap type of
ranges with negative lengths should be: there are currently places in the main
Ardour code base where coverage() is called with ranges where start > end.
2014-11-25 17:49:51 +00:00
3a6c9e3bb9 Fix build of evoral tests
Fix compile errors in libs/evoral/test/, by explicitly calling
Evoral::MusicalTime::to_double() wherever a double value is required of a
MusicalTime.

Some of the double variables should probably really be made into MusicalTime
ones instead, but I don't want to mess with this too much.

takeFiveTest still fails for me after this, but a failing test is probably
more informative in the long run than a test that won't even compile.
2014-11-25 14:59:48 +00:00
1f58f81aa6 Fix order of parameters to stop_touch() in Mackie::Control
Reverse the parameters of Mackie::Control::stop_touch() to make them
consistent with AutomationControl::stop_touch(), and fix up the call to
AutomationControl::stop_touch() to have the parameters in the correct
order.

Unfortunately, I don't possess any devices that speak the Mackie protocol, so
though the patch seems logical and correct to me, I have no way of testing it.
If anyone has a device with touch faders that speaks Mackie, I'd be glad of any
confirmation that it at least doesn't break anything.
2014-11-25 14:59:48 +00:00
ea5876b836 Remove dead code. 2014-11-25 02:11:44 -05:00
78218e8c07 fix OSX open URL in browser 2014-11-24 20:35:38 +01:00
c7ddedc5b8 Simulate 'trunc()' which isn't available in MSVC
(needed by 'gtk2_ardour/editor.cc')
2014-11-24 12:56:07 +00:00
018f559aad Remove a commented out line in 'pbd/stacktrace.h'
(was probably just needed for testing at some stage)
2014-11-24 12:53:24 +00:00
25745758aa Changes needed to accommodate building libevoral with MSVC
Note that class 'MusicalTime' needn't be exportable (with a little work, this could be reverted if it affects the other builds)
2014-11-24 12:51:54 +00:00
c0e8647806 amend c4533939b9 2014-11-24 00:04:45 +01:00
cd91fa0046 hotfix windows-compilation (unfinished bfe49540b9)
..at least it compiles and starts. Mackie support etc
is probably still broken.
2014-11-23 23:57:56 +01:00
8ddeb712f6 make debug message more useful 2014-11-23 23:57:55 +01:00
5aba4df252 fix/silence various compiler warnings.
* ifdef unused static functions
* brackets around assignment and comparision
* no return statement in function returning non-void
* boost concept_checks.hpp unused-local-typedefs
2014-11-23 23:57:55 +01:00
f1926dc863 Fix build with a certain awful broken compiler. 2014-11-23 16:31:59 -05:00
ec01682714 -Wunused-function on windows 2014-11-23 21:01:39 +01:00
40764f4cb3 use NULL not 0 for c-functions (even in c++ code)
4.3 KBytes less compiler warnings.
2014-11-23 21:01:39 +01:00