Hi ,
I am trying to read a raster file and I think I am not doing
something correctly.
This is how the relevant portion of the code looks like
------------------------------------------------------------------------
struct Cell_head region ;
double east ;
double north ;
int row, col ;
G_get_window(®ion) ;
row = (int)G_northing_to_row(north,®ion) ;
col = (int)G_easting_to_col(east,®ion) ;
/* to get the index of the row and col prior to reading
it using */
G_get_map_row(fd,buf,row) ;
--------------------------------------------------------------------------
Am I forgetting something? Because the value that I get for
the 'north' and 'east' values are absurd. That in turn leads
to ridiculous values for 'row' and 'col'.
All help is appreciated. If somebody wants to see more of the
code then I can send it to them.
Thanks.
Dinendra