Hi Martin,

[...]
> It make sense, the GridCoverage2D constructor may invokes some RenderedImage
> that trigs the tile computation. However each tile should be computed only 
> once,
> unless there is no TileCache or the TileCache is full.
>
> I would suggest to first make sure that there is a TileCache. The default tile
> cache should be used automatically (if I remember well), but as a safety you 
> can
> specify it explicitly:
>
>    TileCache tc = JAI.getDefaultInstance().getTileCache();
>    RenderingHints hints = new RenderingHints();
>    hints.put(JAI.KEY_TILE_CACHE, tc);
>
> and pass those hints to whatever "create" method you use for creating your
> image. If you use the standard JAI.create method, it seems to me that the tile
> cache hint should be added automatically. But if you instantiate your
> PointOpImage directly, you may need to provide the tile cache hints yourself 
> in
> your RenderingHint map.

I am using the JAI.create and in fact I thought the TileCache should
be used by default. I also used the method you report above to specify
the tilecache and also set some more memory to it in order to be sure
that it is ok. But nevertheless also with very small images the thing
got triggered more than once.

But now that you take away my doubt about how it should be, I will try
to see if I can find where I do something wrong.

> If you really have a TileCache, check if it is full (there is methods in
> TileCache interface for checking the amount of bytes used).

TileCache is something I would like to implement with a
"geomorphologic knowledge" at some point, but before I want to make
sure that the rest of things work :)


Thanks and congratulations for your (& friends) job on geoapi at OGC.
Andrea

>
>        Martin
>

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to