The atGeometry, minusGeometry, atStbox, and minusStbox functions restrict a trgeometry to (the complement of) a geometry or a spatiotemporal box. The semantic mirrors tpose: a temporal rigid geometry is "in" a region at time t iff its body, the reference geometry placed by the pose at t, meets that region. atGeometry and minusGeometry restrict a value in three dimensions in step or discrete interpolation to a geometry with Z by each placement of its body, read in 3D as the ever and temporal relationships read it, a closed body as the solid it bounds; a value in two dimensions reads a geometry with Z in 2D. A value in three dimensions reads a geometry without Z by the footprint of its body on the ground, as it reads a box without Z, a segment that turns in three dimensions being not yet supported; a value in three dimensions in linear interpolation against a geometry with Z is not yet supported. atStbox and minusStbox read a box on the dimensions it shares with the value: in three dimensions where both have Z, and on the plane otherwise, where a value with Z in linear interpolation whose body lies in a plane of constant z is read as its projection to the ground. A value with Z in linear interpolation is not yet supported against a box with Z, nor where it turns in three dimensions.
A body with holes in linear interpolation is restricted where it meets the region, a region that a hole of the body holds at an instant not meeting it.
A geometry with holes is supported for a value in step or discrete interpolation, which holds each placement of its body and is restricted where the placement meets the geometry, holes read as outside it; for a value in linear interpolation it is not yet supported.
A value in linear interpolation whose body is a convex polygon without holes, against a point, a line or a convex polygon without holes, or a box, is in the region exactly when its distance to it is zero, as tIntersects answers it, so a contact at a single instant and a box flat in one dimension are read; the upper borders a tile leaves out, and the other bodies and regions, are read by the clip of the edges of the body, those of its holes included, against the vertices and segments of the region, so that a contact at a single instant is read there too.
Restrict to (the complement of) a pose or a set of poses
atValue(trgeometry,pose) → trgeometry minusValue(trgeometry,pose) → trgeometry atValues(trgeometry,poseset) → trgeometry minusValues(trgeometry,poseset) → trgeometry
SELECT asText(atValue(trgeometry 'Polygon((1 1,2 2,3 1,1 1));
[Pose(Point(1 1), 0.2)@2001-01-01, Pose(Point(1 1), 0.4)@2001-01-02,
Pose(Point(1 1), 0.5)@2001-01-03]', pose 'Pose(Point(1 1), 0.5)'));
-- POLYGON((1 1,2 2,3 1,1 1));{[Pose(POINT(1 1),0.5)@2001-01-03]}
SELECT asText(minusValue(trgeometry 'Polygon((1 1,2 2,3 1,1 1));
{Pose(Point(1 1), 0.3)@2001-01-01, Pose(Point(1 1), 0.5)@2001-01-02,
Pose(Point(1 1), 0.5)@2001-01-03}', pose 'Pose(Point(1 1), 0.5)'));
-- POLYGON((1 1,2 2,3 1,1 1));{Pose(POINT(1 1),0.3)@2001-01-01}
The restricting value is a pose, the base value a temporal rigid geometry interpolates. The reference geometry is carried through unchanged, so the result describes the same body.
Restrict a trgeometry to (the complement of) a geometry
atGeometry(trgeometry,geometry) → trgeometry minusGeometry(trgeometry,geometry) → trgeometry
SELECT getTime(atGeometry( trgeometry 'Polygon((0 0,1 0,1 1,0 1,0 0));
[Pose(Point(0 0), 0.0)@2001-01-01, Pose(Point(4 0), 0.0)@2001-01-05]',
geometry 'Polygon((1 -1,3 -1,3 1,1 1,1 -1))'));
-- {[2001-01-01, 2001-01-04]}
SELECT getTime(minusGeometry( trgeometry 'Polygon((0 0,1 0,1 1,0 1,0 0));
[Pose(Point(0 0), 0.0)@2001-01-01, Pose(Point(4 0), 0.0)@2001-01-05]',
geometry 'Polygon((1 -1,3 -1,3 1,1 1,1 -1))'));
-- {(2001-01-04, 2001-01-05]}
Restriction against an empty geometry returns NULL for atGeometry and the original input for minusGeometry.
Restrict a trgeometry to (the complement of) a spatiotemporal box
atStbox(trgeometry,stbox[,border_inc boolean=true]) → trgeometry minusStbox(trgeometry,stbox[,border_inc boolean=true]) → trgeometry
SELECT getTime(atStbox( trgeometry 'Polygon((0 0,1 0,1 1,0 1,0 0));
[Pose(Point(0 0), 0.0)@2001-01-01, Pose(Point(4 0), 0.0)@2001-01-05]',
stbox 'STBOX X((1, -1), (3, 1))'));
-- {[2001-01-01, 2001-01-04]}
A box with only a temporal component restricts the time domain, as atTime does; if the box has only a spatial component the temporal domain is preserved.