Difference between revisions of "Function:ColorPick"
From CUVI Wiki
(Created page with "__NOTOC__ Segments input color image by selecting a specified color. Rest of the image is converted to grayscale. ===Function=== {| |style="font-size:150%;"| <syntaxhighlight ...") |
(→Sample) |
||
(7 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
Segments input color image by selecting a specified color. Rest of the image is converted to grayscale. | Segments input color image by selecting a specified color. Rest of the image is converted to grayscale. | ||
===Function=== | ====Function==== | ||
{| | {| | ||
|style="font-size: | |style="font-size:100%;"| | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
Line 13: | Line 13: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
|} | |} | ||
====Parameters==== | |||
{| | |||
|style="font-size:75%;"| | |||
{|class="wikitable" | {|class="wikitable" | ||
|- | |- | ||
Line 40: | Line 42: | ||
| const CuviStream& | | const CuviStream& | ||
| GPU stream ID for execution | | GPU stream ID for execution | ||
|} | |||
|} | |} | ||
===Image Type Support=== | ====Image Type Support==== | ||
{| | |||
|style="font-size:75%;"| | |||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
Line 52: | Line 55: | ||
| 8uC3 | | 8uC3 | ||
| 8uC3 | | 8uC3 | ||
|} | |||
|} | |} | ||
===Sample=== | ====Sample==== | ||
[[File:960px.jpg|none|frame|Input Image]] | |||
<br/> | |||
[[File:ColorPick.jpg|none|frame|Picked Color]] | |||
<br/> | |||
===Example=== | ====Example==== | ||
{| | {| | ||
|style="font-size: | |style="font-size:100%;"| | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
//Creating GPU images | //Creating GPU images | ||
CuviImage | CuviImage input = cuvi:io::loadImage(path), output; | ||
//Select blue color from the image. | //Select blue color from the image. | ||
cuvi:: | cuvi::colorOperations::colorPick(input,output,CUVI_COLOR_BLUE); | ||
</syntaxhighlight> | </syntaxhighlight> | ||
|} | |} |
Latest revision as of 20:53, 18 October 2022
Segments input color image by selecting a specified color. Rest of the image is converted to grayscale.
Function
|
Parameters
|
Image Type Support
|
Sample
Error creating thumbnail: Unable to save thumbnail to destination
Error creating thumbnail: Unable to save thumbnail to destination
Example
|