Commit graph

15351 commits

Author SHA1 Message Date
Paul Davis
fd5cd74214 fix DiskReader::overwrite_existing_audio()
Several math/geometry errors here
2020-01-03 16:13:23 -07:00
Paul Davis
e7542c0611 NOOP: line refolding 2020-01-03 16:13:23 -07:00
Robin Gareus
eccbdd10e0
Remove debug output 2020-01-01 20:52:07 +01:00
Paul Davis
d100c92731 convert GenericMIDI into a real control protocol module, with its own event loop and ports 2019-12-31 12:06:14 -07:00
Paul Davis
1ced4067aa ensure that xmlKeepBlankDefault() is called early in instance-life, from PBD::init()
See comment for details on why
2019-12-31 12:06:14 -07:00
Paul Davis
007136cc23 remove MIDI Control input and output ports from session-level objects 2019-12-31 12:06:14 -07:00
John Emmas
75aaae9963 Fix two more cases of of C99 strtoll() 2019-12-31 10:11:18 +00:00
Robin Gareus
def4be7285
Fix MSVC builds, use C89 strtol() instead of C99 strtoll()
For the case at hand (plugin scale-points) it's highly unlikely to
encounter numbers > INT_MAX.
2019-12-30 19:05:51 +01:00
Paul Davis
60ccbcf9cc use a local version (copy) of the G_SOURCE_FUNC macro, since it is not available in the GTK+ version we use for the official build stack 2019-12-30 09:49:23 -07:00
Robin Gareus
3ee08bbae7
Revert "fix a cast warning (as recommended in GTK+ docs"
This reverts commit af30a6f001

