Andrea,
Thanks for your quick response. I've manually changed it in it's coverage.xml file, but I'm still not able to preview it. It doesn't throw any error but I can't see it. Here is the coverage.xml file an the output:
<coverage>
<id>CoverageInfoImpl--5d73d6d9:133834d8da7:-7fed</id>
<name>100_ED50</name>
<namespace>
<id>NamespaceInfoImpl-5f552ab0:12b763c2d5d:-7fff</id>
</namespace>
<title>100_ED50</title>
<description>Generated from WorldImage</description>
<keywords>
<string>WCS</string>
<string>WorldImage</string>
<string>100_ED50</string>
</keywords>
<nativeCRS class="projected">PROJCS["ED50 / UTM zone 30N", 
GEOGCS["ED50", 
DATUM["European Datum 1950", 
SPHEROID["International 1924", 6378388.0, 297.0, AUTHORITY["EPSG","7022"]], 
TOWGS84[-157.89, -17.16, -78.41, 2.118, 2.697, -1.434, -1.1097046576093785], 
AUTHORITY["EPSG","6230"]], 
PRIMEM["Greenwich", 0.0, AUTHORITY["EPSG","8901"]], 
UNIT["degree", 0.017453292519943295], 
AXIS["Geodetic longitude", EAST], 
AXIS["Geodetic latitude", NORTH], 
AUTHORITY["EPSG","4230"]], 
PROJECTION["Transverse Mercator", AUTHORITY["EPSG","9807"]], 
PARAMETER["central_meridian", -3.0], 
PARAMETER["latitude_of_origin", 0.0], 
PARAMETER["scale_factor", 0.9996], 
PARAMETER["false_easting", 500000.0], 
PARAMETER["false_northing", 0.0], 
UNIT["m", 1.0], 
AXIS["Easting", EAST], 
AXIS["Northing", NORTH], 
AUTHORITY["EPSG","23030"]]</nativeCRS>
<srs>EPSG:23030</srs>
<nativeBoundingBox>
<minx>457322.616</minx>
<maxx>609446.744</maxx>
<miny>4699002.257</miny>
<maxy>4817304.006</maxy>
<crs>EPSG:4326</crs>
</nativeBoundingBox>
<latLonBoundingBox>
<minx>-3.529</minx>
<maxx>-1.647</maxx>
<miny>42.434</miny>
<maxy>43.507</maxy>
<crs>EPSG:4326</crs>
</latLonBoundingBox>
<projectionPolicy>FORCE_DECLARED</projectionPolicy>
<enabled>true</enabled>
<metadata>
<entry key="cachingEnabled">false</entry>
<entry key="dirName">Mapa Papel 100 ED50_100_ED50</entry>
</metadata>
<store class="coverageStore">
<id>CoverageStoreInfoImpl--776f4fea:12b81e9cdec:-7fff</id>
</store>
<nativeFormat>WorldImage</nativeFormat>
<grid dimension="2">
<range>
<low>0 0</low>
<high>11919 9269</high>
</range>
<transform>
<scaleX>12.763161999999987</scaleX>
<scaleY>-12.763161999999987</scaleY>
<shearX>0.0</shearX>
<shearY>0.0</shearY>
<translateX>457328.99793690274</translateX>
<translateY>4817297.624389882</translateY>
</transform>
<crs>EPSG:23030</crs>
</grid>
<supportedFormats>
<string>GIF</string>
<string>PNG</string>
<string>JPEG</string>
<string>TIFF</string>
<string>GEOTIFF</string>
</supportedFormats>
<interpolationMethods>
<string>bilinear</string>
<string>bicubic</string>
</interpolationMethods>
<dimensions>
<coverageDimension>
<name>RED_BAND</name>
<description>GridSampleDimension[-Infinity,Infinity]</description>
</coverageDimension>
<coverageDimension>
<name>GREEN_BAND</name>
<description>GridSampleDimension[-Infinity,Infinity]</description>
</coverageDimension>
<coverageDimension>
<name>BLUE_BAND</name>
<description>GridSampleDimension[-Infinity,Infinity]</description>
</coverageDimension>
</dimensions>
<requestSRS>
<string>EPSG:4326</string>
<string>EPSG:23030</string>
</requestSRS>
<responseSRS>
<string>EPSG:4326</string>
<string>EPSG:23030</string>
</responseSRS>
</coverage>
Output:
08 Nov 16:30:57 DEBUG [org.geotools.jdbc] - CREATE CONNECTION
08 Nov 16:30:58 DEBUG [org.geotools.jdbc] - CLOSE CONNECTION
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.003365672538153, 0.0, -1544.1981697472734], [0.0, -0.003365672538153, 16223.385327014064]]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Computed scale denominator: 1061133.7053571427
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 1,061,133.705
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[458808.2031875 : 610932.3311875, 4701997.9358125 : 4820250.6759375]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.006731345076305, 0.0, -3349.3963394945467], [0.0, -0.006731345076316, 32257.770654083088]]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Computed scale denominator: 530566.8526785714
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 530,566.853
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[497582.02878125 : 573644.09278125, 4733046.7080314 : 4792173.0780938]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.01346269015261, 0.0, -6959.792678989026], [0.0, -0.013462690152633, 64326.541308164175]]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Computed scale denominator: 265283.4263392857
08 Nov 16:31:04 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 265,283.426
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[516968.94157812 : 554999.97357812, 4748571.0941406 : 4778134.2791718]
08 Nov 16:31:04 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:04 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:04 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.02692538030522, 0.0, -14180.585357978165], [0.0, -0.026925380305266, 128464.08261632903]]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Computed scale denominator: 132641.71316964243
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 132,641.713
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[526662.39797656 : 545677.91397656, 4756333.2871953 : 4771114.8797109]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.05385076061044, 0.0, -28622.170715956217], [0.0, -0.053850760610535, 256739.1652326776]]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Computed scale denominator: 66320.85658482162
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 66,320.857
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[531509.12617578 : 541016.88417578, 4760214.3837227 : 4767605.1799805]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.107701521220879, 0.0, -57505.3414319118], [0.0, -0.107701521218166, 513289.330451517]]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Computed scale denominator: 33160.42829241122
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 33,160.428
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[533932.49027539 : 538686.36927539, 4762154.9319863 : 4765850.3301153]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.215403042441764, 0.0, -115271.68286382758], [0.0, -0.21540304244795, 1026389.6609583771]]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Computed scale denominator: 16580.214146205202
08 Nov 16:31:05 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 16,580.214
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[535144.1723252 : 537521.1118252, 4763125.2061182 : 4764972.9051826]
08 Nov 16:31:05 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:05 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:05 DEBUG [org.geotools.image] - Writing out...
08 Nov 16:31:07 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:07 DEBUG [org.geotools.renderer.shape] - Affine Transform is AffineTransform[[0.430806084883549, 0.0, -230804.36572766546], [0.0, -0.430806084896333, 2052590.3219188214]]
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - Computed scale denominator: 8290.107073102195
08 Nov 16:31:07 DEBUG [org.geotools.styling] - number of fts set 1
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - processing 1 stylers for http://www.opengis.net/gml:GridCoverage
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - creating rules for scale denominator - 8,290.107
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - added attribute grid
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - added attribute params
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - Querying layer GridCoverage with bbox: ReferencedEnvelope[535750.0133501 : 536938.4831001, 4763610.3431841 : 4764534.1927163]
08 Nov 16:31:07 DEBUG [org.geotools.rendering] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:07 DEBUG [org.geotools.renderer.shape] - Style cache hit ratio: NaN , hits 0, requests 0
08 Nov 16:31:07 DEBUG [org.geotools.image] - Encoding input image to write out as JPEG.
08 Nov 16:31:07 DEBUG [org.geotools.image] - Getting a JPEG writer and configuring it.
08 Nov 16:31:07 DEBUG [org.geotools.image] - Writing out...
Un saludo,
··················································································
David Alda Fernández de Lezea
Lurralde eta Biodibertsitate Saila / Dpto. de Territorio y Biodiversidad
IKT
Granja Modelo s/n · 01192 · Arkaute (Araba)
··················································································
Tlfnos.: 945-00-32-95 Fax: 945-00.32.90
··················································································
email: dalda@anonymised.com web: www.ikt.es
··················································································
-----Mensaje original-----
De: andrea.aime@anonymised.com [mailto:andrea.aime@anonymised.com] En nombre de Andrea Aime
Enviado el: martes, 08 de noviembre de 2011 16:09
Para: David Alda Fernandez de Lezea
CC: geoserver-users@lists.sourceforge.net
Asunto: Re: [Geoserver-users] Geoserver's default CRS when adding a tiff
On Tue, Nov 8, 2011 at 3:49 PM, David Alda Fernandez de Lezea <dalda@anonymised.com5...> wrote:
Hi list,
I'm in a GeoServer 2.0.2 instance, and I wanted to add a tif datastore. When I add the layer of that datastore, the native CRS that appears in GEoServer's interface is WGS84 EPSG:4326 although that tiff is in another projection (ED50 EPSG:23030). I'm aware that tifs don't have the typical prj file in which you have the definition of the CRS, they only have the coordinates of the upper left corner and some other data.
My question is about how can I change that GeoServer gets a default CRS for that cases??
My memory is rather foggy on the 2.0.x series but I believe you cannot force a different SRS from the GUI, add a .prj file to your tiff file set that specifies its native projection instead.
On 2.1.x it should be possible to force the SRS from the GUI instead.
Cheers
Andrea
--
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 962313
http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf
-------------------------------------------------------