php Imagick::levelImage usage

后端 未结 1 770
梦毁少年i
梦毁少年i 2021-01-23 06:34


I have trying hard, but can\'t make this method works properly.
The usage format is

Imagick::levelImage ( float $blackPoint , float $gamma , float $whi         


        
相关标签:
1条回答
  • 2021-01-23 07:26

    Looking at the ImageMagick documentation for LevelImage:

    Specify the levels where the black and white points have the range of 0-QuantumRange, and gamma has the range 0-10

    So a sensible call from PHP might look like this:

    //bool Imagick::levelImage ( float $blackPoint , float $gamma , float $whitePoint [, int $channel = Imagick::CHANNEL_ALL ] )
    $img->levelImage (20, 5, 220);
    

    I'm guessing the QuantumRange is set at 255, if not, try calling Imagick::getQuantumRange to find out what it is.

    If it still doesn't seem to work, I'll figure out what's wrong by writing example code.

    0 讨论(0)
提交回复
热议问题