[CM] CMN - weird accent placement

Bill Sack bsack23@gmail.com
Sat, 14 Apr 2007 23:41:13 -0400


------=_Part_28322_22903349.1176608473954
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

i'll try to get through the list over the next few days - i'll go through
the Gardner Read book and see what he has to say ...

thanks for the fix.

b


On 4/14/07, andersvi@extern.uio.no <andersvi@extern.uio.no> wrote:
>
> >>>>> "B" == Bill Sack <bsack23@gmail.com> writes:
>
>     B> CMN seems to be putting accents above the staff no matter
>     B> what. I tried the test case in cmn1.lisp and there seem to be
>     B> similar problems with little-swell, down-bow, up-bow and some
>     B> others.  Shouldn't the default, for accent at least, be
>     B> opposite the stem direction? i don't recall this being a
>     B> problem before - i wonder if it's recently broken ...
>
>     B> bill sack
>
> Dont know when this crept in, but at least accents should be placed
> opposite stems.  The fix is easy, put a test on
>
>   '(direction-from-note mark note)'
>
> to check for direction. ie:
>
> (defun display-accent (mark note score &optional justifying)
>   (declare (ignore justifying))
>   (let ((dir (direction-from-note mark note)))
>     (show score mark
>           :matrix (translate-matrix
>                    score mark
>                    (+ (box-x0 note) (vis-dx mark) (center note) -.2 (x0
> mark))
>                    (+ (box-y0 mark) (vis-dy mark)
>                       (if (eq dir :down)
>                           (+ (staff-y0 note) (min (* (- (head-line note)
> 4) *staff-line-separation*) -.5))
>                         (max (+ (or (stem-end note) 0) .125)
>                              (+ (staff-y0 note)
>                                 (* (max 10 (+ 3 (head-line note)))
>                                    *staff-line-separation*)))))))))
>
>
> But some marks are placed above staff by default.  If someone could
> compile or link to a list of default-placement for the marks (and
> ideally all marks in accent.lisp as well):
>
>               staccato
>               accent
>               little-swell
>               edge
>               tenuto
>               marcato
>               down-bow
>               up-bow
>               detache
>               martele
>               thumb
>               natural-harmonic
>               bartok-pizzicato
>               stopped-note
>               open-note
>               left-hand-pizzicato
>
> and fill in default direction (ie: opposite-stem/up/down) for the
> various marks, it would be a rather small job going through the
> various #'display-some-mark programs which needs fixing (i think...)
> Anyone?
>
> -anders
>

------=_Part_28322_22903349.1176608473954
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

i&#39;ll try to get through the list over the next few days - i&#39;ll go through the Gardner Read book and see what he has to say ... <br>
<br>
thanks for the fix.<br>
<br>
b<br>
<br><br><div><span class="gmail_quote">On 4/14/07, <b class="gmail_sendername"><a href="mailto:andersvi@extern.uio.no">andersvi@extern.uio.no</a></b> &lt;<a href="mailto:andersvi@extern.uio.no">andersvi@extern.uio.no</a>
&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">&gt;&gt;&gt;&gt;&gt; &quot;B&quot; == Bill Sack &lt;<a href="mailto:bsack23@gmail.com">
bsack23@gmail.com</a>&gt; writes:<br><br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; CMN seems to be putting accents above the staff no matter<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; what. I tried the test case in cmn1.lisp and there seem to be<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; similar problems with little-swell, down-bow, up-bow and some
<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; others.&nbsp;&nbsp;Shouldn&#39;t the default, for accent at least, be<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; opposite the stem direction? i don&#39;t recall this being a<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; problem before - i wonder if it&#39;s recently broken ...<br>
<br>&nbsp;&nbsp;&nbsp;&nbsp;B&gt; bill sack<br><br>Dont know when this crept in, but at least accents should be placed<br>opposite stems.&nbsp;&nbsp;The fix is easy, put a test on<br><br>&nbsp;&nbsp;&#39;(direction-from-note mark note)&#39;<br><br>to check for direction. ie:
<br><br>(defun display-accent (mark note score &amp;optional justifying)<br>&nbsp;&nbsp;(declare (ignore justifying))<br>&nbsp;&nbsp;(let ((dir (direction-from-note mark note)))<br>&nbsp;&nbsp;&nbsp;&nbsp;(show score mark<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:matrix (translate-matrix<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; score mark<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
(+ (box-x0 note) (vis-dx mark) (center note) -.2 (x0 mark))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
(+ (box-y0 mark) (vis-dy mark)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(if
(eq dir :down)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(+
(staff-y0 note) (min (* (- (head-line note) 4) *staff-line-separation*)
-.5))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(max
(+ (or (stem-end note) 0) .125)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
(+ (staff-y0 note)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(*
(max 10 (+ 3 (head-line note)))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
*staff-line-separation*)))))))))<br><br><br>But some marks are placed above staff by default.&nbsp;&nbsp;If someone could<br>compile or link to a list of default-placement for the marks (and<br>ideally all marks in accent.lisp as well):
<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;staccato<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;accent<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;little-swell<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp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bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;left-hand-pizzicato<br><br>and fill in default direction (ie: opposite-stem/up/down) for the
<br>various marks, it would be a rather small job going through the<br>various #&#39;display-some-mark programs which needs fixing (i think...)<br>Anyone?<br><br>-anders<br></blockquote></div><br>

------=_Part_28322_22903349.1176608473954--