123 | | ------ 1-b-ii: Generate Euclidean Distance from a set of raster specifications: |
124 | | -------- 1-b-ii-1: Snap is True; Max distance NOT specified: |
125 | | -------- 1-b-ii-2: Snap is False; Max distance NOT specified: |
126 | | -------- 1-b-ii-3: Snap is True; Max distance is specified: |
127 | | -------- 1-b-ii-4: Snap is False; Max distance is specified: |
128 | | |
129 | | ---- 1-c: Source geometry partially outside of the extent of the desired raster: |
130 | | ------ 1-c-i: Generate Euclidean Distance from a one-band reference raster |
131 | | -------- 1-c-i-1: Snap is True; Max distance NOT specified: |
132 | | -------- 1-c-i-2: Snap is False; Max distance NOT specified: |
133 | | -------- 1-c-i-3: Snap is True; Max distance is specified: |
134 | | -------- 1-c-i-4: Snap is False; Max distance is specified: |
| 123 | 1-b-ii: Generate Euclidean Distance from a set of raster specifications: |
| 124 | 1-b-ii-1: Snap is True; Max distance NOT specified: |
| 125 | {{{ |
| 126 | #! |
| 127 | sql |
| 128 | CREATE TABLE test_eudist_1_b_ii_1 AS (SELECT 1 AS rid,ST_EuclideanDistance(10,10,0,0,1,1,0,0,4326,NULL,'32BF','public','test_source_geometry_1_b','the_geom',True) AS rast FROM test_ref_raster_1); |
| 129 | }}} |
| 130 | result: same as test_eudist_1_b_i_1.gif[BR]][[BR]] |
| 131 | 1-b-ii-2: Snap is True; Max distance is specified: |
| 132 | {{{ |
| 133 | #! |
| 134 | sql |
| 135 | CREATE TABLE test_eudist_1_b_ii_2 AS (SELECT 1 AS rid,ST_EuclideanDistance(10,10,0,0,1,1,0,0,4326,NULL,'32BF','public','test_source_geometry_1_b','the_geom',True,15) AS rast FROM test_ref_raster_1); |
| 136 | }}} |
| 137 | result: same as test_eudist_1_b_i_2.gif[BR]][[BR]] |
| 138 | 1-b-ii-3: Snap is False; Max distance NOT specified: |
| 139 | {{{ |
| 140 | #! |
| 141 | sql |
| 142 | CREATE TABLE test_eudist_1_b_ii_3 AS (SELECT 1 AS rid,ST_EuclideanDistance(10,10,0,0,1,1,0,0,4326,NULL,'32BF','public','test_source_geometry_1_b','the_geom',False) AS rast FROM test_ref_raster_1); |
| 143 | }}} |
| 144 | result: same as test_eudist_1_b_i_3.gif[BR]][[BR]] |
| 145 | 1-b-ii-4: Snap is False; Max distance is specified: |
| 146 | {{{ |
| 147 | #! |
| 148 | sql |
| 149 | CREATE TABLE test_eudist_1_b_ii_4 AS (SELECT 1 AS rid,ST_EuclideanDistance(10,10,0,0,1,1,0,0,4326,NULL,'32BF','public','test_source_geometry_1_b','the_geom',False,15) AS rast FROM test_ref_raster_1); |
| 150 | }}} |
| 151 | result: same as test_eudist_1_b_i_4.gif[BR]][[BR]] |
| 152 | [[BR]] |
| 153 | 1-c: Source geometry partially outside of the extent of the desired raster: |
| 154 | {{{ |
| 155 | #!sql |
| 156 | CREATE TABLE test_source_raster_1_c AS SELECT 1 AS rid,rast FROM (SELECT ST_MakeEmptyRaster(10,10,-5,-2,1,1,0,0,4326) AS rast)foo; |
| 157 | CREATE TABLE test_source_geometry_1_c AS SELECT generate_series(1,10) AS id,ST_RandomPoints(the_geom,10) AS the_geom FROM (SELECT ST_SetSRID(ST_Extent(rast::geometry),4326) AS the_geom FROM test_source_raster_1_c)foo; |
| 158 | }}} |
| 159 | 1-c-i: Generate Euclidean Distance from a one-band reference raster: |
| 160 | {{{ |
| 161 | #! |
| 162 | sql |
| 163 | CREATE TABLE test_eudist_1_c_i_1 AS (SELECT 1 AS rid,ST_EuclideanDistance(rast,'32BF','public','test_source_geometry_1_c','the_geom',True) AS rast FROM test_ref_raster_1); |
| 164 | }}} |
| 165 | result:[[BR]][[BR]] |
| 166 | [[Image(test_eudist_1_c_i_1.gif)]][[BR]] |
| 167 | 1-c-i-2: Snap is True; Max distance is specified: |
| 168 | {{{ |
| 169 | #! |
| 170 | sql |
| 171 | CREATE TABLE test_eudist_1_c_i_2 AS (SELECT 1 AS rid,ST_EuclideanDistance(rast,'32BF','public','test_source_geometry_1_c','the_geom',True,6) AS rast FROM test_ref_raster_1); |
| 172 | }}} |
| 173 | result:[[BR]][[BR]] |
| 174 | [[Image(test_eudist_1_c_i_2.gif)]][[BR]] |
| 175 | 1-c-i-3: Snap is False; Max distance NOT specified: |
| 176 | {{{ |
| 177 | #! |
| 178 | sql |
| 179 | CREATE TABLE test_eudist_1_c_i_3 AS (SELECT 1 AS rid,ST_EuclideanDistance(rast,'32BF','public','test_source_geometry_1_c','the_geom',False) AS rast FROM test_ref_raster_1); |
| 180 | }}} |
| 181 | result:[[BR]][[BR]] |
| 182 | [[Image(test_eudist_1_c_i_3.gif)]][[BR]] |
| 183 | 1-c-i-4: Snap is False; Max distance is specified: |
| 184 | {{{ |
| 185 | #! |
| 186 | sql |
| 187 | CREATE TABLE test_eudist_1_c_i_4 AS (SELECT 1 AS rid,ST_EuclideanDistance(rast,'32BF','public','test_source_geometry_1_c','the_geom',False,6) AS rast FROM test_ref_raster_1); |
| 188 | }}} |
| 189 | result:[[BR]][[BR]] |
| 190 | [[Image(test_eudist_1_c_i_4.gif)]][[BR]] |
| 191 | |