13
0
Commit Graph

645 Commits

Author SHA1 Message Date
247bd4d3d9
NO-OP: whitespace 2020-04-10 18:32:18 +02:00
ede0fd3ddf
Remove hardcoded 2^15 cairo-boundary, prefer window-area 2020-04-10 18:28:26 +02:00
2177462b73
NO-OP: consistent function and variable naming 2020-04-10 18:06:42 +02:00
bc4de874dc
NO-OP: whitespace 2020-04-10 18:06:42 +02:00
9bbedcb781
Remove unused function
Cairo::curve_to renders cubic Bézier splines, those are not
generally useful in a DAW context.

Canvas::Curve implements centripetal catmull-rom spline drawing
which can be used for fades and automation interpolation.
2020-04-10 18:06:42 +02:00
7bb8ca1e76
Interpolate poly-line with view-point #6481 2020-04-10 18:06:41 +02:00
6cc1e5e75d
NO-OP: whitespace 2020-04-10 18:06:39 +02:00
f744b5fc12 change velocity bar inside notes to extend to edges of note
Having the velocity bar inset from note causes distracting space at beginning of note
when viewing a MIDI note that is zoomed out
2020-03-26 10:12:54 -06:00
4151ec1907 remove accumulated debug output 2020-03-25 15:12:30 -06:00
dbcf7dd666 more playhead-drag/click locate debugging 2020-03-25 13:50:23 -06:00
André Nusser
0a1ed004f2
Remove unused forward declaration. 2020-02-24 23:01:15 +01:00
06b2eb1c27
Explicitly use OSX
Previously this was inherited via PBD.

On MacOS/X,  this adds
  "-undefined dynamic_lookup -flat_namespace"
and various "-framework .." options to linkflags

Without this flag, .dylibs fail to link usually because
of missing `-lintl` (Undefined symbols: "_libintl_dgettext")

On other systems this is a NO-OP:
CFLAGS_OSX, CXXFLAGS_OSX and LINKFLAGS_OSX
are only set on the darwin platform.
2020-01-25 04:07:41 +01:00
bca825e515
NO-OP: whitespace 2020-01-14 00:52:24 +01:00
John Emmas
45dd6a8ed3 Add a missing semicolon 2020-01-05 10:29:35 +00:00
0b266a54f0
Return of image-surface backed canvas (windows graphics performance)
This partially reverts 2edbda2526.

