Hi Andrea,

Thanks, that looks promising. In the GeoTIFF file the “method” in the CRS 
metadata is indicated as "Lambert Cylindrical Equal Area", whereas the in the 
LambertCylindricalEqualAreaProvider you linked to says:



new NamedIdentifier(Citations.GEOTOOLS, "Lambert Cylindrical Equal Area 
(Spherical)")



So perhaps it’s a matter of adding another NamedIdentifier without the 
“(Spherical)” part? (Perhaps also another Citations.ESRI-entry with said ERSI 
identifier number). That way the GeoTiffMetadata2CRSAdapter should pick it up 
automatically no?

Regards,
Tobias

Från: Andrea Aime <andrea.a...@geosolutionsgroup.com>
Skickat: den 9 februari 2022 14:25
Till: Tobias Gerdin <tobias.ger...@havochvatten.se>
Kopia: geotools-gt2-users@lists.sourceforge.net
Ämne: Re: [Geotools-gt2-users] Loading GeoTIFF in ESRI:54034 CRS

Hi Tobias,
yes it should be possible. Some code for a CyclidricalEqualArea projection was 
donated to the project in 2017:
https://github.com/geotools/geotools/blob/50b283a7c9229d6c64160b3e8a17eede1c7fa2f4/modules/library/referencing/src/main/java/org/geotools/referencing/operation/projection/CylindricalEqualArea.java#L30<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=wdQnpCL5wmQcX_G_Js5fL3zVNPDc_K5F5-9jsALHOwTPQL7sJesac03PAPP9y962bKdeAiplEGEoeS3dqaUjZOWttxGbMxNROh5z6bUPT2HiywIPNTLIT-JYCdnIcxfjo3u0h9eFP7wx4RBStf2bPtFPhLG0XDU48LM0BRB3Jl02fgg5Qp2ofSEkjtUdbzp47KR72n1pxE_sbKBm9F86MmH7-2v-Ymv14AIdyG0aG0KGo8E_BEMRGe-_ys2hXLXugVQBCc9sfDnYooilpHwcE94_r0b6Gqa-_djxmRevjQIxmhlaFhYK0lss5qwzKBuA72VD9DKkLIenfSsgM0AdgMYJgBRVt0TZxGK2jrpGfTstd-VQ1U4YPE8QTC2RI-ZVsx_O8XUrByiHFGUfSbyDOCKCsV4rQ2DQZcuIz0ia2RvB4_GyVyVHaFLCKb6hgKoygf-_GLaQS1A2BYx2yUztKg>

Assuming it's the right match, I'm guessing the GeoTiffMetadata2CRSAdapter class
could be adapted to make use of it:
https://github.com/geotools/geotools/blob/5b917631ffbc21f9348e3baead175d3772c0ea7e/modules/library/coverage/src/main/java/org/geotools/coverage/grid/io/imageio/geotiff/GeoTiffMetadata2CRSAdapter.java#L965<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=jjemjc3LLewOVrVfg_mT6n9rsIjGm_7mvS2hQ1JfptKeWOTVca1gMPGp7b8Ox-lhRlzFeLF6csuEmT7QIyA6X91JdHRp9-M43qVGs-ew_CCXvrrJGKK3ES6BKwEfaVOvY_2jPmNqtYLySBXKOpAVrglEM0dx3YeN9FBgTau4-RtZML68gIU5DYSstzqoMc6Mu_il9WYLS0gceR_Frqv8Ez8J9UUSs6_sMxAVcbQG8aemZjTNDMCp6mkhyTRYqpHckRta_JWeSvi7OqulClMbzx0a7al8LPGyuS7dncmlQXuoPqEWaWGf23PuhTE2oDvH5WbAgf67NtNeVIsN_hN9--MK4T0tPctkNu_HKHDj7a8lortnRzp1k6c6IseceyQ7eOntp46jn5IbCxvz0CwqLXlKaYYUSUTY8vbkos16XL5CVBAvO57mR2tJj5UbCQ1gS9P-17KeaVr49SDhCvtG0g>

Cheers
Andrea


On Wed, Feb 9, 2022 at 12:41 PM Tobias Gerdin 
<tobias.ger...@havochvatten.se<mailto:tobias.ger...@havochvatten.se>> wrote:
Hello,

I would like to load GeoTIFF files in ESRI:54034  CRS. I understand I need a 
suitable factory for the CRS, which I do not seem to have at the moment, and 
get the below when doing
format.getReader(file, hints).read(null):

12:09:56,585 WARNING [org.geotools.gce.geotiff] (default task-3) GEOTIFF Module 
Error Report
GeoTiffMetadata2CRSAdapter::createUserDefinedPCS:Projection is not supported.
ModelPixelScaleTag: [250.0,250.0,0.0]
ModelTiePointTag: (1 tie points)
TP #0: [0.0,0.0,0.0] -> [-441000.0,1790000.0,0.0]
ModelTransformationTag: NOT AVAILABLE
GeoKey #1: Key = 1024, Value = 1
GeoKey #2: Key = 2048, Value = 4326
GeoKey #3: Key = 3072, Value = 32767
GeoKey #4: Key = 1025, Value = 1
GeoKey #5: Key = 2049, Value = WGS 84
GeoKey #6: Key = 1026, Value = WGS_1984_Cylindrical_Equal_Area
GeoKey #7: Key = 3074, Value = 32767
GeoKey #8: Key = 3075, Value = 28
GeoKey #9: Key = 3076, Value = 9001
GeoKey #10: Key = 2054, Value = 9102
GeoKey #11: Key = 3078, Value = -12.0
GeoKey #12: Key = 3080, Value = 12.0
GeoKey #13: Key = 2057, Value = 6378137.0
GeoKey #14: Key = 3082, Value = 0.0
GeoKey #15: Key = 2059, Value = 298.257223563
GeoKey #16: Key = 3083, Value = 0.0

Hints are equal to new Hints(Hints.FORCE_LONGITUDE_FIRST_AXIS_ORDER, 
Boolean.TRUE). Currently I only have the org.geotools.gt-epsg-hsql artifact in 
the Maven project POM.

Is it possible to have Geotools understand the ESRI:54034 CRS?

Regards,
Tobias Gerdin

Havs- och vattenmyndigheten behandlar dina personuppgifter i enlighet med 
dataskyddsförordningen och myndighetens dataskyddspolicy, läs mer på 
www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter<http://www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter><https://www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter>
SwAM processes your personal data in accordance with the General Data 
Protection Regulation (GDPR) and our Data Protection Policy, see 
www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter<http://www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter><https://www.havochvatten.se/sa-behandlar-hav-dina-personuppgifter>

_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net<mailto:GeoTools-GT2-Users@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=_zYxm8zGZ8sCTXDS9m6Y9ZOxBy2Tx1pBLIVnrVb4HnYubVdFAI_UHbKx4NBJA_5sYrpNDQx_Qfa4N4WGyqafn1uTLTbf0LJ9sf-i7obQtI_t_yfe3O4jslksvBO68CUlKjW0XTKDNwZVz5ExyBRxp0xk5n4gDoNLBrL3rrT56OG0Mp2fUXTpmNrk5zLB5fM7ema1q-UE9XParKdBCQP4uCX-4F5bTf93KNu5NdqePDDEbApz9Zrq4GSY0SYBgdspl1TDJIEtzXlfArcp1qYXVQ>


--

Regards,

Andrea Aime

==
GeoServer Professional Services from the experts!

Visit 
http://bit.ly/gs-services-us<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=BlKWtNwum5UgZS0x6CStilqaOTyX4uESLll7R6dfJI1aCwp_8HsxZzm76-pVl2cf8TF07eucfUUFzjVSw2iJcEn4xIGH5SepX86mz7uatApOXn7hWT4IgU6GOp-yxKV_jOK0npfsz1BhY-xI8G8bjKID27ixk-7j0CxuoDcWWiUzhMt_ivg0OOT7_qbxFw9IalBpI7L4LrV_ppXucSTpoOE7IP6QANZYaKEFJ2WcRkU>
 for more information.
==

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions Group
phone: +39 0584 962313

fax:     +39 0584 1660272

mob:   +39  333 8128928


https://www.geosolutionsgroup.com/<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=n1DNV1Xx3V8cQSn3r0pzsW3JAhZdvxR38L9WFnbdlTslAyqjCiLpBDgWmJ7hsqnzKWEAsNheuiCMwIj17I3t6EBVeSpY2yLttrPtPlo4BIPDlzs_sqH97sCl9N4KnJpAoVNhPldHJ2HRu3l6pAmGfCiP0-iMShuRRgmaA-IbIZ1Z8MoQvAHRa8EyfhUM-j85zycOqirnu6UdoelLpt8dC2GNjJWR3biOejO2YwqS8R0>

http://twitter.com/geosolutions_it<https://url10.mailanyone.net/v1/?m=1nHmxn-0005eA-4v&i=57e1b682&c=nIXN4DXh8sH2o_m-4yi5nEo0CY2swba47MKVPPVTXqMkDL6Xx1uWPiFCnNthOXhgw3p3mmHXAxfg-y_cD-a6fMEEhtzT1PRrNKdL_n06-rw5oboPYdAPv1ujgsLfRkZl2rNMymdrceD3BBh-7b2cUuziaHDfqlTEB6-jIgkrx3JMA7606XimauWhTFbzo3lfmd9p0WMB_sgqxfCAfjhmqxgeyI9PLCEuLbTSgCE5WJk>

-------------------------------------------------------

Con riferimento alla normativa sul trattamento dei dati personali (Reg. UE 
2016/679 - Regolamento generale sulla protezione dei dati “GDPR”), si precisa 
che ogni circostanza inerente alla presente email (il suo contenuto, gli 
eventuali allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i 
destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per 
errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le sarei 
comunque grato se potesse darmene notizia.

This email is intended only for the person or entity to which it is addressed 
and may contain information that is privileged, confidential or otherwise 
protected from disclosure. We remind that - as provided by European Regulation 
2016/679 “GDPR” - copying, dissemination or use of this e-mail or the 
information herein by anyone other than the intended recipient is prohibited. 
If you have received this email by mistake, please notify us immediately by 
telephone or e-mail
_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to