Back to Adaptive Vision Library websiteYou are here:
Start »
Function Reference »
Image Conversions »
SelectChannel
Creates an image from a single channel of the input image.
Syntax
C++
C#
void avl::SelectChannel
(
const avl::Image& inImage,
atl::Optional<const avl::Region&> inRoi,
int inChannelIndex,
avl::Image& outImage
)
void SelectChannel
(
Image inImage,
Region? inRoi,
int inChannelIndex,
out Image outImage
)
Parameters
|
Name |
Type |
Range |
Default |
Description |
|
inImage |
const Image& |
|
|
Input image |
|
inRoi |
Optional<const Region&> |
|
NIL |
Range of pixels to be processed |
|
inChannelIndex |
int |
0 - 3 |
|
|
|
outImage |
Image& |
|
|
Output image |
Description
The operation extracts the selected color channel of inImage.
Examples
An example image used as inImage. |
The resulting outImage when inChannelIndex = 0. |
The resulting outImage when inChannelIndex = 1. |
The resulting outImage when inChannelIndex = 2. |
Hardware Acceleration
This operation supports automatic parallelization for multicore and multiprocessor systems.
Errors
Error type |
Description |
DomainError |
Channel index out of range in SelectChannel. |
See Also
- SplitChannels – Creates several monochromatic images from individual channels of the input image.