PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ RASTER_noop()

Datum RASTER_noop ( PG_FUNCTION_ARGS  )

Definition at line 174 of file rtpg_inout.c.

175 {
177  rt_pgraster *pgraster, *result;
178  pgraster = (rt_pgraster *) PG_DETOAST_DATUM(PG_GETARG_DATUM(0));
179  raster = rt_raster_deserialize(pgraster, FALSE);
180  if (!raster) {
181  PG_FREE_IF_COPY(pgraster, 0);
182  elog(ERROR, "RASTER_noop: Cannot deserialize raster");
183  PG_RETURN_NULL();
184  }
185  result = rt_raster_serialize(raster);
187  if (result == NULL)
188  PG_RETURN_NULL();
189 
190  SET_VARSIZE(result, raster->size);
191  PG_RETURN_POINTER(result);
192 }
#define FALSE
Definition: dbfopen.c:168
void rt_raster_destroy(rt_raster raster)
Release memory associated to a raster.
Definition: rt_raster.c:82
void * rt_raster_serialize(rt_raster raster)
Return this raster in serialized form.
Definition: rt_serialize.c:521
rt_raster rt_raster_deserialize(void *serialized, int header_only)
Return a raster from a serialized form.
Definition: rt_serialize.c:725
raster
Be careful!! Zeros function's input parameter can be a (height x width) array, not (width x height): ...
Definition: rtrowdump.py:121
Struct definitions.
Definition: librtcore.h:2250

References FALSE, rtrowdump::raster, rt_raster_deserialize(), rt_raster_destroy(), and rt_raster_serialize().

Here is the call graph for this function: