Page 1 of 1

Set - An observation

Posted: 2016-10-06T06:27:26-07:00
by miket
I'm new to perl magic and am writing this post to highlight a "feature" which took me some time to resolve, in the hope that it might save others a bit of time in the future :)

Running (for example):

$image->Set(Alpha=>'Set');

does what it says on the tin !

For those of us with thick fingers, running:

$image->Set(Alphs=>'Set');

also runs (at least on my system), but creates an "Alphs" tag within the $image file with the value of 'Set'. This appears to happen silently (i.e. no warnings or errors).

The erroneous "Alphs" tag can be found using $image->Identify(); under Properties.

Whilst the ability to embed you own custom tags is certainly handy, it's a bit of a pain when it comes to troubleshooting!

I've not checked to see if there is the facility within perl magic to trap this error (I'm a bit lazy when it comes to error trapping in my scripts).

Hopefully this will save somebody some time at some time.

Mike