% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/vis_volume.R
\name{volvis.lightbox}
\alias{volvis.lightbox}
\title{Draw a lightbox view from volume slices.}
\usage{
volvis.lightbox(
  volume,
  slices = -5,
  axis = 1L,
  per_row = 5L,
  per_col = NULL,
  border_geometry = "5x5",
  background_color = "#000000",
  arrange_single_image = FALSE
)
}
\arguments{
\item{volume}{3D array, can be numeric (gray-scale intensity values) or color strings. If numeric, the intensity values must be in range \verb{[0, 1]}.}

\item{slices}{slice index definition. If a vector of integers, interpreted as slice indices. If a single negative interger \code{-n}, interpreted as every \code{nth} slice, starting at slice 1. The character string 'all' or the value \code{NULL} will be interpreted as \emph{all slices}.}

\item{axis}{positive integer in range 1L..3L, the axis to use.}

\item{per_row}{positive integer, the number of subimages per row in the output image. If \code{NULL}, automatically computed from the number of slices and the \code{per_col} parameter.}

\item{per_col}{positive integer, the number of subimages per column in the output image. If \code{NULL}, automatically computed from the number of slices and the \code{per_row} parameter.}

\item{border_geometry}{string, a geometry string passed to \code{magick::image_border} to define the borders to add to each image tile. The default value adds 5 pixels, both horizontally and vertically.}

\item{background_color}{string, a valid ImageMagick color string such as "white" or "#000080". The color to use when extending images (e.g., when creating the border). Defaults to black.}

\item{arrange_single_image}{logical, whether to apply the given arrangement (from parameters \code{per_row} and \code{per_column}) even if a single slice (a 2D image) is passed as \code{volume}. Defaults to FALSE, which prevents that background tiles are added to fill the row up to \code{per_row} images. This also prevents the border from getting added to a single image, so all you see is the raw image. Set to \code{TRUE} if you want to arrange even a single image in a row with a border.}
}
\value{
a magick image instance
}
\description{
A lightbox is a single image that holds a set of subimages, arranged in a grid. The images can have a small border or spacing between them. Consecutive subimages will be appear the same row of the grid.

If overlay_colors are given, the volume will be used as the background, and it will only be visible where overlay_colors has transparency.
}
\note{
You should, in most cases, not call this function directly. Use \code{\link[fsbrain]{volvis.lb}} instead, which has a more intuitive interface.
}
\seealso{
\code{\link[fsbrain]{volvis.lb}}

Other volume visualization: 
\code{\link{vis.volume.on.surface}()},
\code{\link{volvis.lb}()},
\code{\link{volvis.lb.with.surface}()}
}
\concept{volume visualization}
