[kaffe] Re: Is BufferedImage supported in Kaffe?

Dalibor Topic robilad@yahoo.com
Fri May 16 04:52:01 2003


Hallo Torsten,

--- Torsten_Hübscher <Torsten.Huebscher@gmx.net> wrote:
> Hello!
> 
> No, forget about this. I have tried this (exactly the same) a few weeks 
> ago ending up frustrated.

Thanks for clearing it up. I haven't really worked on the AWT implementation
(beside some small bugfixes, and merges) so I am not aware how much work it is
to actually come up with a Graphics2D implementation for kaffe.

Could you elaborate on the difficulties you came accross?
 
> Kaffe uses a mixture of own libs and libs from other projects like GNU 
> classpath. If you check the source-code of the implementation, you'll 
> find empty methods and things like "throw new error("not implemented") 
> ". I had to cross-check kaffe, classpath, SUN for the "best" 
> implementation, but it's to hard to spend the time on this, because 
> things are moving to fast.

I'm trying to mix and match best free software implementations out there in
kaffe's class library. But there usually aren't that many implementations to
pick from ;)

On the other hand, with things moving rather quickly, it may all look different
in a couple of months.

> I mailed with dalibor and classpath about it, (this behavior is quite 
> senseless), but so they do pass simple compatibility tests with SUNs JDK.

Classpath does it (have unimplemented methods return silently, or throw runtime
exceptions) so you can at least compile against the class library. I think that
policy is largely influenced by debian 'free-vs-non-free' policy, meaning a
package can only enter the 'free packages' distribution, when  it can be built
without depending on non-free packages.

I'm following Classpath where I can merge their code without breaking other
features. Sometimes, that's not possible, so the code stays out of kaffe. For
example, kaffe can use Sun's swing 1.1.1 implementation, so merging in
Classpath's skeletal swing implementation would not be very useful ;)

With Java2D, while Classpath's implementation is incomplete, it's 'better than
nothing'. There is no other Java2D implementation that could be used with
kaffe, so I'm taking the implementation from Classpath in hope that it will
grow more complete with time. I understand your frustration with the state of
affairs, but there is not much we can do, except trying to improve on what's
there.

Anyway, speaking of Graphics2D implementations, here are some that could be
useful as starting points:
itext: http://www.lowagie.com/iText/ [lgpl] ... see
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/itext/src/com/lowagie/text/pdf/PdfGraphics2D.java?rev=1.18&content-type=text/vnd.viewcvs-markup

freehep: http://java.freehep.org/index.html [lgpl] ... see
http://java.freehep.org/jcvslet/JCVSlet/show/freehep/freehep/org/freehep/graphics2d/PixelGraphics2D.java/1.29

cheers,
dalibor topic

__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com