harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Igor Stolyarov" <igorvstolya...@gmail.com>
Date Thu, 27 Jul 2006 06:24:40 GMT
Hi folks!

I want to discuss AWT 2D Performance Issue, especially performance of the
BufferedImage rendering.

In order to recieve best performance we have to use hardware acceleration.
Thus is appearing good thought using DirectDraw or Direct3D Surface as cache
of BufferedImage Raster for rendering operations. In other words all drawing
operations for BufferedImage Graphics we are doing on the BufferedImage
cache and then draw BufferedImage cache on the screen with hardware
acceleration. But sometimes we need Java access to the Raster, for example
BufferedImage has getRGB and setRGB methods. Appear synchronization issue.
We can use flags that inform us about cache or Raster was chaneged, after
that we have to update cache or Raster. But customer can to recieve full
access to the DataBuffer data (DataBuffer classes have getData methods which
return link for arrays which store data) and we don't know when customer
release data. Thus we have to update cache before each rendering operation
what will slow down performance. I have done package private class which can
safely give and release link for DataBuffer data and we can use this class
for our private API, but end customer know nothing about this possibility

Have anybody ideas about how solve this problem. Wellcome to the discussion.

Best regards,

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message