Fortify method for classes from the terra package.
Examples
r_df <- fortifySpatRaster(rlogo)
head(r_df)
#> x y red green blue
#> 1 0.5 76.5 255 255 255
#> 2 1.5 76.5 255 255 255
#> 3 2.5 76.5 255 255 255
#> 4 3.5 76.5 255 255 255
#> 5 4.5 76.5 255 255 255
#> 6 5.5 76.5 255 255 255