No georeferencing data, no metadata, just grid information with the z value-- with z value being the drain number where the cell is draining to.
How can I use the libgeotiff library to do this conversion?
I use TauDEM in my application for catchment delineation, and TauDEM uses raster file ( in the form of geotiff/ASCII) as input, and outputs the catchment delineation result in geotiff format.
I have my mesh from analysis, that I will need to convert to geotiff file for TauDEM for processing. When TauDEM finishes the work and outputs the result in geotiff format, I would need to read it into the memory in my code and render it using my own rendering engine-- vdraw. If I know how to convert between geotiff and ASCII file, I can immediately go from mesh to geotiff file without the intermediate ASCII ( which is very wasteful); likewise, if I know how to take the output geotiff and convert it to ASCII, I can process the geotiff file in memory and render it much faster without convert it to file in ASCII format.
This is why I need to know how to use libgeotiff ( or any other library) to do the conversion-- because my ESRI ASCII "file" lives in the memory and not hard disk. Even though GDAL contains such a conversion utility method, I couldn't use GDAL because using it will then require the actual ASCII file for conversion.