|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #61134 Missing "setimageopacity", "Set" Methods and "PixelPacket" Access
Submitted: 2012-02-18 13:24 UTC Modified: 2012-02-28 14:24 UTC
Avg. Score:4.6 ± 0.8
Reproduced:4 of 4 (100.0%)
Same Version:2 (50.0%)
Same OS:1 (25.0%)
From: victorneufeld at hotmail dot com Assigned:
Status: Open Package: gmagick (PECL)
PHP Version: Irrelevant OS: Ubuntu Linux/Mac
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
Solve the problem:
36 - 32 = ?
Subscribe to this entry?

 [2012-02-18 13:24 UTC] victorneufeld at hotmail dot com
From manual page:
There are many parallels between Imagick and Gmagick functionality, but one key method seems to have been missed in Gmagick:

Imagick::setImageOpacity — Sets the image opacity level

It appears that the GraphicsMagick PHP port may not support the GraphicsMagick "SetImageOpacity" method, but it's not certain.  I've tried variations on the name without success (eg. SetImageOpacity, setImageOpacity, setimageopacity).  The documentation may not be up to date, but I suspect that the method may have been missed. 

Test script:
//Instantiate a new Gmagick object
$image = new Gmagick('p5_abg.png');
$image->setimageopacity( 0.5 );

Expected result:
Same results that I get with Imagick version:

$image = new Imagick('p5_abg.png');
$image->setImageOpacity( 0.5 );

Actual result:
PHP Fatal error:  Call to undefined method Gmagick::setimageopacity() in GMagickTest.php on line ##


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2012-02-28 14:24 UTC] victorneufeld at hotmail dot com
-Summary: Missing "SetImageOpacity" Method +Summary: Missing "setimageopacity", "Set" Methods and "PixelPacket" Access -Operating System: Ubuntu Linux +Operating System: Ubuntu Linux/Mac
 [2012-02-28 14:24 UTC] victorneufeld at hotmail dot com
As I examine and attempt to use the PHP class further, I am finding a number of other missing functions that further reduces its utility.  For example, there are a number of "get" functions defined in the PHP interface for which their corresponding "set" counterparts have not been included:

Furthermore the included "GmagickPixel" class does define a number of "get" and "set" functions that would be useful, but no means has been provided to gain access to those pixels, neutering their usefulness.  Interfaces to the following API functions would rectify this shortcoming:

Compare Gmagick to its closely-related Imagick counterpart, the latter of which has been richly translated to PHP.  I have used GraphicsMagick command-line for some time and would prefer to use its PHP equivalent, but am being hampered by the partial implementation.  I would prefer to take advantage of its purported faster processing, but can't do without the missing functionality so may end up having to use Imagick instead.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jun 24 20:01:30 2024 UTC