PostGIS  2.1.10dev-r@@SVN_REVISION@@
GDALResampleAlg rt_util_gdal_resample_alg ( const char *  algname)

Convert cstring name to GDAL Resample Algorithm.

Parameters
algname: cstring name to convert
Returns
valid GDAL resampling algorithm

Definition at line 202 of file rt_api.c.

Referenced by RASTER_GDALWarp().

202  {
203  assert(algname != NULL && strlen(algname) > 0);
204 
205  if (strcmp(algname, "NEARESTNEIGHBOUR") == 0)
206  return GRA_NearestNeighbour;
207  else if (strcmp(algname, "NEARESTNEIGHBOR") == 0)
208  return GRA_NearestNeighbour;
209  else if (strcmp(algname, "BILINEAR") == 0)
210  return GRA_Bilinear;
211  else if (strcmp(algname, "CUBICSPLINE") == 0)
212  return GRA_CubicSpline;
213  else if (strcmp(algname, "CUBIC") == 0)
214  return GRA_Cubic;
215  else if (strcmp(algname, "LANCZOS") == 0)
216  return GRA_Lanczos;
217 
218  return GRA_NearestNeighbour;
219 }

Here is the caller graph for this function: