Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

add.colour

Add colour channels to a grayscale image or pixel set


Description

Add colour channels to a grayscale image or pixel set

Usage

add.colour(im, simple = TRUE)

add.color(im, simple = TRUE)

Arguments

im

a grayscale image

simple

if TRUE just stack three copies of the grayscale image, if FALSE treat the image as the L channel in an HSL representation. Default TRUE. For pixel sets this option makes no sense and is ignored.

Value

an image of class cimg

Functions

  • add.color: Alias for add.colour

Author(s)

Simon Barthelme

Examples

grayscale(boats) #No more colour channels
add.colour(grayscale(boats)) #Image has depth = 3 (but contains only grays)

imager

Image Processing Library Based on 'CImg'

v0.42.10
LGPL-3
Authors
Simon Barthelme [aut], David Tschumperle [ctb], Jan Wijffels [ctb], Haz Edine Assemlal [ctb], Shota Ochi [cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.