394{
397 double *dptr = (double *)(geometry_start);
398 int32_t *iptr = (int32_t *)(geometry_start);
399
400
402 {
404 }
405
406
408 {
409 int i = 1;
410
411
412 int isempty = (iptr[1] == 0);
413
414
416
417 gbox->
xmin = gbox->
xmax = dptr[i++];
418 gbox->
ymin = gbox->
ymax = dptr[i++];
421 {
422 gbox->
zmin = gbox->
zmax = dptr[i++];
423 }
425 {
426 gbox->
mmin = gbox->
mmax = dptr[i++];
427 }
430 }
431
433 {
435 int i = 0;
436 int npoints = iptr[1];
437
438
439 if (npoints != 2)
441
442
443
444 i++;
447
448
449 i++;
452
455 {
456
457 i++;
460 }
462 {
463
464 i++;
467 }
470 }
471
473 {
474 int i = 0;
475 int ngeoms = iptr[1];
476 int npoints;
477
478
479 if (ngeoms != 1)
481
482
483 npoints = iptr[3];
484
485
486
487 if (npoints != 1)
489
490
491
492
493 i += 2;
494
495
496 gbox->
xmin = gbox->
xmax = dptr[i++];
497 gbox->
ymin = gbox->
ymax = dptr[i++];
500 {
501 gbox->
zmin = gbox->
zmax = dptr[i++];
502 }
504 {
505 gbox->
mmin = gbox->
mmax = dptr[i++];
506 }
509 }
510
512 {
514 int i = 0;
515 int ngeoms = iptr[1];
516 int npoints;
517
518
519 if (ngeoms != 1)
521
522
523 npoints = iptr[3];
524
525 if (npoints != 2)
527
528
529
530
531
532 i += 2;
535
536
537 i++;
540
543 {
544
545 i++;
548 }
550 {
551
552 i++;
555 }
558 }
559
561}
void gbox_float_round(GBOX *gbox)
Round given GBOX to float boundaries.
uint32_t gserialized2_get_type(const GSERIALIZED *g)
Extract the geometry type from the serialized form (it hides in the anonymous data area,...
static uint8_t * gserialized2_get_geometry_p(const GSERIALIZED *g)
lwflags_t gserialized2_get_lwflags(const GSERIALIZED *g)
Read the flags from a GSERIALIZED and return a standard lwflag integer.
#define G2FLAGS_GET_BBOX(gflags)
#define G2FLAGS_GET_GEODETIC(gflags)
#define G2FLAGS_GET_Z(gflags)
#define G2FLAGS_GET_M(gflags)
#define G2FLAGS_NDIMS(gflags)
#define POINTTYPE
LWTYPE numbers, used internally by PostGIS.