Hi,
I am creating a program to convert a feature collection (shape, gml, etc) into
a GridCoverage2D object. Using the rendering classes from geotools2 I am able
of generating an image from the vector data. But I am having problems to pass
the data from this image to the GridCoverage2D object.
One way to achive this (creating the GridCoverage2D) is using this:
GridCoverageFactory gcf = new GridCoverageFactory();
GridCoverage2D gc = gcf.create("Grid Name", matrix, envelope);
Where matrix is a float matrix whose values are coming from the image rendered
from the feature collection and the envelope data should be the same coming
from the feature collection.
The problem is that I can't pass directly the envelope from the feature
collection since it is not compatible with the parameter received in the create
function.
That is, feature collection returns an Envelope of type
com.vividsolutions.jts.geom.Envelope, but the create function needs an envelope
of type org.opengis.spatialschema.geometry.Envelope.
Any idea of how passing from one to the other?
Thanks in advance,
Miguel Ángel
--------------------------------------------
Consultant
Atos Research and Innovation
Consulting and Public Sector
Atos Origin Spain
Albarracin, 25
E-28037 Madrid
Telephone: +34 91214 8805
Fax: +34 91754 3252
http://www.atosorigin.com <http://www.atosorigin.com>
------------------------------------------------------------------
This e-mail and the documents attached are confidential and intended solely
for the addressee; it may also be privileged. If you receive this e-mail
in error, please notify the sender immediately and destroy it.
As its integrity cannot be secured on the Internet, the Atos Origin group
liability cannot be triggered for the message content. Although the
sender endeavours to maintain a computer virus-free network, the sender does
not warrant that this transmission is virus-free and will not be liable for
any damages resulting from any virus transmitted.
Este mensaje y los ficheros adjuntos pueden contener informacion
confidencial destinada solamente a la(s) persona(s) mencionadas
anteriormente. Pueden estar protegidos por secreto profesional Si usted
recibe este correo electronico por error, gracias de informar inmediatamente
al remitente y destruir el mensaje.
Al no estar asegurada la integridad de este mensaje sobre la red, Atos
Origin no se hace responsable por su contenido. Su contenido no constituye
ningun compromiso para el grupo Atos Origin, salvo ratificacion escrita por
ambas partes.
Aunque se esfuerza al maximo por mantener su red libre de virus, el emisor
no puede garantizar nada al respecto y no sera responsable de cualesquiera
danos que puedan resultar de una transmision de virus
------------------------------------------------------------------
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users