Hi,<br><br>Pardon me for the intrusion in this post related to Geotiff with GDAL(Java bind).<br><br>I was wondering the list discussion was oriented towards the implementation and the bind of the GDAL half of the GDAL/OGR bind has anyone implemented or used the OGR half of the bind as well.
<br><br>I tried a small test with Java OGR bind as follows, (I tried to hack the GdalTest.java for this ):<br>OgrTest.java<br>-----------------------------------------------------------------------------------------<br>import
org.gdal.ogr.Driver;<br>import org.gdal.ogr.ogr;<br><br>public class OgrTest<br>{<br> public OgrTest() {<br><br> }<br> public static void main(String[] args) {<br> System.out.println("OGR init...");
<br> ogr.RegisterAll();<br> int count = ogr.GetDriverCount();<br><br> System.out.println(count + " available Drivers");<br> for (int i = 0; i < count; i++) {<br> try {<br>
Driver driver = ogr.GetDriver(i);<br> System.out.println(" " + driver.GetName() + " ");<br> } catch (Exception e) {<br> System.err.println("Error loading driver " + i);
<br> }<br> }<br> }<br>}<br><br>------------------------------------------------------------------------------------------<br><br>Is there any documentation or sample that exists for the same which is advance enough to create complex application.
<br><br>Rgds<br><br>Abhay.<br><br><div class="gmail_quote">On Jan 14, 2008 10:38 PM, Stefan Keller <<a href="mailto:sfkeller@gmail.com">sfkeller@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>Obviously, there seems to be quite some interest in a Java binding to GDAL/OGR.</div>
<div>Can someone summarize and perhaps update the wiki/documentation with instructions and example downloads?</div>
<div>Any volunteers to become a committer for this Java Binding?<br> </div>
<div>-- Stefan<br> </div>
<div><span class="gmail_quote">2008/1/14, Stefan Mietke <<a href="mailto:St.Mietke@gmx.de" target="_blank">St.Mietke@gmx.de</a>>:</span>
<div><div></div><div class="Wj3C7c"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">Thats it! It works, wow ...<br><br>For interested list members:
<br><br>The solution of this problem is simple:
<br><br>After allocating a ByteBuffer, you have to set the Byte order, before reading the raster with 'ReadRaster_Direct()' method.<br><br>ByteBuffer byteBuffer = ByteBuffer.allocateDirect(buffer_size);<br>byteBuffer.order
(ByteOrder.nativeOrder());<br><br>For the writing process you have to do the same with the output ByteBuffer.<br><br>I thank Daniele Romagnoli and Benjamin Collins for their great support.<br><br>Stefan Mietke<br>--<br>
Institute for Cartography
<br>TU Dresden<br><br>Psssst! Schon vom neuen GMX MultiMessenger gehört?<br>Der kann`s mit allen: <a href="http://www.gmx.net/de/go/multimessenger?did=10" target="_blank">
http://www.gmx.net/de/go/multimessenger?did=10</a><br>_______________________________________________ <br>gdal-dev mailing list<br><a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">
gdal-dev@lists.osgeo.org</a><br><a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote>
</div></div></div><br>
<br>_______________________________________________<br>gdal-dev mailing list<br><a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br><a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">
http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br>