Skip to main content

ImageIO Mac OS X

4 replies [Last post]
helicopter
Offline
Joined: 2004-07-04
Points: 0

Hello,
is a native layer for jpeg loading available for Mac OS X ? Loading some JPEG-Images seems to be slow using Mac OS X Tiger. The loading of one Jpeg-Image (20-30kb) takes 80ms (imac G5 / PPC). By way of comparison the same image takes 5-10ms using Linux.
Regards,
Thomas

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
jxc
Offline
Joined: 2005-02-24
Points: 0

Maybe the Java SE builtin JPEG plugin from Apple already uses some kind of
native library, such as libjpeg, if it's similar to the Java SE from Sun. You have
to consult Apple for a sure answer.

The JPEG plugin in JAI Image I/O Tools is currently not available on Mac OS X.
You can vote for this issue if you'd like to have it available in a future release:
https://jai-imageio-core.dev.java.net/issues/show_bug.cgi?id=103
But it's unlikely that we'll have resources to tune the native library for the G5
processor. It's more likely to be a Universal library, with MMX/SSE code for x86
if possible.

Thanks,
-James

helicopter
Offline
Joined: 2004-07-04
Points: 0

For all those interested in: It seems the JPEG loading using Mac OS X / Java SE is very poor. It is native but the C code isn't optimized using SSE (Intel) or AltiVec (PPC) instructions which makes a huge difference!

Benchmark loading some 30-50kb JPEG using ImageIO.read()

Pentium 4 / Ubuntu Linux 6.10

3-9ms

G5 1,8 Single / Mac OS X Tiger

50-90ms

best Regards,
Thomas

Brian Burkhalter

Presumably you are referring to the JPEG reader in the build of Java SE
distributed by Apple.

Brian

On Mon, 5 Mar 2007, jai-imageio@javadesktop.org wrote:

> For all those interested in: It seems the JPEG loading using Mac OS X / Java SE is very poor. It is native but the C code isn't optimized using SSE (Intel) or AltiVec (PPC) instructions which makes a huge difference!
>
> Benchmark loading some 30-50kb JPEG using ImageIO.read()
>
> Pentium 4 / Ubuntu Linux 6.10
>
> 3-9ms
>
> G5 1,8 Single / Mac OS X Tiger
>
> 50-90ms
>
> best Regards,
> Thomas
> [Message sent by forum member 'helicopter' (helicopter)]
>
> http://forums.java.net/jive/thread.jspa?messageID=206169
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: interest-unsubscribe@jai-imageio.dev.java.net
> For additional commands, e-mail: interest-help@jai-imageio.dev.java.net
>
>

----------------
Brian Burkhalter
Java Media, Imaging, and Graphics
Sun Microsystems, Inc.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This email message is for the sole use of the intended recipient(s)
and may contain confidential and privileged information. Any
unauthorized review, use, disclosure or distribution is prohibited.
If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@jai-imageio.dev.java.net
For additional commands, e-mail: interest-help@jai-imageio.dev.java.net

helicopter
Offline
Joined: 2004-07-04
Points: 0

Right, there's no JAVA SE build for Mac distributed by Sun ;-) The JPEG Reader used in the Java SE build by Apple is poor.