Rashad,<br><br>This would probably give you a Float64 type bands with the pixels valued at 255.0<br>Try setting the band type to Byte using the -ot option.<br><br><div class="gmail_quote">On Sun, Feb 13, 2011 at 4:11 PM, Mohammed Rashad <span dir="ltr"><<a href="mailto:mohammedrashadkm@gmail.com">mohammedrashadkm@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><br clear="all">How to convert shapefile to a raster image using gdal<div><br></div><div>I tried </div>
<div>gdal_rasterize -burn 255 -burn 0 -burn 0 -ts 100 100 -l ernakulam ernakulam.shp ekm.tif</div><div><br></div><div><div>
gdal_rasterize -A DIST -ts 100 100 -l ernakulam ernakulam.shp ekm.tif</div><div><br></div><div><div>gdal_rasterize -A AREA -ts 100 100 -l ernakulam ernakulam.shp ekm.tif</div></div><div><br></div><div>but still no output</div>
<div><br></div><div><br></div><div><br></div><div><span dir="ltr">ogrinfo -al -so ernakulam.shp</span></div><div><span dir="ltr"><br></span></div><div><div> <span dir="ltr">INFO: Open of `ernakulam.shp'<br>
using driver `ESRI Shapefile' successful.<br><br>Layer name:
ernakulam<br>Geometry: Polygon<br>Feature Count: 16<br>Extent:
(76.168263, 9.788524) - (76.840498, 10.301794)<br>Layer SRS WKT:<br>(unknown)<br>AREA:
Real (20.15)<br>PERIMETER: Real (20.15)<br>INDIA_: Real (11.0)<br>INDIA_ID:
Real (11.0)<br>STATE: String (20.0)<br>DIST: String (20.0)<br>TALUK:
String (20.0)<br>CENTROID_Y: Real (20.15)<br>CENTROID_X: Real (20.15)</span></div><div dir="ltr">i selected AREA</div><div dir="ltr"><br></div>-- <br><div>Thanks && Regards</div>
Rashad<br>
</div></div>
<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><br clear="all"><br>-- <br>Best regards,<br>Chaitanya kumar CH.<br>
/tʃaɪθənjə/ /kʊmɑr/ <br>+91-9494447584<br>17.2416N 80.1426E<br>