ImageMagick: Can I remove the "Crop marks"?

I use ImageMagick to create thumb PDF.

/opt/local/bin/convert \
   "$inputFile[0]"     \
  -geometry 157x200    \
  -colorspace RGB      \
   "$ThumbFile"

But finally, we got a PDF with “crop marks” (for bleeding).

Is there an option that I can use to not accept them?

How can i do this?

Example:

enter image description here

I would like to have only the contents of the second image.

+5
source share
2 answers

I ended up pointing out the magic of the image to capture only the cropping field:

/opt/local/bin/convert \
  -geometry 157x200    \
  -colorspace RGB      \
  -define pdf:use-trimbox=true \
   "$inputFile[0]"     \   
   "$ThumbFile"
+7
source

The easiest to use option -shave Nwill remove a depth of N pixels from each edge of the image.

For instance:

convert         \
   original.gif \
  -shave 30     \
   result.gif

This will allow you to shave out 30 extreme rows / columns of pixels from each edge of the original image.

PDF (, PNG):

convert        \
   some.pdf[0] \
  -scale 25%   \
  -shave 30    \
   result.png
+1

All Articles