pierreroudier / hillshader

Create Shaded Relief Maps using Ray-Tracing
GNU General Public License v3.0
32 stars 2 forks source link

New functions #2

Open JanCaha opened 3 years ago

JanCaha commented 3 years ago

More then issue I have a proposal.

When rayshader became a thing I wrote package rather similar to yours (available here). I never aimed at CRAN for various reasons, but mostly because I condsidered the package rather trivial. However, seeing that someone but the time and effort into getting the package to CRAN got me thinking...

One of my main aims and use cases was to allow construction of shade maps based on location (obtained from raster) and date with time. Which I consider interesting for GIS applications.

I would like to contribute sections of code from my package here, to bring the mentioned functionality to this package. Would that make sense?

pierreroudier commented 3 years ago

@JanCaha Thanks for reaching out! Just had a quick look at the code, and I think it is a great idea.

What are your thoughts? We could include some of the rasterShade code as options to the hillshader function:

hs <- hillshader(
  elevation = maungawhau_hr, 
  shader = c("ray_shade", "ambient_shade"), 
  date = "2021-06-14T04:10:40+00:00" # ISO8601, but could be parsed using {lubridate}
)

with the spatial position taken as the centre of the raster extent?