Commit Graph

1094 Commits

Author SHA1 Message Date
Vesa
f33d1f4972 Instrument track, mixer... 2014-07-09 20:42:54 +03:00
Vesa
4eb486be1e Attempt to remove mutex calls from instrumenttrack::processinevent 2014-07-09 20:39:41 +03:00
Vesa V
8407427c4b Merge pull request #933 from LMMS/stable-1.1
Stable 1.1
2014-07-05 16:34:34 +03:00
Vesa
06b47a52a2 Fix styling of textFloat & whatsthis, make text floats consistent in style with tooltips
Should fix #925
2014-07-03 14:09:31 +03:00
Tres Finocchiaro
63a5a16cd0 isinf and isnan declarations win32/apple 2014-06-30 23:21:17 -04:00
Vesa V
6ffcc0e799 Merge pull request #911 from diizy/master-nph
Revision of handling of frameoffset for NPH, SPH
2014-06-30 12:52:44 +03:00
Vesa V
9c8c80683b Merge pull request #913 from LMMS/stable-1.1
Syncing...
2014-06-30 12:49:02 +03:00
Vesa
23433a70b5 Sample-exact models: improve
- Remove the redundant hasSampleExactData() function. Instead, signal lack of s.ex.data by returning a NULL in valueBuffer()
- Cache s.ex.buffers and only update them once per period
- Make valueBuffer() in AutomatableModel threadsafe so that it can be used for NPH's sharing the same model
- Add sample-exactness to instrumenttrack's vol & pan knobs
2014-06-30 01:59:18 +03:00
Vesa
270af579b8 Revision of handling of frameoffset for NPH, SPH
Change in handling of frameoffset for multistreamed instruments and sampletracks.
- Instead of holding the offset for the lifetime of the playhandle, negate the offset in the first period
- Multistream-instruments require some small changes: they have to now check for the offset and accordingly leave empty space in the start of the period (already done in this commit)
- There are possibly optimizations that can be done later
- This change is necessary so that we can have sample-exact models, and sample-exact vol/pan knobs for all instruments. Earlier multistream instruments were always rendering some frames ahead-of-time, so applying sample-exact data for them would have been impossible, since we don't have the future-values yet...
2014-06-29 23:13:00 +03:00
Vesa
005bf69705 Lmms_math: add dBV conversion functions (for future use) 2014-06-29 13:08:49 +03:00
Vesa
edc97edb9e DspEffectLibrary: fix stereoenhancer 2014-06-29 09:55:16 +03:00
Vesa
a7bb31159e Merge branch 'stable-1.1'
Conflicts:
	include/basic_filters.h
	src/core/FxMixer.cpp
2014-06-28 17:24:23 +03:00
Tobias Doerffel
0447e0fe44 Merge pull request #895 from diizy/filters
basic_filters: optimize RC highpass & bandpass filters
2014-06-28 11:55:47 +02:00
Vesa
0058b1064f Update channel send model names properly 2014-06-28 10:06:52 +03:00
Vesa
9243d94484 Fix qstring arg 2014-06-27 23:17:21 +03:00
Vesa
d9d085d14e FxMixer: rewrite mixer routing 2014-06-27 18:21:18 +03:00
Vesa
27383f91b7 basic_filters: replace div with mul 2014-06-26 13:18:00 +03:00
Vesa
ba700399da basic_filters - even more optimization
Use more efficient interpolation, optimize some calculations
2014-06-26 13:15:20 +03:00
Vesa
d6809b45c1 basic_filters: further optimization
Use qBound in formant, and return early from calcFilterCoeffs so we don't do needless calculations
2014-06-26 12:41:35 +03:00
Vesa
d166212d49 basic_filters: optimize RC highpass & bandpass filters
For both RC12 and RC24 filter types: handle lowpass separately, because we can then calculate highpass & bandpass with less operations.
This shouldn't affect the performance of lowpass, but probably will make highpass and bandpass a bit faster.
2014-06-25 20:43:34 +03:00
Vesa
a463594bb2 FxMixerView, FxLine: graphics & layout fixes 2014-06-24 21:07:15 +03:00
Vesa
4185eac023 Merge branch 'stable-1.1'
Conflicts:
	src/core/AutomatableModel.cpp
