PostGIS  2.1.10dev-r@@SVN_REVISION@@
static uint32_t read_uint32 ( const uint8_t **  from,
uint8_t  littleEndian 
)
static

Definition at line 7237 of file rt_api.c.

Referenced by read_float32(), read_int32(), rt_band_from_wkb(), and rt_raster_deserialize().

7237  {
7238  uint32_t ret = 0;
7239 
7240  assert(NULL != from);
7241 
7242  if (littleEndian) {
7243  ret = (uint32_t) ((*from)[0] & 0xff) |
7244  (uint32_t) ((*from)[1] & 0xff) << 8 |
7245  (uint32_t) ((*from)[2] & 0xff) << 16 |
7246  (uint32_t) ((*from)[3] & 0xff) << 24;
7247  } else {
7248  /* big endian */
7249  ret = (uint32_t) ((*from)[3] & 0xff) |
7250  (uint32_t) ((*from)[2] & 0xff) << 8 |
7251  (uint32_t) ((*from)[1] & 0xff) << 16 |
7252  (uint32_t) ((*from)[0] & 0xff) << 24;
7253  }
7254 
7255  *from += 4;
7256  return ret;
7257 }

Here is the caller graph for this function: