Search code examples
c++geotiff

What do the return values denote for GTIFWriteKeys and GTIFKeySet libgeotiff functions (C++)?


In the (partial) libgeotiff API documentation, the meanings of the return values for the following functions are not stated:

  • GTIFWriteKeys
  • GTIFKeySet

What possible return values will these functions return? What do the values mean?


Solution

  • I had to dig through the source code to figure these out, and I am guessing that somebody else might benefit from this information. The simple answer is, that both of these functions will return 1 for success, and 0 for failure. This is straight forward, but because libtiff varies in what return values mean for various functions, I was unsure how libgeotiff would handle these.