<div dir="ltr"><div dir="ltr">Thank you Even,<div><br></div><div>I went more low-level and <a href="https://github.com/FreemapSlovakia/freemap-tiler/blob/8e1650b62fe2ca6a784870234810410284bd8263/src/main.rs#L344">successfully used GDALChunkAndWarpImage</a>. I also posted <a href="https://stackoverflow.com/a/79342516/289827">answer on SO</a>.</div><div><br></div><div>Regarding the pipeline, it could be a bad copy-paste or garbled by ChatGPT 😀.</div><div><br></div><div>Best regards</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Thu, Jan 9, 2025 at 1:11 PM Even Rouault <<a href="mailto:even.rouault@spatialys.com">even.rouault@spatialys.com</a>> wrote:</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>
    <p>GDALReprojectImage() expects that a correct geotransform is
      already set on the target dataset.</p>
    <p>You may use GDALSuggestedWarpOutput2() to get a guessed
      geotransform<br>
    </p>
    <p>Otherwise for full automated way, you may also using the C
      function GDALWarp().</p>
    <p>By the way, your below pipeline looks wrong<br>
    </p>
    <pre><code>+proj=pipeline
+step +inv +proj=krovak +lat_0=49.5 +lon_0=24.8333333333333 +alpha=30.2881397527778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel
+step +inv +proj=hgridshift +grids=Slovakia_JTSK03_to_JTSK.gsb
+step +proj=krovak +lat_0=49.5 +lon_0=24.8333333333333 +alpha=30.2881397527778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel
+step +proj=webmerc
</code>
</pre>
    <p>After the 3rd step (+proj=krovak), you are in projected
      coordinate space. Applying +proj=webmerc afterwards doesn't make
      any sense since the later expects geographic coordinates. You
      probably want to omit the 3rd step</p></div></blockquote></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Martin Ždila <br><br></div></div></div></div>