'Starts a MidiCaptor to compile incoming messages into a NoteSequence.
If neither `stop_time` nor `stop_signal`, are provided, the caller must
explicitly stop the returned capture thread. If both are specified, the one
that occurs first will stop the capture.
Args:
qpm: The integer quarters per minute to use for the captured sequence.
start_time: The float wall time in seconds to start the capture. May be in
the past. Used for beat alignment.
stop_time: The optional float wall time in seconds to stop the capture.
stop_signal: The optional mido.Message to use as a signal to use to stop
the capture.
Returns:
The MidiCaptor thread.'

def start_capture(self, qpm, start_time, stop_time=None, stop_signal=None):

    captor_class = (MonophonicMidiCaptor if (self._texture_type == TextureType.MONOPHONIC) else PolyphonicMidiCaptor)
    captor = captor_class(qpm, start_time, stop_time, stop_signal)
    with self._lock:
        self._captors.append(captor)
    captor.start()
    return captor
