Learn R Programming

rayimage (version 0.26.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

2,258

Version

0.26.1

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Tyler Morgan-Wall

Last Published

June 12th, 2026

Functions in rayimage (0.26.1)

get_whitepoint_xyz

Normalize/label a white point
preview_focus

Preview Focus
generate_2d_disk

Generate 2D Disk
render_bokeh

Render Bokeh
print.rayimg

Print method for rayimg
render_boolean_distance

Render Boolean Distance
make_vignette_overlay

Make Vignette Overlay
flipud

Flip Up-Down
add_padding

add_padding
offset_alpha

Offset Alpha Matrix
handle_image_output

Handle Image Output
render_crop

Crop Image
ray_read_image

Read Image
dragondepth

Dragon Depthmap
ray_write_image

Write Image
render_text_image

Generate Text Image
render_stack

Stack Images
dragon

Dragon Image
rotate_image_array

Rotate an image array around its center
rgb_to_hex

Encode RGB/RGBA to hex (sRGB domain)
fill_alpha_gaps

Fill Border Alpha Gaps
expand_to_fit

expand to fit
plot_image_grid

Plot Image Grid
plot_image

Plot Image
render_clamp

Clamp Image
render_gamma_linear

Render Gamma/Linear
render_bw

Render Black and White
render_image_overlay

Add Overlay
find_border_alpha_gaps

Find Border Alpha Gaps
get_string_dimensions

Get String Dimensions
fliplr

Flip Left-Right
get_file_type

Check Filename
rayimg

Create a rayimg
render_white_balance

Render White Balance (Bradford CAT)
render_exposure

Apply exposure compensation and ISO gain
render_vignette

Add Vignette Effect
generate_2d_gaussian

Generate 2D Gaussian Distribution
make_colorspace

Build a colorspace descriptor
generate_2d_exponential

Generate 2D exponential Distribution
interpolate_array

Matrix/Array Interpolation
linear_png_device

Select PNG Device
render_convert_colorspace

Render Convert Colorspace
render_color_correction

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

Render Tonemap
render_vibrance

Render Vibrance
render_reorient

Reorient Image
to_linear

sRGB to Linear
render_padding

Add Transparent Padding
sunset_image

Sunset Image
render_alpha_outline

Render Alpha Outline
rayimg_vertical_ellipsis

Vertical ellipsis symbol
to_srgb

Linear to sRGB
trim_padding

trim_padding
rayimg_composite_checker

Compose RGB over checkerboard using alpha
make_rgb_xyz_matrices

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

Plot Native Raster with Custom Aspect Ratio
pad_to_fit

pad to fit
render_convolution_fft

Render Convolution FFT
render_resized

Resize Image
render_sprite_overlay

Add Sprite Overlay
render_title

Render a Title on an Image
render_convolution

Render Convolution
render_to_display

Render To Display
composite_alpha_outline_image

Composite Alpha Outline Image
colorspace_descriptors

Prebuilt RGB Working/Display Color Spaces
compute_cat_bradford

Bradford CAT matrix from source to target white
convert_to_native_raster

Convert to Native Raster
calc_bokeh_size

Calculate Bokeh Size
array_rgb_to_hex_colmajor

Array hex vector in column-major order
add_multi_padding

add_multi_padding
apply_color_matrix

Apply a 3x3 color transform to an image
convert_color

Convert Color