2014-06-23 22:10:27 +03:00
Tobias Doerffel
1287aec800 Merge pull request #875 from diizy/logs
Logscale models: fix all issues and finalize the implementation
2014-06-21 23:43:05 +02:00
Tobias Doerffel
eee2ba7f16 Merge remote-tracking branch 'origin/stable-1.1'
Conflicts:
	data/locale/de.qm
	data/locale/de.ts
2014-06-21 23:30:59 +02:00
Tobias Doerffel
6d8890b4ff Merge remote-tracking branch 'origin/stable-1.0' into stable-1.1 2014-06-21 23:29:32 +02:00
Vesa
f7042977a9 Logscale: Fix negative ranges
This fixes errors that happen on models that have both logarithmic scale and a range that goes to the negative.
2014-06-21 10:56:28 +03:00
Vesa
8da423412c Remove unneeded function 2014-06-20 23:01:38 +03:00
Vesa
14909bdf1b Log scales finalized 2014-06-20 22:46:10 +03:00
Vesa
83cc446807 FxMixerView: fix disappearing effects 2014-06-19 22:17:59 +03:00
Vesa
4bcbb1abcc FxMixer GUI updates: code 2014-06-19 17:59:37 +03:00
Tobias Doerffel
3ab6a7ac0f Merge pull request #846 from diizy/stable-1.1
FxMixer: Fix channel delete and other bugs
2014-06-15 23:31:02 +02:00
Vesa
24bf336bf8 FxMixer: fix crashes on modifying sends
Added a mutex so that the GUI thread can't change the sends around during the rendering loop.
2014-06-14 14:53:22 +03:00
Vesa
3319380cf6 FxMixer: Fix channel delete 2014-06-14 14:37:27 +03:00
Vesa
9c584778d2 5th: fix #563 - do not destroy IPH's on "All Notes Off" MIDI commands 2014-06-14 14:37:07 +03:00
Vesa
d1eb9886fd Make that 4: Fix stuck midi notes on changing master pitch 2014-06-14 14:37:07 +03:00
Vesa
a172783cd0 3-in-1 bugfix special
Fixes bugs: #568, #289 and the incorrect timing for midi-noteoffs (see mailing list)
2014-06-14 14:37:07 +03:00
Vesa
a0d6115482 A fix to IPH waiting code: don't wait for already finished notes, plus a bit of optimization 2014-06-13 19:47:48 +03:00
sarahkeefe
940fb0d3d5 Updating include to QtCore/QtGlobal 2014-06-11 17:16:28 -04:00
sarahkeefe
91519898d0 Replacing <Qt/global.h> includes with <QtGlobal> to fix compile issue on OS X 2014-06-11 13:21:01 -04:00
Raine M. Ekman
0941520d8c basic_filters.h: One unnecessary m_vflp array removed. 2014-06-10 12:10:42 +03:00
Raine M. Ekman
c29ec40711 basic_filters.h: Remove unneccessary LP filter calculations in Formantfilter 2014-06-10 11:57:59 +03:00
Tobias Doerffel
5fdc8e63d9 Merge pull request #819 from diizy/mixeriph2
Ensure that NotePlayHandles get processed before the InstrumentPlayHandl...
2014-06-09 13:43:51 +02:00
Tobias Doerffel
019c438668 Merge pull request #817 from diizy/bbtrack-ui
Make BB-tracks themeable
2014-06-09 13:41:55 +02:00
Vesa
2fa7892542 Use QBrush instead of QColor on some theme properties
Apparently, we can use QBrush -typed properties in the CSS. This just never occured to me before!
So, this has several benefits. A QColor property only allows a singular RGB value, but a QBrush allows the same plus also qgradients, RGBA-colours and maybe even bitmap patterns. So I'm changing some properties to QBrush, where it makes sense to allow this additional functionality - no need to enable it for simple things like text colours or such.

