summaryrefslogtreecommitdiff
path: root/gtk2_ardour/region_view.cc
AgeCommit message (Collapse)Author
2017-02-05midi note drags are music-based.nick_m
- wysiwyg (during drag) when dragging more than one note across a tempo change. - introduces a muscal equivalent of snap_delta (only used for note drags atm) - split earliest note in selection into a separate function - MRV::copy_selection() returns the equivalent _primary note to avoid offset hell. - RV::snap_frame_to_frame returns a MusicFrame - prevent note drag moving before region start.
2017-02-04rework snapnick_m
snap now fills in a struct (MusicFrame) which contins a snapped frame along with a music divisor. this gives useful information wrt magnetic snap which may or may not have rounded to an exact musical position. region position may now be set musically (using quarter notes for now). this patch fixes several problems in the current code: - dragging a list of music-locked regions now maintains correct musical offsets within the list. - splitting regions using magnetic snap works correctly (#7192) - cut drag should now work correctly with magnetic snap. - musical length of split midi regions is no longer frame based.
2016-11-30NO-OP backport changes from Mixbus branch.Robin Gareus
2016-10-17Fix region colors not updating on theme change.nick_m
2016-07-14enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.hPaul Davis
2016-07-10remove reference "const int32_t&" -> const int32_t"Robin Gareus
this simplifies lua-bindings and also let's the compiler worry about constant primitive types.
2016-07-10Revert incorrect 'optimisation' from 4f7a4cd2333.nick_m
- fixes regression in stacked layering display.
2016-07-10Exact beat - provide audio->music mapping for region split.nick_m
- for those not in the know, this series provides a way to remove the temporal distortion introduced when using an audio frame-based gui for music-locked objects. In short, the gui uses an audio frame representation to move objects. It displays the object using frame_at_beat(), quantizing the time value to audio frames. This is fine until the user selects that frame but expects it to be interpreted as a beat. Thus beat_at_frame() would not produce the user-expected beat (temporal quantization error of up to 0.5 audio samples). This is one method of mapping audio time to music time accurately.
2016-07-10Make some musical operations on music-locked regions operate in beats.nick_m
- use exact beats to determine frame position. - see comments in tempo.cc for more. - this hasn't been done for split yet, but dragging and trimming are supported.
2016-06-11Make RegionView less aggressive about trimming the front of a region.nick_m
2016-05-27Crapola - this is an experimental performance hack that must be reverted.nick_m
2016-05-27Tempo ramps - remove double calls to RegionView::set_duration() and ↵nick_m
MidiRegionView::redisplay_model() - massively improves note redrawing performance when dragging tempos and audio-locked meters,
2016-05-17break live-loop if there's no next region - fixes #6848Robin Gareus
2015-10-22Remove GhostRegion::CatchDeletion signal to reduce session close timesTim Mayberry
Currently when a GhostRegion is deleted by its "parent" RegionView it emits the static GhostRegion::CatchDeletion signal which is connected to the RegionView::remove_ghost method of every RegionView instance. With a static GhostRegion::CatchDeletion signal a particular test session causes 31 Million calls of RegionView::remove_ghost on Session deletion and the session takes 70 seconds to close with a debug build. The lifetime of a ghost region is tied to both the TimeAxisView(TAV) and RegionView(RV) in that when a RegionView is deleted all GhostRegion instances associated with the RegionView should be deleted or when a TimeAxisView is deleted all ghost regions that are contained in the view should be deleted. This means that there needs to be notification between GhostRegion and both classes. Instead of using a signal for this as we know there are only two listeners and GhostRegion already holds a reference to the TimeAxisView, also take a reference to the parent RegionView in the GhostRegion constructor and use it to notify the RegionView when GhostRegion destructor is called so it can drop any references it holds. Using a direct function call in the GhostRegion destructor to notify the TimeAxisView and RegionView "parents" brings the unload/close time down for the test session from 70 seconds to 4.5 seconds. The GhostRegion also references canvas items that are added to the TimeAxisView canvas group or at least a canvas group that it manages. So when the TimeAxisView is destroyed and the canvas group that is the parent of those items is destroyed, the GhostRegion's canvas items will also be deleted/destroyed by the parent canvas item/group. This means the GhostRegions must be destroyed when the TimeAxisView they are contained in is destroyed or there will be dangling references to canvas items that have already been deleted and trying to delete them again will be bad.
2015-10-05NOOP, remove trailing tabs/whitespace.Robin Gareus
2015-09-16Move UIConfiguration Singleton into UIConfiguration headerTim Mayberry
This removes the direct dependence on ardour_ui.h from 39 files
2015-09-16Move DPIReset and ColorsChanged signals into UIConfigurationTim Mayberry
2015-05-23Fix inverted logic of SnapOff with snap modifiers pressed.nick_m
- also clean up, rename and comment some previous hanges.
2015-05-22More cleanupnick_m
- remove "no_magnets" ugh.
2015-05-17Relative snap - support magnetic mode (hackishly for now)nick_m
2015-02-11remove use of TimeRectanglePaul Davis
2014-12-19more color/modifier tweaksPaul Davis
2014-12-19allow theme control of sync mark colorsPaul Davis
2014-12-19add more controllable modifiers for region transparencyPaul Davis
2014-12-18Use color modifiers for dynamic region styles.David Robillard
2014-12-17Remove some aborts that don't really need to be.David Robillard
Enforce PatchPrimaryKey sanity at the type level rather than attempting to check for it everywhere. Remove dead file.
2014-12-15add some alpha to "covered region" colorationPaul Davis
2014-12-15final modifierPaul Davis
2014-12-14fix up requested color names everywhere.Paul Davis
Thank <deity> for emacs ... space-uncamelcase-word-at-point FTW
2014-12-14initial pass to replace all UIConfiguration::get_XXXXXX() calls with ↵Paul Davis
UIConfiguration::color(name). IMPORTANT: names have not been downcased and spaced yet, so many colors are not found
2014-11-22Move time converters only to the region views that actually need them.David Robillard
A step towards sorting out time issues more solidly, the time situation of MIDI region views and automation region views is slightly different.
2014-11-16Use an enum for RoundMode instead of magic numbers.David Robillard
No functional changes in this one (for easier auditing), but towards having round up/down only if necessary modes, rather than kludging around that situation with a double round as we do currently.
2014-11-14Fix missing return statement in deleted region scenario.David Robillard
2014-11-13Fix crash when deleting overlapped regions.David Robillard
Use RegionSelection for MIDI regions as well, since the old dumb stub didn't do some things correctly. There's probably no reason to have a separate class for this at all, and some good ones for putting all regions in the same selection, so we should probably do that. For now they are still separate in the selection but use the same base class.
2014-11-07use new canvas colors header as necessaryPaul Davis
2014-11-03use ArdourCanvas::TimeRectangle for regions, notes, markersPaul Davis
2014-10-21remove "canvasvar_" from all functions related to obtaining values from ↵Paul Davis
ARDOUR_UI::config()
2014-09-04Revert "cont'd work on automation-track headers (amend ba53af1c5)"Robin Gareus
This reverts commit beb5e3e777b0e92e8dde7ee12c324b32c679ff63.
2014-09-03cont'd work on automation-track headers (amend ba53af1c5)Robin Gareus
now that the separator line is at the top, offset region-contents y0 by 1px.
2014-06-25move utility functions into a dedicated namespaceRobin Gareus
2014-06-22more canvas refactoring.Paul Davis
Remove Canvas::Layout, use Canvas::Container for the same purpose, move child-rendering into Item::render_children() so that it could theoretically be used by any derived type.
2014-06-21use newly factored canvas in gtk2_ardourPaul Davis
2014-06-13rationalize and coordinate handle of region (time axis view item) opacity.Paul Davis
There are still some bugs with this because of the waveview image cache - fixes coming soon.
2014-06-09remove instances of RGBA_TO_UINT() macro from region_view.ccPaul Davis
2014-06-09substantial changes in color management, involving a reduction in the use of ↵Paul Davis
Gdk::Color and more consistent logic for region coloring. Group tabs now also get the text drawn in an appropriately contrast-y color
2014-06-05tweak logic for region coloring, particularly when mutedPaul Davis
2014-06-05hopefully fix up selection of color for region name text, under all conditionsPaul Davis
2014-06-03more profound changes to canvas scrolling, in particular find appropriate ↵Paul Davis
ScrollGroup for Canvas::{window,canvas}_to_{canvas,window}()
2014-04-16fix lack of region trimming when not displaying name highlight barPaul Davis
2014-01-10regionviews used for (MIDI) automation (CC) should not show a name highlightPaul Davis