Using cairo-groups increases performance on MacOS, and retains
retina-resolution.
However it adds a performance regression for MS Windows graphics
rendering. cairo-groups use a "similar" surface, not an image surface.
Empirically this adds significant overhead compared to rendering
using the CPU and using bitblt.
2020-01-04 00:30:07 +01:00
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
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
ecc2597870
Fix remaining doxygen warnings (!) 2019-09-30 21:03:29 +02:00
bfec73b8c3
NO-OP: whitespace, indent 2019-09-30 21:03:20 +02:00
5ec5bc4523 goodbye USE_TRACKS_CODE_FEATURES and is_tracks_build 2019-09-25 12:16:13 -06:00
cec5ce8f45
Update canvas/UI lib GPL boilerplate and (C) from git log 2019-08-03 15:53:17 +02:00
46f0b75e12
Undo more incorrect sample/frame replacements 2019-04-08 04:10:04 +02:00
c83ba53399
Remove ancient, unmaintained xcode project files 2019-02-28 18:12:44 +01:00
Andreas Müller
d2aa57af3b Prevent excessive meter redraws for inactive meters at zero II
Same as be826f3635

Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
2018-10-17 22:35:29 +02:00
8ed33f1bc7 remove use of hardcoded -fPIC compiler flag, and use compiler flag dict instead 2018-10-14 22:06:11 -04:00
cf652331ad Adapt our remaining MSVC projects for 'boost::atomic' (in case it later gets extended to the other libs)
Stage 3 of 3
2018-09-30 09:19:28 +01:00
79f01bc889 Initial changes needed for building Mixbus (with MSVC) as version 5
(Mixbus itself will probably need extra changes)
2018-09-10 07:14:59 +01:00
8664768efa make velocity bars thinner (from alex mitchell) 2018-07-08 07:12:12 -04:00
ab6525a24f Accommodate newly introduced source(s) in our MSVC project (cairocanvas) 2018-07-05 08:22:44 +01:00
bf2f4bd28a method for setting whether or not to show velocity bars 2018-07-03 15:39:08 -04:00
c190581552 fix rectangle computation, and re-use alex' color computation 2018-07-03 12:39:56 -04:00
21582828b7 add a guess at appropriate color management for note velocity display
I think that HSV::opposite() is probably too strong here. HSV::darker() might be better. Experimentation needed.
2018-07-03 11:43:42 -04:00
644a05f60b use new Canvas::Note object for (sustained) note display 2018-07-03 11:21:53 -04:00
ed24e01658 initial implementation of a more specialized canvas item for (sustained) notes 2018-07-03 11:21:25 -04:00
5102d8fae1 minor code optimization for Rectangle::render() 2018-07-03 09:22:32 -04:00
b9c9777b9a When building with MSVC, allow for the fact that Mixbus and Ardour can be using different versions of the SESSION_FILE format 2018-02-15 09:03:32 +00:00
6f019faaa0 Accommodate the change from libtimecode to libtemporal 2018-02-14 10:02:11 +00:00
30b087ab3d globally change all use of "frame" to refer to audio into "sample".
Generated by tools/f2s. Some hand-editing will be required in a few places to fix up comments related to timecode
and video in order to keep the legible
2017-09-18 12:39:17 -04:00
36046cccc1 add basic data members and methods for adding an explicit size allocation for Canvas::Item 2017-09-18 11:40:52 -04:00
951404475c MSVC changes needed to implement the new 'waveview' library 2017-07-19 08:20:18 +01:00
9a0a2a29b5 Fix NSGLView invalidation 2017-07-18 21:34:03 +02:00
beb73edf55 Purify libcanvas, remove libardour dependency
A canvas is just a canvas. Move WaveView into its own library.
2017-07-17 21:06:04 +02:00
601c317d70 Clean up library inheritance (colors.h, utils.h)
make libwidget independent of libcanvas.
Confine basics to pbd and gtkmm2ext.
2017-07-17 21:06:04 +02:00
33d30fdf57 Accommodate newly introduced source(s) in our MSVC project (cairocanvas) 2017-06-29 10:10:26 +01:00
d3510b5606 fix OSX builds (llmath compat) 2017-06-28 03:03:05 +02:00
a1cd4f8dfe Fix friend declaration in WaveView code for non-c++11 builds 2017-06-26 17:04:18 +10:00
6e91ee071c Reimplementation of large parts of the WaveView class
The drawing itself should be unchanged but much of the rest of the
implementation has changed. The WaveViewThreads and WaveViewDrawingThread
classes were added and allow multiple drawing threads.

The Item::prepare_for_render interface is implemented by WaveView to enable
queuing draw requests for the drawing threads to process as soon as the state
change occurs during Editor::visual_changer, which often means the images will
be finished by the time they are needed in WaveView::render. This can
significantly reduce total render time and also flickering caused by images not
being ready for display.

If the drawing thread/s cannot finish the request by the time it is required in
WaveView::render then cancel it and draw the WaveViewImage in the GUI thread if
it is likely it can be completed in the current render pass/frame.  This change
also helps reduce the flickering caused by images not being ready with threaded
rendering, but with several drawing threads, drawing in the GUI thread may not
often occur (unless explicitly requested).

Allow unfinished images to be returned from the cache in
WaveView::prepare_for_render so that new draw requests aren't queued for
duplicate images. This reduces the amount of drawing for instance in
compositions where there are many instances of the same sample/waveform
displayed on the canvas as only a single image should be drawn.

Use a random width within a certain range for
WaveView::optimal_image_width_samples so that image drawing is less likely to
occur at the same time (which will cause a spike in render/draw time and
increase the chance of flickering waveforms).

Move implementations of the private WaveView classes into wave_view_private.h
and wave_view_private.cc source files.

Incorporate a fix for limiting the waveview image size to the cairo image size
limit.

Should hopefully Resolve: #6478
2017-06-26 08:40:47 +10:00
4ddf97f5a2 Add Canvas::get_microseconds_since_render_start() method
Initial use is for the WaveView class to determine whether on not to draw the
waveform in the GUI thread.
2017-06-26 08:40:47 +10:00
ab13e87ec2 Add Canvas::get_last_render_start_timestamp method 2017-06-26 08:40:47 +10:00
8538ba35fe Only call Gtk::Widget::queue_draw_area in canvas when item and visible area intersect
Refactor GtkCanvas::request_redraw to use Rect::intersection
2017-06-26 08:40:47 +10:00