|
|
Line 61: |
Line 61: |
|
| |
|
|
| |
|
| ===Example=== | | ====Example==== |
| {| | | {| |
| |style="font-size:150%;"| | | |style="font-size:100%;"| |
| <syntaxhighlight lang="cpp"> | | <syntaxhighlight lang="cpp"> |
|
| |
|
Revision as of 20:47, 18 October 2022
Segments input color image by selecting a specified color. Rest of the image is converted to grayscale.
Function
CuviStatus colorPick(const CuviImage& src,
CuviImage& dst,
const CuviColor color,
const Cuvi32f threshold = 128.0f,
const CuviStream& stream = CuviStream());
|
Parameters
Name
|
Type
|
Description
|
src
|
const CuviImage&
|
Input Image
|
dst
|
CuviImage&
|
Destination Image
|
color
|
CuviColor
|
The color to select from the image
|
threshold
|
Cuvi32f
|
The threshold for color selection
|
stream
|
const CuviStream&
|
GPU stream ID for execution
|
|
Image Type Support
Sample
Example
//Creating GPU images
CuviImage input = cuvi:io::loadImage(path), output;
//Select blue color from the image.
cuvi::colorOperations::colorPick(input,output,CUVI_COLOR_BLUE);
|