Convert between image orientation (top-left origin, y down) and GIS orientation (bottom-left origin, y up). Self-inverse.
Usage
at_flip_y(roi, height, call = rlang::caller_env())Arguments
- roi
An annot_roi.
- height
Numeric image height in pixels at the ROI's reference level.
- call
The calling environment, for error reporting.
Value
An annot_roi with the y-axis flipped.
Examples
at_flip_y(at_roi_rect(0, 0, 10, 5, label = "a"), height = 100)
#> <annot_roi> a (POLYGON)
#> id: "roi_000000014" | level: 0 | source: manual
#> bbox: [0, 95] - [10, 100]