cholmes / cog-map

A viewer for Cloud Optimized GeoTiffs, based on Openlayers
https://cogeo.org/map
Apache License 2.0
64 stars 12 forks source link

Not able to render COG file #18

Open vijay2712 opened 2 years ago

vijay2712 commented 2 years ago

image

vijay2712 commented 2 years ago

image

I am able to render the Geotiff using python. Is there any different format for javascript?

vincentsarago commented 2 years ago

https://ssa-punjab-images.s3.ap-south-1.amazonaws.com/20210514_051305_0f15_3B_AnalyticMS.tif is not a public url

curl https://ssa-punjab-images.s3.ap-south-1.amazonaws.com/20210514_051305_0f15_3B_AnalyticMS.tif
<?xml version="1.0" encoding="UTF-8"?>
<Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>1HF8XQABQDF9FCH2</RequestId><HostId>wvD3sNhypmeaJVC4jE7Xz4wmP/++V4LfEXxR/7V1uD7fICc9WnuVGmjDRPBEpuoAjOjWbMU7h48=</HostId></Error>%  
vijay2712 commented 2 years ago

Thanks for the reply. I am able to solve this error by making my COG file public.

But I am getting this error.

Uncaught TypeError: t is undefined o util.js:33 _n Group.js:238 dispatchEvent Target.js:111 removeAt Collection.js:260 zoomLoad index4.html:357 jQuery 4 u fireWith k n Attached is my code

https://github.com/vijay2712/COG_Geotiff

vincentsarago commented 2 years ago

https://ssa-punjab-images.s3.ap-south-1.amazonaws.com/NDVI_latest_cog.tif is no a COG (it's missing overviews, so might fails in most tile server)

https://ssa-punjab-images.s3.ap-south-1.amazonaws.com/NIR_cut_20200105.tif has no overview but is really small so it should work.

as for your error Uncaught TypeError: t is undefined, well you have to find in your code 🤷‍♂️

vijay2712 commented 2 years ago

Thanks for the quick response

image

https://ssa-punjab-images.s3.ap-south-1.amazonaws.com/Khanna31Aug.tif

https://cholmes.github.io/cog-map/

It's working fine on node.js but I am unable to render using CDN libraries with Openlayers. I have copy the code from this repo.

I am getting this error. Uncaught TypeError: t is undefined