lilypond-devel
[Top][All Lists]
Advanced

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

Re: Gets vertical skylines from grob stencils (issue 5626052)


From: address@hidden
Subject: Re: Gets vertical skylines from grob stencils (issue 5626052)
Date: Fri, 10 Feb 2012 18:16:50 +0100

On Feb 10, 2012, at 5:55 PM, David Kastrup wrote:

> address@hidden writes:
> 
>> 
>>> I immediately agree that it is a
>>> nuisance to first do the work of coding this, then do the work of
>>> replacing it again, then check that the replacement also works.  It
>>> would have been nicer if I had thought of this earlier.
>>> 
>> 
>> There is absolutely no problem at all - I would much rather use a
>> stable and robust library if it's available.  However, the operations
>> are so minimal and simple that the thought didn't even occur to me not
>> to implement them myself (it's taking me longer to write this e-mail
>> than it took me to write the code).  If you think that Pango can do
>> the job of what's in stencil-integrate.cc, lemme know.  I don't see
>> anything in the library that seems designed for this, but I of course
>> could have missed something.
> 
> Look in pango-matrix.h for the transforms.
> 
> I skimmed over the actual code, and at the current point of time it is
> nothing particularly optimized: it almost looks like a copy of your code
> right now.  I'd still prefer a wrapper for that (it's not inconceivable
> that we might want to pass these into Pango rendering at one time, and
> not having to copy anything would be an advantage) to our own code.
> 

The problem is that the Pango API does not allow multiplication between two 
arbitrary matrices.  I like the openness of the one I've created, and if we 
lock ourselves into using Pango, then we close off this openness (for example, 
if we ever want to implement skewX or skewY it'd be difficult whereas w/ my 
affine transformation functions it is a one-liner).

I do see what you're saying, though, about eventually using Pango matrices.  If 
it's all right w/ everyone, I'd rather keep this version for now and use Pango 
if necessary later down the line.

Cheers,
MS


reply via email to

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