Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-Fix typos #280

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion R/add_overlay.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#'If the array is 3D, `alphacolor` should also be passed to indicate transparent regions.
#'@param alphalayer Default `1`. Defines minimum tranparaency of layer. If transparency already exists in `overlay`, the way `add_overlay` combines
#'the two is determined in argument `alphamethod`.
#'@param alphacolor Default `NULL`. If `overlay` is a 3-layer array, this argument tells which color is interpretted as completely transparent.
#'@param alphacolor Default `NULL`. If `overlay` is a 3-layer array, this argument tells which color is interpreted as completely transparent.
#'@param alphamethod Default `max`. Method for dealing with pre-existing transparency with `layeralpha`.
#'If `max`, converts all alpha levels higher than `layeralpha` to the value set in `layeralpha`. Otherwise,
#'this just sets all transparency to `layeralpha`.
Expand Down
2 changes: 1 addition & 1 deletion R/ambient_shade.R
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#'@param heightmap A two-dimensional matrix, where each entry in the matrix is the elevation at that point. All points are assumed to be evenly spaced.
#'@param anglebreaks Default `90*cospi(seq(5, 85,by =5)/180)`. The angle(s), in degrees, as measured from the horizon from which the light originates.
#'@param sunbreaks Default `24`. Number of rays to be sent out in a circle, evenly spaced, around the point being tested.
#'@param maxsearch Default `30`. The maximum horizontal distance that the system should propogate rays to check for surface intersections.
#'@param maxsearch Default `30`. The maximum horizontal distance that the system should propagate rays to check for surface intersections.
#'@param multicore Default FALSE. If TRUE, multiple cores will be used to compute the shadow matrix. By default, this uses all cores available, unless the user has
#'set `options("cores")` in which the multicore option will only use that many cores.
#'@param zscale Default 1. The ratio between the x and y spacing (which are assumed to be equal) and the z axis.
Expand Down
2 changes: 1 addition & 1 deletion R/convert_path_to_animation_coords.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#'@param long Vector of longitudes (or other coordinate in the same coordinate reference system as extent).
#'@param lat Vector of latitudes (or other coordinate in the same coordinate reference system as extent).
#'@param altitude Elevation of each point, in units of the elevation matrix (scaled by zscale).
#'If left `NULL`, this will be just the elevation value at ths surface, offset by `offset`. If a single value,
#'If left `NULL`, this will be just the elevation value at this surface, offset by `offset`. If a single value,
#'all data will be rendered at that altitude.
#'@param extent Either an object representing the spatial extent of the scene
#' (either from the `raster`, `terra`, `sf`, or `sp` packages),
Expand Down
2 changes: 1 addition & 1 deletion R/plot_gg.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
#'if `triangulate = TRUE`.
#'@param emboss_text Default `0`, max `1`. Amount to emboss the text, where `1` is the tallest feature in the scene.
#'@param emboss_grid Default `0`, max `1`. Amount to emboss the grid lines, where `1` is the tallest feature in the scene.
#'By default, the minor grid lines will be half the size of the major lines. Pass a length-2 vector to specify them seperately (second value
#'By default, the minor grid lines will be half the size of the major lines. Pass a length-2 vector to specify them separately (second value
#'is the minor grid height).
#'@param reduce_size Default `NULL`. A number between `0` and `1` that specifies how much to reduce the resolution of the plot, for faster plotting. By
#'default, this just decreases the size of height map, not the image. If you wish the image to be reduced in resolution as well, pass a numeric vector of size 2.
Expand Down
2 changes: 1 addition & 1 deletion R/ray_shade.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#'@title Calculate Raytraced Shadow Map
#'
#'@description Calculates shadow map for a elevation matrix by propogating rays from each matrix point to the light source(s),
#'@description Calculates shadow map for a elevation matrix by propagating rays from each matrix point to the light source(s),
#' lowering the brightness at each point for each ray that intersects the surface.
#'
#'@param heightmap A two-dimensional matrix, where each entry in the matrix is the elevation at that point. All points are assumed to be evenly spaced.
Expand Down
2 changes: 1 addition & 1 deletion R/render_depth.R
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
#'`1` is the darkest vignetting, while `0` is no vignetting. If vignette is a length-2 vector, the second entry will
#'control the blurriness of the vignette effect.
#'@param vignette_color Default `"black"`. Color of the vignette.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a porportion of the image dimensions.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a proportion of the image dimensions.
#'@param width Default `NULL`. Optional argument to pass to `rgl::snapshot3d()` to specify the
#'width when `software_render = TRUE`..
#'@param height Default `NULL`. Optional argument to pass to `rgl::snapshot3d()` to specify the
Expand Down
4 changes: 2 additions & 2 deletions R/render_movie.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#'Other options are `oscillate` (sine wave around `theta` value, covering 90 degrees), or `custom` (which uses the values from the
#'`theta`, `phi`, `zoom`, and `fov` vectors passed in by the user).
#'@param frames Default `360`. Number of frames to render.
#'@param fps Default `30`. Frames per second. Recommmend either 30 or 60 for web.
#'@param fps Default `30`. Frames per second. Recommend either 30 or 60 for web.
#'@param phi Defaults to current view. Azimuth values, in degrees.
#'@param theta Default to current view. Theta values, in degrees.
#'@param zoom Defaults to the current view. Zoom value, between `0` and `1`.
Expand All @@ -36,7 +36,7 @@
#'`1` is the darkest vignetting, while `0` is no vignetting. If vignette is a length-2 vector, the second entry will
#'control the blurriness of the vignette effect.
#'@param vignette_color Default `"black"`. Color of the vignette.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a porportion of the image dimensions.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a proportion of the image dimensions.
#'@param audio Default `NULL`. Optional file with audio to add to the video.
#'@param progbar Default `TRUE` if interactive, `FALSE` otherwise. If `FALSE`, turns off progress bar.
#'Will display a progress bar when adding an overlay or title.
Expand Down
2 changes: 1 addition & 1 deletion R/render_obj.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#'@param long Vector of longitudes (or other coordinate in the same coordinate reference system as extent).
#'@param lat Vector of latitudes (or other coordinate in the same coordinate reference system as extent).
#'@param altitude Default `NULL`. Elevation of each point, in units of the elevation matrix (scaled by `zscale`).
#'If left `NULL`, this will be just the elevation value at ths surface, offset by `offset`. If a single value,
#'If left `NULL`, this will be just the elevation value at this surface, offset by `offset`. If a single value,
#'the OBJ will be rendered at that altitude.
#'@param xyz Default `NULL`, ignored. A 3 column numeric matrix, with each row specifying the x/y/z
#'coordinates of the OBJ model(s). Overrides lat/long/altitude and ignores extent to plot the OBJ in raw rgl coordinates.
Expand Down
2 changes: 1 addition & 1 deletion R/render_path.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#'@param long Default `NULL`. Vector of longitudes (or other coordinate in the same coordinate reference system as extent).
#'Ignored if lat is an `sf` or `SpatialLineDataFrame` object.
#'@param altitude Default `NULL`. Elevation of each point, in units of the elevation matrix (scaled by zscale).
#'If left `NULL`, this will be just the elevation value at ths surface, offset by `offset`. If a single value,
#'If left `NULL`, this will be just the elevation value at this surface, offset by `offset`. If a single value,
#'all data will be rendered at that altitude.
#'@param groups Default `NULL`. Integer vector specifying the grouping of each lat/long path segment, if lat/long are
#'specified as numeric vectors (as opposed to `sf` or `SpatialLineDataFrame` objects, where this information
Expand Down
2 changes: 1 addition & 1 deletion R/render_snapshot.R
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#'`1` is the darkest vignetting, while `0` is no vignetting. If vignette is a length-2 vector, the second entry will
#'control the blurriness of the vignette effect.
#'@param vignette_color Default `"black"`. Color of the vignette.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a porportion of the image dimensions.
#'@param vignette_radius Default `1.3`. Radius of the vignette, as a proportion of the image dimensions.
#'@param clear Default `FALSE`. If `TRUE`, the current `rgl` device will be cleared.
#'@param instant_capture Default `TRUE` if interactive, `FALSE` otherwise. If `FALSE`, a slight delay is added
#'before taking the snapshot. This can help stop prevent rendering issues when running scripts.
Expand Down
2 changes: 1 addition & 1 deletion R/render_tree.R
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ render_tree = function(lat = NULL,

# Handling case where both full tree and parts are specified
if(custom_tree && has_custom_tree && (has_custom_crown || has_custom_trunk)) {
warning("Using `custom_obj_tree` over models specied in `custom_obj_crown` and `custom_obj_trunk`")
warning("Using `custom_obj_tree` over models specified in `custom_obj_crown` and `custom_obj_trunk`")
has_custom_crown = FALSE
has_custom_trunk = FALSE
}
Expand Down
2 changes: 1 addition & 1 deletion R/resize_matrix.R
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#'e.g. 0.5 would halve the resolution for the width.
#'@param height Default `NULL`. Alternative to `scale` argument. The desired output width. If `height` is less than 1, it will be interpreted as a scaling factor--
#'e.g. 0.5 would halve the resolution for the height.
#'@param method Default `bilinear`. Method of interpolation. Alteratively `cubic`, which is slightly smoother, although
#'@param method Default `bilinear`. Method of interpolation. Alternatively `cubic`, which is slightly smoother, although
#'current implementation slightly scales the image.
#'@export
#'@examples
Expand Down
4 changes: 2 additions & 2 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Also included are functions to add additional effects and information to your 3D
- `render_highquality()` renders in the scene with a built-in pathtracer, powered by the **rayrender** package. Use this for high-quality maps with realistic light transport.
- `render_depth()` generates a depth of field effect for the 3D map. The user can specify the focal distance, focal length, and f-stop of the camera, as well as aperture shape and bokeh intensity. This either plots the image to the local device, or saves it to a file if given a filename.
- `render_label()` adds a text label to the `x` and `y` coordinate of the map at a specified altitude `z` (in units of the matrix). The altitude can either be specified relative to the elevation at that point (the default), or absolutely.
- `render_water()` adds a 3D tranparent water layer to 3D maps, after the rgl device has already been created. This can either add to a map that does not already have a water layer, or replace an existing water layer on the map.
- `render_water()` adds a 3D transparent water layer to 3D maps, after the rgl device has already been created. This can either add to a map that does not already have a water layer, or replace an existing water layer on the map.
- `render_compass()` places a compass on the map in 3D.
- `render_path()` adds a 3D path to the current scene, using latitude/longitude or coordinates in the reference system defined by the extent object. If no altitude is provided, the path will be elevated a constant offset above the heightmap.
- `render_points()` Adds 3D points to the current scene, using latitude/longitude or coordinates in the reference system defined by the extent object. If no altitude is provided, the points will be elevated a constant offset above the heightmap.
Expand Down Expand Up @@ -252,7 +252,7 @@ rgl::rgl.close()
system("rm dem_01.tif")
```

You can also easily add a water layer by setting `water = TRUE` in `plot_3d()` (and setting `waterdepth` if the water level is not 0), or by using the function `render_water()` after the 3D map has been rendered. You can customize the appearance and transparancy of the water layer via function arguments. Here's an example using bathymetric/topographic data of Monterey Bay, CA (included with rayshader):
You can also easily add a water layer by setting `water = TRUE` in `plot_3d()` (and setting `waterdepth` if the water level is not 0), or by using the function `render_water()` after the 3D map has been rendered. You can customize the appearance and transparency of the water layer via function arguments. Here's an example using bathymetric/topographic data of Monterey Bay, CA (included with rayshader):

```{r README_three-d-water, fig.width = 10, fig.height = 8}

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ your 3D visualizations:
the map at a specified altitude `z` (in units of the matrix). The
altitude can either be specified relative to the elevation at that
point (the default), or absolutely.
- `render_water()` adds a 3D tranparent water layer to 3D maps, after
- `render_water()` adds a 3D transparent water layer to 3D maps, after
the rgl device has already been created. This can either add to a
map that does not already have a water layer, or replace an existing
water layer on the map.
Expand Down Expand Up @@ -347,7 +347,7 @@ render_highquality(samples=200, scale_text_size = 24,clear=TRUE)
You can also easily add a water layer by setting `water = TRUE` in
`plot_3d()` (and setting `waterdepth` if the water level is not 0), or
by using the function `render_water()` after the 3D map has been
rendered. You can customize the appearance and transparancy of the water
rendered. You can customize the appearance and transparency of the water
layer via function arguments. Here’s an example using
bathymetric/topographic data of Monterey Bay, CA (included with
rayshader):
Expand Down
2 changes: 1 addition & 1 deletion man/add_overlay.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/ambient_shade.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/convert_path_to_animation_coords.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/plot_gg.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/ray_shade.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/render_depth.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions man/render_movie.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/render_obj.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/render_path.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/render_snapshot.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading