Learn R Programming

rayimage (version 0.27.1)

Image Processing for Simulated Cameras

Description

Uses convolution-based techniques to generate simulated camera bokeh, depth of field, and other camera effects, using an image and an optional depth map. Accepts both filename inputs and in-memory array representations of images and matrices, including common raster formats such as 'JPEG', 'PNG', 'TIFF', 'TGA', 'BMP', 'PSD', 'GIF', 'HDR', 'PIC', 'PNM', 'DNG', and 'EXR'. Includes functions to perform 2D convolutions, color correction, colorspace conversion, image/matrix reorientation and resizing, image and text overlays, exposure adjustment, camera vignette effects, and image titles.

Copy Link

Version

Install

install.packages('rayimage')

Monthly Downloads

1,871

Version

0.27.1

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Tyler Morgan-Wall

Last Published

September 13th, 2026

Functions in rayimage (0.27.1)

composite_alpha_outline_image

Composite Alpha Outline Image
estimate_environment_white

Estimate Lat-Long Environment White
expand_to_fit

expand to fit
compute_cat_bradford

Bradford CAT matrix from source to target white
interpolate_array

Matrix/Array Interpolation
linear_png_device

Select PNG Device
convert_color

Convert Color
dragondepth

Dragon Depthmap
offset_alpha

Offset Alpha Matrix
flipud

Flip Up-Down
dragon

Dragon Image
make_colorspace

Build a colorspace descriptor
generate_2d_exponential

Generate 2D exponential Distribution
generate_2d_disk

Generate 2D Disk
generate_2d_gaussian

Generate 2D Gaussian Distribution
get_string_dimensions

Get String Dimensions
preserved_exr_metadata

Preserve EXR metadata not promoted to rayimg attributes
normalize_exr_chromaticities

Normalize EXR chromaticities metadata
convert_to_native_raster

Convert to Native Raster
get_file_type

Check Filename
pad_to_fit

pad to fit
libopenexr_supports_metadata

Check whether libopenexr supports metadata
plot_asp_native_raster

Plot Native Raster with Custom Aspect Ratio
rayimg_composite_checker

Compose RGB over checkerboard using alpha
apply_color_matrix

Apply a 3x3 color transform to an image
preview_focus

Preview Focus
print.rayimg

Print method for rayimg
make_vignette_overlay

Make Vignette Overlay
handle_image_output

Handle Image Output
get_whitepoint_xyz

Normalize/label a white point
array_rgb_to_hex_colmajor

Array hex vector in column-major order
make_rgb_xyz_matrices

Build RGB-to-XYZ matrices from primaries + white
ray_read_image

Read Image
render_crop

Crop Image
render_bokeh

Render Bokeh
render_convert_colorspace

Render Convert Colorspace
render_convolution

Render Convolution
render_alpha_outline

Render Alpha Outline
plot_image

Plot Image
render_reorient

Reorient Image
render_resized

Resize Image
render_bw

Render Black and White
render_sprite_overlay

Add Sprite Overlay
render_boolean_distance

Render Boolean Distance
render_padding

Add Transparent Padding
render_convolution_fft

Render Convolution FFT
rayimg_vertical_ellipsis

Vertical ellipsis symbol
ray_write_image

Write Image
render_clamp

Clamp Image
render_color_correction

Render Color Correction Matrix (3x3, linear RGB)
rayimg

Create a rayimg
render_tonemap

Render Tonemap
xyz_to_xy

Convert XYZ to xy chromaticity coordinates
render_image_overlay

Add Overlay
render_gamma_linear

Render Gamma/Linear
plot_image_grid

Plot Image Grid
render_vibrance

Render Vibrance
render_environment_white_balance

White Balance with a Lat-Long Environment Map
render_exposure

Apply exposure compensation and ISO gain
render_title

Render a Title on an Image
render_to_display

Render To Display
render_vignette

Add Vignette Effect
rgb_to_hex

Encode RGB/RGBA to hex (sRGB domain)
white_current_from_exr_metadata

Get the adopted neutral white point from EXR metadata
xy_to_xyz

Convert xy chromaticity coordinates to XYZ
sunset_image

Sunset Image
to_linear

sRGB to Linear
render_white_balance

Render White Balance (Bradford CAT)
rotate_image_array

Rotate an image array around its center
render_stack

Stack Images
trim_padding

trim_padding
render_text_image

Generate Text Image
to_srgb

Linear to sRGB
calc_bokeh_size

Calculate Bokeh Size
colorspace_descriptors

Prebuilt RGB Working/Display Color Spaces
find_border_alpha_gaps

Find Border Alpha Gaps
fliplr

Flip Left-Right
fill_alpha_gaps

Fill Border Alpha Gaps
exr_metadata_from_rayimg

Build EXR metadata from a rayimg
colorspace_from_exr_metadata

Build a colorspace descriptor from EXR metadata
add_multi_padding

add_multi_padding
add_padding

add_padding
colorspace_to_exr_chromaticities

Convert a colorspace descriptor to EXR chromaticities metadata