|
SOLUTIONS
|
CUDALINK SYMBOL
CUDAColorNegate
CUDAColorNegate[image]
performs color negation on image.
CUDAColorNegate[list]
performs color negation on list.
CUDAColorNegate[mem]
performs color negation on memory referenced by mem.
DetailsDetails
- The CUDALink package must be loaded using Needs["CUDALink`"].
works with binary, grayscale, and other images.
works with CUDAMemory and lists.- If multiple image channels are present,
operates on each of them separately. - If the input type is Real, then the input is subtracted from
, not
.
does not work on fixed vector structure types like
,
, ....- The following options can be given:
-
"Device" $CUDADevice CUDA device used to perform computation "OutputMemory" None output memory provided to avoid creating new memory location
ExamplesExamplesopen allclose all
Basic Examples (5)Basic Examples (5)
First, load the CUDALink application:
| In[1]:= |
This performs color negation on the input color image:
| In[2]:= |
| Out[2]= | ![]() |
This inverts a grayscale image:
| In[1]:= |
| Out[1]= | ![]() |
| In[1]:= |
| Out[1]= | ![]() |
This performs color negation on the input list:
| In[1]:= |
| Out[1]= |
If the input is CUDAMemory, then memory is returned as output:
| In[1]:= |
| Out[1]= |
| In[2]:= |
| Out[2]= |
Memory is retrieved using CUDAMemoryGet:
| In[3]:= |
| Out[3]= | ![]() |
Mathematica 9 is now available!
New to Mathematica?
Find your learning path »
Have a question?
Ask support »






