Skip to content

log

Core and matricesfunctionOpenCV 5.0.0
import { log } from '@banou/opencv-wasm'

Use after await initOpenCV(). See the initialization and named imports guide.

ARGUMENTSsrc, dst
FUNCTIONlog
RETURN TYPEvoid
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Calculates the natural logarithm of every array element.

The function cv::log calculates the natural logarithm of every element of the input array:

\texttt{dst} (I) =  \log (\texttt{src}(I)) 

Output on zero, negative and special (NaN, Inf) values is undefined.

See: exp, cartToPolar, polarToCart, phase, pow, sqrt, magnitude

log(src: Mat, dst: Mat): void;
src

input array.

dst

Output destination, filled by the native operation. output array of the same size and type as src .

These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.