ClassesClasses | | Operators

pow_imagepow_imagePowImagePowImage (Operator)

Name

pow_imagepow_imagePowImagePowImage — Raise an image to a power.

Signature

pow_image(Image : PowImage : Exponent : )

Herror pow_image(const Hobject Image, Hobject* PowImage, double Exponent)

Herror T_pow_image(const Hobject Image, Hobject* PowImage, const Htuple Exponent)

void PowImage(const HObject& Image, HObject* PowImage, const HTuple& Exponent)

HImage HImage::PowImage(const HTuple& Exponent) const

HImage HImage::PowImage(double Exponent) const

static void HOperatorSet.PowImage(HObject image, out HObject powImage, HTuple exponent)

HImage HImage.PowImage(HTuple exponent)

HImage HImage.PowImage(double exponent)

Description

pow_imagepow_imagePowImagePowImagePowImage raises the gray values of the input image ImageImageImageImageimage to the power ExponentExponentExponentExponentexponent and stores the result in the image PowImagePowImagePowImagePowImagepowImage. If ImageImageImageImageimage contains gray values that would overflow the range of PowImagePowImagePowImagePowImagepowImage, e.g., > 7131.55017 for ExponentExponentExponentExponentexponent = 10, the corresponding gray values in PowImagePowImagePowImagePowImagepowImage are set to the largest value representable in PowImagePowImagePowImagePowImagepowImage (i.e., ). If ImageImageImageImageimage contains gray values that cannot be raised to the power ExponentExponentExponentExponentexponent, i.e., if the gray values are negative and ExponentExponentExponentExponentexponent is not an integer, the corresponding gray values in PowImagePowImagePowImagePowImagepowImage are set to 0.

Attention

pow_imagepow_imagePowImagePowImagePowImage can be executed on an OpenCL device for byte, int1, int2, uint2, int4, and real images. Note that the results of the OpenCL code may vary from the results produced by the CPU.

Execution Information

Parameters

ImageImageImageImageimage (input_object)  (multichannel-)image(-array) objectHImageHImageHobject (byte* / int1* / uint2* / int2* / int4* / int8 / real*) *allowed for compute devices

Input image.

PowImagePowImagePowImagePowImagepowImage (output_object)  (multichannel-)image(-array) objectHImageHImageHobject * (real)

Output image.

ExponentExponentExponentExponentexponent (input_control)  number HTupleHTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Power to which the gray values are raised.

Default value: 2

Suggested values: 0.25, 0.5, 2, 3, 4

Alternatives

gamma_imagegamma_imageGammaImageGammaImageGammaImage

See also

sqrt_imagesqrt_imageSqrtImageSqrtImageSqrtImage, exp_imageexp_imageExpImageExpImageExpImage, log_imagelog_imageLogImageLogImageLogImage

Module

Foundation


ClassesClasses | | Operators