Fix some compilation warnings
use C++ std function for max()
Squashed commit of the following:

commit fdbae82077db53add90df7448a06869dac89acc6
Author: Paul Davis <paul@linuxaudiosystems.com>
Date:   Wed Mar 27 21:45:28 2013 -0400

    mammoth changes in basic signal flow, total redesign of MIDI channel filtering and more.

commit 59343a8283698e02bc0f622313b29e98f449e4c8
Author: Paul Davis <paul@linuxaudiosystems.com>
Date:   Wed Mar 27 01:58:53 2013 -0400

    initial working version after changes to MIDI channel filtering. may affect metering input too. testing not yet finished

this commit merges many deep changes in ardour's internal architecture,
combined with a total redesign of how MIDI channel filtering works.

data in a track used to flow from JACK port buffers to diskstream's ringbuffers
and was then copied from the ringbuffers into a BufferSet for use during
Route::process_output_buffers(). The butler thread would handle the movement of
data between the ringbuffers and disk.

with this commit, data now flows from JACK port buffers into the BufferSet used
for Route processing, and is copied from the BufferSet into the diskstream's
ringbuffers (the butler thread continues to handle interactions with disk as
usual).

this change allowed a dramatic consolidation of code and simplification of most
aspects of Track/Route::roll() and Track/Route::no_roll(). in particular, see
Route::fill_buffers_with_input() which now concisely describes how we move data
from JACK port buffers into the BufferSet for all Route types (including Tracks).

this work was initially motivated by changing MIDI channel filtering so that we
can process capture and playback independently. there is now a very clean
pathway for this - see MidiTrack::roll() (NOTE: This needs implementing in the
no-roll case too - a TODO item).

the channel selector for MIDI tracks has been moved out of the track header and
is now accessible via the context menu. more work is likely here, to make it
(more) obvious to the user when filtering is going on.
vtl: prepare simple/advanced usage modes

"simple": localhost only system; hide much of the setup complexity
"advanced":' allow for remote-server, paths mapping, server index etc.
vtl: rc config dialog for simple/advanced config
vtl: simple/localhost mode.

Hide most of the setup complexity that is irrelevant when
running the video-server on the same host as Ardour.

Add an abstraction layer to the config which will become
important later when /building in/ the video-server.
little extra debugging to show discovered LXVST .so's
Merge branch 'master' of git.ardour.org:ardour/ardour
vtl: prepare audio offset on A/V import
vtl: debug xjadeo communication
minor fix for misleading comment
vtl: hide audio-import button when import/processing started
vtl: fflush stdout/in after writing to external process
some deep tweaking to get MIDI channel control into nearly done shape for 3.1
vtl: fix possible race condition when terminating external program
vtl: add close/remove video menu entry
vtl: amend  0c2d95b - fix possible race condition when terminating external program
vtl: update ffprobe csv parsing
vtl: rework import workflow

 - do not allow to simply copy the video file
 - decision to transcode or just reference is made in "transcode dialog"
   not during file-selection.
   Only there the actual codec is known and can be judged to be suitable
   for direct reference
 - simplify "transcode dialog" - no more buttons for specific actions,
   drop-down select actions.
 - increase minimum bitrate for imported file to 500kbit/s
vtl: workaround xjadeo <= 0.6.4 issue