File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33## Unreleased
44
55* add ` grayscale ` and ` bitonal ` algorithms
6+ * add ` transform ` and ` crs ` for ` tiff ` outputs
67
78## 0.24.0 (2025-09-23)
89
Original file line number Diff line number Diff line change @@ -2126,13 +2126,26 @@ def test_ogc_maps_cog():
21262126 assert "Content-Bbox" in headers
21272127 assert "Content-Crs" in headers
21282128 assert headers ["content-type" ] == "image/jpeg"
2129+ meta = parse_img (response .content )
2130+ assert not meta ["crs" ]
2131+
2132+ response = client .get ("/map" , params = {"url" : cog_path , "f" : "tif" })
2133+ assert response .status_code == 200
2134+ headers = response .headers
2135+ assert "Content-Bbox" in headers
2136+ assert "Content-Crs" in headers
2137+ assert headers ["content-type" ] == "image/tiff; application=geotiff"
2138+ meta = parse_img (response .content )
2139+ assert meta ["crs" ]
21292140
21302141 response = client .get ("/map" , params = {"url" : cog_path , "f" : "tiff" })
21312142 assert response .status_code == 200
21322143 headers = response .headers
21332144 assert "Content-Bbox" in headers
21342145 assert "Content-Crs" in headers
21352146 assert headers ["content-type" ] == "image/tiff; application=geotiff"
2147+ meta = parse_img (response .content )
2148+ assert meta ["crs" ]
21362149
21372150 # Conformance Class “Scaling”
21382151 # /req/scaling/width-definition
Original file line number Diff line number Diff line change @@ -108,7 +108,7 @@ def render_image( # noqa: C901
108108 data = rescale_array (data , mask , in_range = datatype_range )
109109
110110 creation_options = {** kwargs , ** output_format .profile }
111- if output_format == ImageType . tif :
111+ if output_format . driver == "GTiff" :
112112 if "transform" not in creation_options :
113113 creation_options .update ({"transform" : image .transform })
114114 if "crs" not in creation_options and image .crs :
You can’t perform that action at this time.
0 commit comments