Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.

Good catch Alan! Now I just need to filter all the attempts to get the final pointsize and dimensions. That might do in the meantime.

Fred

PS. Unfortunately, I am having trouble using SED or GREP to extract the pointsize only from the debug text. Not sure if it is me or the way the text is output. It seems to go to the terminal and cannot be piped to SED or GREP.

PS2. using -debug annotate (even with label:) seems to give similar pointsize information, but not everything else. However, I still cannot filter that to get just the last pointsize.

Last edited by fmw42 on 2010-06-17T16:48:54-07:00, edited 1 time in total.

magick wrote:In the next release of ImageMagick, look for label:pointsize as a property.

Thanks. I am not sure how that will work. Do you mean that it will be reported with -verbose as in my command earlier? If so, that will be terrific, because I want to be able to extract the width, height and pointsize when using label: from once instance and then I can filter the text returned to get each of these properties. That will help a lot when using label to get the width, height and pointsize to feed then to -annotate to do the more fancier text creation.

magick wrote:In the next release of ImageMagick, look for label:pointsize as a property.

Thanks. I am not sure how that will work.

It means it will be set as an image properity (-set) or artifact (-define). probably the former. that in turn is accessible from verbose info: (identify) output, or -format percent escapes. Of course not all file formats will save the information, though it will be present in-memory or in MIFF.

whcih shows that 'label' contains the string that was used to generate the label! (something you recently came accross and commented on). When Cristy (magick) addes his code. then there will also be a label:pointsize 12 in the above. Which means you can access it using. a -format %[label:pointsize], just as you can with any other 'Property'.

I am hoping to have these properties report other information too. For example it could report the number of primitive iterations morphology last performed. Or in a connected object labelling operation I could have IM report the number of connected objects that it found and coloured.

Note -set also sets these labels. For example -set filename:tile_offset '%O' +repage would remove the virtual pixel offset, but still keep a copy of it for later use.
You can use +set to remove property.

-set option:... however will defines a 'artefact' (such as verbose does in the above example) -define also only sets artefacts. Artefacts are meant only to be used by image processing operators such as coders and expert options. For exampe -set option:compose:args ... actually sets a -define compose:args=...

I only learned this facite of Im operations myself recently, so only have rough notes about it in "Basics, Settings" at this time.