Re: Piano Pedal performace across a PianoStaff

2004-04-06 Thread Edward Sanford Sutton, III
On Tuesday April 6 2004 03:02, Han-Wen Nienhuys wrote:
> [EMAIL PROTECTED] writes:
> > A pedal-event is currently performed by the staff context within
> > which it is declared.  As a piano's pedal tends to affect the entire
> > output of the piano and not just one hand, it would be nice if
> > pedal-events could be automatically performed across the staves in a
> > PianoStaff.  My instinct was to use the following:
> >
> > \context {
> > \VoiceContext
> > \remove "Piano_pedal_performer"
> > }
> > \context {
> > \PianoStaffContext
> > \consists "Piano_pedal_performer"
> > }
> >
> > but I can see that I was wrong.  What would be necessary to make
> > something like this work?  I am willing to code it, but I would
> > appreciate a push in the right direction.
>
> It's probably the easiest to make a Piano_pedal_swallow_performer that
> sits at the piano-staff level, and have that scoop up the events. Then
> have Piano_pedal_performers at staff level. This is similar to
> Repeat_engraver which cooperates with the Repeat_acknowledge_engraver.
>
>
> Let me know if you have more questions!

  I thought about this recently for both dynamic and pedal marks. I thought 4 
tracks (RH, LH, dynamics, pedal) on one channel would distribute all the 
changes. Either my midi knowledge is wrong or/and that couldn't work well 
about how a mark would be handled if it applied to only one line. I don't 
want to start hate mail and fired discussions, but better notational & midi 
knowledge is something I can always use so . . .
Thanks again,
Ed Sutton


___
Lilypond-devel mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/lilypond-devel


Piano Pedal performace across a PianoStaff

2004-04-06 Thread Han-Wen Nienhuys
[EMAIL PROTECTED] writes:
> A pedal-event is currently performed by the staff context within
> which it is declared.  As a piano's pedal tends to affect the entire
> output of the piano and not just one hand, it would be nice if
> pedal-events could be automatically performed across the staves in a
> PianoStaff.  My instinct was to use the following:
> 
>   \context {
>   \VoiceContext
>   \remove "Piano_pedal_performer"
>   }
>   \context {
>   \PianoStaffContext
>   \consists "Piano_pedal_performer"
>   }
> 
> but I can see that I was wrong.  What would be necessary to make
> something like this work?  I am willing to code it, but I would
> appreciate a push in the right direction.

It's probably the easiest to make a Piano_pedal_swallow_performer that
sits at the piano-staff level, and have that scoop up the events. Then
have Piano_pedal_performers at staff level. This is similar to
Repeat_engraver which cooperates with the Repeat_acknowledge_engraver.


Let me know if you have more questions!

-- 

 Han-Wen Nienhuys   |   [EMAIL PROTECTED]   |   http://www.xs4all.nl/~hanwen 



___
Lilypond-devel mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/lilypond-devel


Re: Piano Pedal performace across a PianoStaff

2004-04-06 Thread Mats Bengtsson
Interesting, you get a SIGSEGV!

However, if you replace "Piano_pedal_performer" with
"Piano_pedal_engraver", LilyPond will process the file without
crashing. Still, it doesn't do what you want.
The next time, you try these things, remember that "_performer":s
deal with MIDI file creation, whereas "_engraver":s deal with
paper typesetting. To see the default definition of the contexts,
take a look at the file ly/engraver-init.ly.
Here's a full example file for those who want to try it out more.

\version "2.2.0"

upper = \notes\relative c'' {
  c4 d e \sustainDown b |
  c c, \sustainUp \sustainDown  d8[ c]  e8[ e \sustainUp \sustainDown] |
}
lower = \notes\relative c {
  c1
  d1
  f4 d \sustainUp g \sustainDown b |
  b, \sustainUp c'
}
\score {
  \context PianoStaff <<
\set PianoStaff.instrument = "Piano  " % set instrument name.
\context Staff = upper \upper
\context Staff = lower <<
  \clef bass
  \lower
>>
  >>
  \paper {
\context {
\VoiceContext
\remove "Piano_pedal_engraver"
}
\context {
\PianoStaffContext
\consists "Piano_pedal_engraver"
}
 }
  \midi { }
}
   /Mats

Michael Welsh Duggan wrote:
A pedal-event is currently performed by the staff context within
which it is declared.  As a piano's pedal tends to affect the entire
output of the piano and not just one hand, it would be nice if
pedal-events could be automatically performed across the staves in a
PianoStaff.  My instinct was to use the following:
\context {
\VoiceContext
\remove "Piano_pedal_performer"
}
\context {
\PianoStaffContext
\consists "Piano_pedal_performer"
}
but I can see that I was wrong.  What would be necessary to make
something like this work?  I am willing to code it, but I would
appreciate a push in the right direction.
--
=
Mats Bengtsson
Signal Processing
Signals, Sensors and Systems
Royal Institute of Technology
SE-100 44  STOCKHOLM
Sweden
Phone: (+46) 8 790 8463 
Fax:   (+46) 8 790 7260
Email: [EMAIL PROTECTED]
WWW: http://www.s3.kth.se/~mabe
=
___
Lilypond-devel mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/lilypond-devel


Piano Pedal performace across a PianoStaff

2004-04-06 Thread Michael Welsh Duggan
A pedal-event is currently performed by the staff context within
which it is declared.  As a piano's pedal tends to affect the entire
output of the piano and not just one hand, it would be nice if
pedal-events could be automatically performed across the staves in a
PianoStaff.  My instinct was to use the following:

\context {
\VoiceContext
\remove "Piano_pedal_performer"
}
\context {
\PianoStaffContext
\consists "Piano_pedal_performer"
}

but I can see that I was wrong.  What would be necessary to make
something like this work?  I am willing to code it, but I would
appreciate a push in the right direction.

-- 
Michael Welsh Duggan
([EMAIL PROTECTED])


___
Lilypond-devel mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/lilypond-devel