package image
Contains classes for representing discrete and continuous images as well as filters for filtering both types of images.
In this library, the standard type of images are just functions, defined on some domain. There is also the more traditional discrete image type, which represents image data on a regular pixel/voxel grid.
DiscreteImages are mainly used for reading/writing and simple manipulation of image values. The continuous representation of images is much more flexible and most method for manipulating images are defined only on this image type. A discrete image can be converted to a continuous image by using an interpolation procedure:
val domain = StructuredPoints(Point(0,0), Vector(1,1), Index(255,255)) val di = DiscreteImage(domain)(0) val discreteImage = DiscreteImage(domain, (_ : Point[_2D]) => 1.0f) val continuousImage = discreteImage.interpolate(3)
To get back the discrete representation, we can sample the image values on a regular grid:
val newDomain = StructuredPoints(Point(0,0), Vector(1,1), Index(128,128)) val resampledDiscreteImage = continuousImage.sample(domain, 0)
- Alphabetic
- By Inheritance
- image
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- sealed trait CreateStructuredPoints[D] extends AnyRef
Typeclass for creating domains of arbitrary dimensionality
- type DiscreteImage[D, A] = DiscreteField[D, DiscreteImageDomain, A]
- case class DiscreteImageDomain[D](structuredPoints: StructuredPoints[D])(implicit evidence$1: NDSpace[D]) extends DiscreteDomain[D] with Product with Serializable
- implicit class DiscreteImageOps[D, A] extends AnyRef
- abstract class StructuredPoints[D] extends PointSet[D] with Equals
Defines points in D dimension which are aligned on a regular grid.
Defines points in D dimension which are aligned on a regular grid.
The grid points are defined by specifying an origin, a spacing between the grid points, and the size (number of points) in each direction.
A global coordinate system is assumed, and all units are measured in mm.
- D
The dimensionality of the domain
- case class StructuredPoints1D(origin: Point[_1D], spacing: EuclideanVector[_1D], size: IntVector[_1D]) extends StructuredPoints[_1D] with Product with Serializable
- case class StructuredPoints2D(origin: Point[_2D], spacing: EuclideanVector[_2D], size: IntVector[_2D], phi: Double) extends StructuredPoints[_2D] with Product with Serializable
- case class StructuredPoints3D(origin: Point[_3D], spacing: EuclideanVector[_3D], size: IntVector[_3D], phi: Double, theta: Double, psi: Double) extends StructuredPoints[_3D] with Product with Serializable
Value Members
- object CreateStructuredPoints
- object DiscreteImage
Basic interface for a discrete image of arbitrary Pixel type
- object DiscreteImage1D
- object DiscreteImage2D
- object DiscreteImage3D
- object DiscreteImageDomain1D
- object DiscreteImageDomain2D
- object DiscreteImageDomain3D
- object StructuredPoints
Factory methods for creating StructuredPoints objects
- object StructuredPoints2D extends Serializable
- object StructuredPoints3D extends Serializable