Showing 1 of 3 files from the diff.

@@ -2055,7 +2055,11 @@
Loading
2055 2055
    if (isTRUE(useSAcrs)) {
2056 2056
      targCRS <- .crs(studyArea)
2057 2057
    } else {
2058 -
      targCRS <- srcCRS
2058 +
      if (!is.null(rasterToMatch)) {
2059 +
        targCRS <- crs(rasterToMatch)
2060 +
      } else {
2061 +
        targCRS <- srcCRS
2062 +
      }
2059 2063
      studyAreasf <- sf::st_transform(studyAreasf, crs = targCRS)
2060 2064
    }
2061 2065
    # write the studyArea to disk -- go via sf because faster
@@ -2066,12 +2070,15 @@
Loading
2066 2070
2067 2071
2068 2072
  } else if (!is.null(rasterToMatch)) {
2069 -
    needNewRes <- !identical(res(x), res(rasterToMatch))
2073 +
2070 2074
    cropExtent <- extent(rasterToMatch)
2071 2075
    targCRS <- .crs(rasterToMatch)
2072 2076
  }
2073 2077
  dontSpecifyResBCLongLat <- isLongLat(targCRS, srcCRS)
2074 2078
2079 +
  if (!is.null(rasterToMatch)) {
2080 +
    needNewRes <- !identical(res(x), res(rasterToMatch))
2081 +
  }
2075 2082
  ## GDAL requires file path to cutline - write to disk
2076 2083
  tr <- if (needNewRes) res(rasterToMatch) else res(x)
2077 2084
@@ -2095,6 +2102,10 @@
Loading
2095 2102
    }
2096 2103
  }
2097 2104
2105 +
  if (!is.character(targCRS)) {
2106 +
    targCRS <- as.character(targCRS)
2107 +
  }
2108 +
2098 2109
  cores <- dealWithCores(cores)
2099 2110
  prll <- paste0("-wo NUM_THREADS=", cores, " ")
2100 2111
  # browser(expr = exists("._cropReprojMaskWGDAL_2"))
Files Coverage
R 67.73%
Project Totals (25 files) 67.73%
1
comment: false
2

3
coverage:
4
  status:
5
    project:
6
      default:
7
        target: auto
8
        threshold: 1%
9
        informational: true
10
    patch:
11
      default:
12
        target: auto
13
        threshold: 1%
14
        informational: true
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading