I am trying to draw a rectangle across the full width of an image with convert
[1]. I am trying to use ImageMagick Attributes to accomplish this.
The command I use is this:
convert ImageFile -fill black -stroke black -draw "rectangle 0,0 %[w],42" ImageFileNew
The Output I get is:
convert: NonconformingDrawingPrimitiveDefinition `rectangle' @ error/draw.c/DrawImage/3271.
With debug:
convert ImageFile -fill black -stroke black -draw "rectangle 0,0 %[w],42" ImageFileNew
I get:
2016-07-27T14:55:37+02:00 0:00.047 0.047u 7.0.2 Draw CONVERT[6660]: draw.c/DrawImage/1755/Draw
begin draw-image
2016-07-27T14:55:37+02:00 0:00.047 0.047u 7.0.2 Draw CONVERT[6660]: draw.c/DrawImage/3207/Draw
rectangle 0,0
2016-07-27T14:55:37+02:00 0:00.047 0.047u 7.0.2 Draw CONVERT[6660]: draw.c/DrawImage/3258/Draw
end draw-image
CONVERT: NonconformingDrawingPrimitiveDefinition `rectangle' @ error/draw.c/DrawImage/3271.
I do not want to use a temporary file and I want to use this eventually after a trim repage. I would also like to replace the '42' with a formula if it is possible to use attributes in this command.
I guess the question is if this is supported( and if not then why the H not)?
[1] Version: ImageMagick 7.0.2-5 Q16 x64 2016-07-22 http://www.imagemagick.org