Well I haven't done this yet, but it should work. But you would have to change
the original source code provided by Sun to change the methods to native method
(there might be a problem with the license from SUN - you should check this
with SUN before).

Then you should be able to link them against native libraries.
I.e. for the jdk1.3 (standard edition) you would have to mark the drawImage
function as native, derive the header files with a call to javah and then
implement the native code as c-code, create a native library and link it to the
class in runtime with using the loadLibrary functionality.

For the j2me it should work similar - the only difference might be that you
link native function calls using either a native library or modified java
engine against the operating device functions. I am not sure how many portable
devices will support linking against shared libraries (I don't know any). The
java engine I have for my palm is linked against the palm operating system as
far as I know.

Source code is provided for most implementations, but this is really a hard
task to do.
You have to make sure that all transformations work correctly, that clipping
works correctly, that color corrections are going in place and that the calls
are executed at the correct position inside the pipeline.

I am not really sure, if it worth the efforts to maintain some code on yourown.
The new jdk1.4 release (beta is out as far as I know) promised to raise the
speed of the Graphics2D pipeline to a higher level.

So just by using jdk1.4 you should gain a speed raise. Implementing something
in native code will have ever the same speed - even if the java engine or some
core classes were changed to higher speed - except you change/adapt your own
code too.
I would not recommend doing that.

But perhaps you can just browse throught he source code of the midp4palm
edition. They provide full c-code for the midlet engine. I guess (haven't
checked) that they link most function directly against palm os functionality
inside the core engine for speed reasons.

Karsten

>         Hello all,
>         I am currently developping an application on embedded system, using
> java2d to render our business objects. I would like to use some hardware
> accelaration on some specific methods of java2d api, but I am wondering
> myself if, in despite of the pipeline architecture of java2d implementation,
> it is possible in a proprietary JVM (who respects this architecture) to link
> a call to graphics2d.drawImage(...) (for instance) to a native call other
> than X11 library?
> Thanks for your help,
>
> Florence.
> SIEMENS-VDO Automotive
> Sophia-Antipolis, France
> mailto:[EMAIL PROTECTED]
>
> ===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff JAVA2D-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".

--
Karsten Trott
Technical Lead, Intuitive Design Interface , Get2Chip.com, Inc.
Staff R&D Engineer
Phone: +49-89-5908-2333
Fax:   +49-89-5908-1328

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to