denemo-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Denemo-devel] Playback with repeats


From: Richard Shann
Subject: Re: [Denemo-devel] Playback with repeats
Date: Sun, 26 May 2013 17:56:49 +0100

Play back with repeats is now in git, you will find it under the Plaback
menu, called Performance.
It requires a first time bars to be marked with a different tag, so old
files will not observe these until the first time bar marker is renewed
(delete and re-insert is the easiest).
I would be interested to hear how this performs on slower machines, as
it uses a very simple mechanism of playing each section with clearing of
the playback queues between each section. It is working nicely on my
machine. Though the display is not scrolled back when a repeat happens -
perhaps I can fix that in the script.

Richard



On Sat, 2013-05-25 at 10:23 +0100, Richard Shann wrote:
> I just realized how to do playback with repeats, I have created a sample
> script which does the simple case of one repeat barline somewhere after
> the start. It will need first and second time bars and repeat start
> barlines, and then some C to play all the bits in a less clunky way on
> slow machines...
> Here is my first draft:
> 
> ;PlayWithRepeats
> (d-CreateTimebase)
> (d-MoveToBeginning)
> (let ((timings '())(start-repeat 0.0)(end-repeat #f)(timing 0.0))
>   (while (d-NextObject)
>     (if (d-GetMidiOffTime)
>       (set! timing (d-GetMidiOffTime)))
>       (disp "MIDI off time " timing " ok")
>     (cond
>       ((Music?)
>           (disp "music"))
>       ((d-Directive-standalone? "RepeatEnd")
>           (set! end-repeat timing)
>           (disp "Midi repeat from " end-repeat " ok")
>           (set! timings (cons (cons start-repeat end-repeat) timings))
>           (disp "timings now " timings " ok")
>           (set! start-repeat end-repeat)
>           (set! end-repeat #f))
>     )
>   )
> (disp "timings is this list " timings " ok")
> (d-SetPlaybackInterval (car (car timings)) (cdr (car timings)))
> (d-Play
>   (string-append "(d-SetPlaybackInterval " (number->string (car (car
> timings))) " " (number->string timing) ") (d-Play)"))
> )
> 
> Does anyone want playback with repeats? Not very useful if you just want
> to check the notes are entered correctly by ear... but Nils put it on
> the wish list before he left.
> 
> Richard
> 
> 
> 
> _______________________________________________
> Denemo-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/denemo-devel





reply via email to

[Prev in Thread] Current Thread [Next in Thread]