I am using GDAL libraries to read tif image.. but i gor lot of errors while i build it. here is my source code :
------------------------------------------------------------------------------------------
include"gdal.h"
include"gdal_priv.h"
include"cpl_conv.h"
using namespace std;
int main()
{
GDALDataset *poDataset;
const char *pszFilename = "F:\VCPP\GAILGRA1.tif";
GDALAllRegister();
poDataset = (GDALDataset *) GDALOpen( pszFilename, GA_ReadOnly );
if( poDataset == NULL )
{
cout << "wrong file ";
}
return 0;
}
.............................................................................
i am using visual studio 2010 and created new project console application
OP's additional information moved from non-solution below
Error 1974 error LNK2019: unresolved external symbol _png_write_rows referenced in function "public: static class GDALDataset * __cdecl PNGDataset::CreateCopy(char const *,class GDALDataset *,int,char * *,int (__stdcall*)(double,char const *,void *),void *)" (?CreateCopy@PNGDataset@@SAPAVGDALDataset@@PBDPAV2@HPAPADP6GHN0PAX@Z3@Z) C:\Users\ACER\Desktop\gdal-1.9.1\VisualStudio9\gdal\pngdataset.obj gdal
-----------------------------------------------------------------------------
there are so many errors like this.... please help me out....