because it breaks OSX/MacOS builds:
libs/surfaces/mackie/mackie_control_protocol.cc:945: error: 'G_SOURCE_FUNC' was not declared in this scope
2019-12-30 16:00:22 +01:00
Paul Davis
d79d2807b1 expand use of new BasicUI API for transport button state to all control surfaces 2019-12-29 18:53:22 -07:00
Paul Davis
52aa405ce3 use new Session API to deal with transport state
Transition to use BasicUI button state API to come
2019-12-29 18:43:51 -07:00
Paul Davis
e46e6f12a3 use new BasicUI and Session API to deal with transport state 2019-12-29 18:43:51 -07:00
Paul Davis
a8cc5b1303 provide new methods for BasicUI that wrap the "complexity" of how to show transport state via lit buttons 2019-12-29 18:43:51 -07:00
Paul Davis
6383d4f6a6 recomment a DEBUG_TRACE statement that generates too much output with -D transport 2019-12-29 18:43:51 -07:00
Paul Davis
30226fdc2a add EMIT_SIGNAL comment 2019-12-29 18:43:51 -07:00
Paul Davis
719c3f1457 add Session::transport_stopped_or_stopping()
Session::TransportStateChanged notifies about transport stop before the stop is complete (i.e. at the start of the declick).
Various other objects (notably control surfaces) connect to this signal and use it to modify their displayed state.
We need a method that can tell them we are stopped (or stopping) even though we are not "fully" stopped yet. This is
that method
2019-12-29 18:43:51 -07:00
Paul Davis
af30a6f001 fix a cast warning (as recommended in GTK+ docs 2019-12-29 18:43:51 -07:00
Robin Gareus
bb232b6ec4
Use human-numeric-sort for plugin scale-points 2019-12-29 19:48:45 +01:00
Robin Gareus
04a409df6f
Add a numerically_less compare operator
This is similar to sort(1) --human-numeric-sort,
as opposed to naturally_less() negative numbers, hex-prefixes
and SI metric prefixes are taken into account.
2019-12-29 19:47:48 +01:00
Paul Davis
ed67f465fb fix JACK transport sync
key change: to sync with JACK always locate jack-position PLUS buffer-sized-rounded-worst_latency_preroll() ahead
2019-12-27 21:18:12 -07:00
Paul Davis
5cdeb2401f add new Session method to return the worst_latency_preroll() value rounded up to the nearest buffer size 2019-12-27 21:18:12 -07:00
Paul Davis
ca36d7cc2f register TransportState enum for use with enumwriter 2019-12-27 21:18:12 -07:00
Robin Gareus
2edbda2526
Replace explicit image-surface with cairo pattern/group
For MacOS/X this is equivalent, rendering happens using a
CGBitmapContext + image-surface. Windows and Linux needs profiling
for respective equivalent surfaces.
2019-12-27 19:35:02 +01:00
Robin Gareus
c3ab63a2ea
Allow for per-widget image-surface backing
This is an intermediate commit, before replacing image surfaces with
cairo pattern groups.

The eventual goal is to reduce flickering and/or use
CPU + bitblt for specific widgets instead of cairo
graphics-cards accel.

This also removes excessive calls to getenv() for every rendering
operation.
2019-12-27 19:34:56 +01:00
Paul Davis
7b1a875f9c remove unused member
Note: there is no global state for "the" transport master, since we have several at all times now
2019-12-27 10:53:02 -07:00
Paul Davis
c35a28acfe variable rename 2019-12-27 10:53:02 -07:00
Paul Davis
0d3a91b381 improve parseability of a comment 2019-12-27 10:53:02 -07:00
Robin Gareus
ab58c894d3
Use weak-ptr for source added/removed signals (1/2)
This might fix a "SessionHandleRef exists across session deletion",
when the shared_ptr was be pushed onto a x-thread pool, and not
invalidated in time before the session was closed.
2019-12-25 17:59:38 +01:00
Robin Gareus
df17e3f041
Prevent copy-construction of sources to be destroyed list
destroy_sources () is only called from Session::remove_last_capture ().
The list of sources to be destroyed is the local scope of that method
and will hold a reference to the object.
copy-construct the list and removing elements one by one from the
copy is only unnecessary overhead.
2019-12-25 17:57:10 +01:00
Robin Gareus
c9c8cd2777
NO-OP: comment signal emission 2019-12-25 17:52:02 +01:00
Paul Davis
61aeb05f2e add a mechanism to use existing MIDNAM info and connect to PatchesChanged in future, atomically
The atomically is with respect to the initial thread-based MIDNAM loading
2019-12-23 10:27:00 -07:00
Paul Davis
63ba8da3e1 basics of threaded MIDNAM loading 2019-12-23 10:27:00 -07:00
Paul Davis
4874ff8843 slightly enhanced error handling when loading MIDNAM data 2019-12-19 13:14:45 -07:00
Paul Davis
bfa5eb982d handle MIDI rendering correctly when there are no regions 2019-12-19 13:14:45 -07:00
Paul Davis
8deed500a4 fix thinko ... we're checking if a DiskReader handles audio 2019-12-19 09:09:42 -07:00
Paul Davis
3c83979a50 further improve debug message 2019-12-18 19:56:38 -07:00
Paul Davis
c8b9184956 fix thinko in MidiRegion::render()
MidiSource::read() wants a length, not an end-sample.

This should fix (at least) some cases where notes past the region end
get included/played
2019-12-18 19:50:32 -07:00
Paul Davis
9bd8e67f39 remove debug message 2019-12-18 19:49:34 -07:00
Paul Davis
ebe1aeb146 fix debug message 2019-12-18 19:49:09 -07:00
Paul Davis
8b3e7fea37 fix Temporal::Beats::operator* 2019-12-18 18:00:53 -07:00
Paul Davis
aa856b509c tweak debug output 2019-12-18 18:00:33 -07:00
Paul Davis
a73577a45a do not try to process audio in a diskreader with no audio playlist 2019-12-18 17:34:39 -07:00
Paul Davis
aeefd7e50a fix crash when looping with a MIDI track 2019-12-18 15:05:49 -07:00
Robin Gareus
c49c17ffff
Cont'd work on Playlists import from old 2.x sessions
v2.0.0 sessions don't save empty playlists. So missing playlists
for a give diskstream are fine. Just use a default empty one.
2019-12-17 22:56:12 +01:00
Paul Davis
53f72dd402 a new stop command while in the middle of declick-to-stop is not a bad transition 2019-12-17 13:21:38 -07:00
Robin Gareus
f76c897f04
Directly apply MIDI automation state changes
Previously "play/off" and "discrete/linear" changes had no effect
until the MIDI playlist was edited and MIDI re-read into RAM.
2019-12-17 17:17:27 +01:00
Robin Gareus
37c9a7beb1
Fix MIDI port i/o when vari-speeding 2019-12-17 05:56:49 +01:00
Robin Gareus
848831d844
Convert Disksteam & Playlists from old 2.x sessions 2019-12-17 00:42:28 +01:00
Paul Davis
c144e807ef remove mistakenly left-in debug stacktrace 2019-12-16 16:18:30 -07:00