Difference between revisions of "Function:NOT"
From CUVI Wiki
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
Inverts the bits of each image pixel. | |||
===Function=== | ====Function==== | ||
{| | {| | ||
|style="font-size: | |style="font-size:100%;"| | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
CuviStatus NOT(const CuviImage& src, | CuviStatus NOT(const CuviImage& src, | ||
Line 10: | Line 10: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
|} | |} | ||
====Parameters==== | |||
{| | |||
|style="font-size:75%;"| | |||
{|class="wikitable" | {|class="wikitable" | ||
|- | |- | ||
Line 30: | Line 32: | ||
| 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 51: | Line 54: | ||
| 16uC3 | | 16uC3 | ||
| 16uC3 | | 16uC3 | ||
|} | |||
|} | |} | ||
===Sample=== | ===Sample=== | ||
[[File:NotIn.jpg|none|frame|Input Image]] | |||
<br/> | |||
[[File:NotOut.jpg|none|frame|Negative Image]] | |||
<br/> | |||
====Example==== | |||
===Example=== | |||
{| | {| | ||
|style="font-size: | |style="font-size:100%;"| | ||
<syntaxhighlight lang="cpp"> | <syntaxhighlight lang="cpp"> | ||
Line 73: | Line 75: | ||
//Computing Negative of the image | //Computing Negative of the image | ||
cuvi::arithmeticLogical::NOT(gimg,gout); | cuvi::arithmeticLogical::NOT(gimg,gout); | ||
//The same can be achieved using the ~ operator | |||
gout = ~gimg; | |||
</syntaxhighlight> | </syntaxhighlight> | ||
|} | |} |
Latest revision as of 20:20, 18 October 2022
Inverts the bits of each image pixel.
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
|