- Song editor background: instead of the earlier hack with 7 qproperties just to set a limited background gradient, we can use only 2 properties and allow much more flexibility with Qt's own qgradient syntax
- Automation editor: background, graph colour, and the sidebar colour - @musikBear recently complained not seeing the grid through the graph, so transparency can help there, and qlineargradients in the graph can produce very cool visual effects. Grid is pointless to change, it should stay single-colour for now.
- Piano roll: here, I only made the background use QBrush - we don't really have much else here that can utilize QBrush, the notes have their own gradient system... maybe the 2nd colour of the note gradient could be customizable though.

There are probably more places where this change makes sense...
2014-06-08 18:06:09 +03:00
Vesa
bad08a2632 Ensure that NotePlayHandles get processed before the InstrumentPlayHandle on instruments that use both NotePlayHandles and InstrumentPlayHandle, such as LB302 and SF2-Player
Issue: Currently, we use threads to process all PlayHandles, so there's no guarantee of the order they are processed in. This causes timing inaccuracy and jitter: notes of instruments that use both NPH's and IPH's can get randomly delayed by one entire period.
The issue is solved thusly:
- When processing an IPH, we check if the instrument is midi-based. If yes, we just process it normally (no NPH's to worry about).
- If it's not, then it also uses NPH's, so we'll have the IPH wait until all NPH's belonging to same instrument have been processed. There's some similar code in the new FX mixer, I pretty much just copied how we do it there.
2014-06-06 14:24:51 +03:00
Vesa
910f89a5d3 Make BB-tracks themeable
- This allows defining a default colour for BB-track patterns in the CSS
- The default colour is used for all bb-patterns which don't have a custom colour set by the user: in other words, the colour of a pattern can be any rgb-value OR "style colour"
- By default, all created bb-patterns use the style colour
- You can also reset colourized patterns to use style colour again
- Backwards compatibility: old projects will be loaded so that any pattern using either of the old default colours will be converted to use style colour

TODO: add a settings option that can disable custom colours (ie. always use style colour), and/or an option to reset all patterns in a project to style colour. This is needed, since themes can now change the song editor background, which can lead to unfortunate colour combinations with custom colours...
2014-06-06 11:06:12 +03:00
Vesa
6e2d73721c RingBuffer: initial commit
Implements a ring buffer class for LMMS, which is designed to be flexible, efficient and thread-safe.
Due to flexible design, it supports various methods of operation:
- set delays/sizes in absolute frame values, ignoring samplerate
- set delays/sizes in milliseconds with samplerate-awareness
- multiple inputs -> single output
- single input -> multiple outputs
Efficiency is achieved by working in buffers and using memcpy/memset for audio operations, except when additive mixing is needed: then MixHelpers are used
Thread-safety is guaranteed with QMutex
2014-06-05 20:26:48 +03:00
Vesa
06be5bba82 Make MIDI timing sample-accurate
- currently only affects Vestige
- no idea whether this can also be used for Zyn and OpulenZ, I'm not sure if Zyn has any kind of mechanism for communicating frame offset to the synth, as for OpulenZ, @softrabbit would know the answer better
- basically, I made it happen by simply adding an extra parameter in the processMidi{In|Out} functions, which is 0 by default, and made the necessary changes in instrumentTrack and nph to utilize it
- I based this against 1.1 because I didn't think it's a very big change, and I don't see much possibility for things going wrong here, since we're basically just using the existing functionality in Vestige (there already was a frame offset being communicated to the remote plugin, just that it was always set to 0). However, if @tobydox thinks this is better to bump up to 1.2, I can rebase it for master...
2014-06-04 04:23:16 +03:00
Vesa
43d1b30727 FxMixer, ValueBuffer, etc. fixes 2014-06-01 15:25:02 +03:00
Vesa
1c0f9700fa S.ex. models: implement support for sample-exact controls in fx-mixer
Works for all faders and send knobs
2014-06-01 07:17:43 +03:00