title: Assign Latitude and Longitude values to pixels
body: <p>This is a problem that I have been trying to solve for some time. I have a binary file, that, after processing, leaves me with a binary bmp file, i.e, the pixels have only two values. Now, I have with me the following HDR file:</p>
  
  <pre><code>ENVI
  description = {
  PolSARpro File Imported to ENVI}
  samples = 2618
  lines   = 2757
  bands   = 1
  header offset = 0
  file type = ENVI Standard
  data type = 4
  interleave = bsq
  byte order = 0
  map info = {UTM, 1, 1, 399711.555, 2641320.529, 12.500, 12.500, 45, North, WGS-84}
  wavelength units = meters
  band names = {
  SPF_L1.bin }
  </code></pre>
  
  <p>generated by ENVI and PolSARPro. The problem I am facing is that  softwares like ENVI calculate the latitude &amp;  longitude values for each pixel, while I am not able to find any method for replicating the same in my program ( I am using C, using PolSARPro's source files as base ). If any one could help me by explaining how to assign the positional information, it would be highly appreciated!</p>
  
  <p>P.S: From my point of view, map info - <code>lists geographic coordinates information in the order of projection name (UTM), reference pixel x location in file coordinates, pixel y, x pixel size, y pixel size, Projection Zone, North or South for UTM only.</code></p>