You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by COFFMAN Steven <SC...@CBSINC.com> on 2000/11/27 18:54:31 UTC

SVG:gradientTransform:matrix math help

Can someone check my math and understanding of SVG?

In gradientTransform="matrix(a b c d e f)", their is actually another row to
the matrix that is always the same. So the transformation matrix is
actually:
[ a c e ]
[ b d f ]
[ 0 0 1 ]

Call this matrix "M".

You're supposed to mulitply this by the user space coordinates to yield the
viewport space coordinates (which also has an extra row). Now here's the
part that I'm not sure about.
Is the User space coordinate matrix (call it 'U1') like this:
[ x1 ]
[ y1 ]
[ 1  ]

So that M*U1 = V1 (the viewport space x1 and y1)?
And then you do M*U2 = V2.

Is that right? Or should U1 be:
[ x1 ]
[ x2 ]
[ 1  ]

If I'm correct, then the code should be pretty easy. If I'm wrong, then I'm
completely confused. Please send me a clue.
-Steve
-----Original Message-----
From: COFFMAN Steven [mailto:SCoffman@CBSINC.com]
Sent: Monday, November 27, 2000 10:00 AM
To: 'fop-dev@xml.apache.org'
Subject: RE: bugs and test files


Hi Dorothea,

If you want to get SVG's gradientTransform to work in PDF it would be
really, really cool, and it would give you familiarity with the SVG part of
FOP if you wanted to port it to the AWTRenderer later. It would let us use
the Apache feather in documents finally!

-Steve

-----Original Message-----
From: Dorothea Wiarda [mailto:wiarda@vic.com]
Sent: Saturday, November 25, 2000 9:11 PM
To: fop-dev@xml.apache.org
Subject: Re: bugs and test files


Fotis Jannidis wrote:
> 
> I committed that fix. I am not sure about Doro's other bug fix,
> because I didn't check the static stuff. Maybe Arved or somebody
> who has been there could check her fix and commit it. If it is lost I
> can repost it.

Thank you,
  I am not so sure about the other fix either, precisely because I did
not understand what exactly static position is. However, I thought
pinpointing where the error occurs might somebody else give an idea how
to solve it.

   Any suggestion where I should turn my attention next. I was thinking
maybe AWTRenderer and SVG, but I take other suggestions. 

  Doro

________________________________________________________
Dorothea Wiarda

E-Mail:    wiarda@dwiarda.com
Web-Home:  http://www.dwiarda.com
           http://www.techno-info.com