Questions tagged [imagemagick]

ImageMagick is an open source image editing software suite for displaying, converting, and editing raster image files. It supports read/write for more than 100 image file formats.

Filter by
Sorted by
Tagged with
0 votes
1 answer
20 views

Asterisk pbx agi php script with imagick imaging on the fly not working

Problem description: Generate an image with an ASTERISK AGI PHP script that is displayed on a phone (Yealnk) using imagick. installed:php-imagick/oldstable,now 3.4.4+php8.0+3.4. The AGI PHP script ...
Edderpet's user avatar
0 votes
2 answers
26 views

Imagemagick: Split image vertically from bottom, resizing the last part

I want to split a image with dimension 128x? into multiple 128x128 parts, with the last part being resized to height 128. I want the first output image to be from the bottom of the input image. I used ...
reign's user avatar
  • 13
0 votes
0 answers
31 views

Imagemagick, how to remove a stamp and marks from an image?

The scanned document image (grayscale) have two handwritten marks on the top and seal stamp at the bottom. I want to remove these marks and seal by replace them (hide) with same size rectangles, ...
minto's user avatar
  • 511
0 votes
0 answers
17 views

How to set -level values via Imagemagick GUI prompt?

How to set required -level values via ImageMagick GUI dialog prompt? For example, I want set values -level 10%,90% from Imagemagick GUI prompt. It's not clear, what values in GUI dialog correspond to ...
minto's user avatar
  • 511
1 vote
1 answer
26 views

Finding the correct -level operator values for the Imagemagick script

I need process scanned book images and remove the gray background. I want to find a correct -level operator values for the Imagemagick script. To do this, I need to make a series of tests and compare ...
minto's user avatar
  • 511
0 votes
0 answers
54 views

How to split image vertically with fixed height and overlap, with imagemagic?

I use convert -crop 1x4+0+30@ +repage in.png out.png to split a long image vertically to parts with 30px overlap. I want to make output parts with a fixed height, like 768px, but convert -crop 100%...
Galaxy's user avatar
  • 237
0 votes
0 answers
24 views

All PDFs default as a picture of ImageMagick

Cinnamon Mint. All PDFs suddenly now open in default to a ghastly image of an 'ImageMagick' clown. i tried every one of your recommendations : Setting 'Document Viewer' as 'default' don't work, ...
nimpz's user avatar
  • 1
3 votes
3 answers
447 views

Batch split images vertically in half, sequentially numbering the output files

I have a folder with scans of a book numbered 001.jpg through 092.jpg The scans have two pages of the book scanned together. What I want is split these by two from the middle vertically and regenerate ...
Plato's user avatar
  • 77
0 votes
0 answers
46 views

Imagemagick not found by other apps, but needs to be updated in any case. How best to remove and install v7-

I am running Mint 21.1 64 bit. I believe that Imagemagick v6.. was installed via the 'synaptic package manager'. I now require Imagemagick v7, to dovetail with another app that will not work with v6 ...
Birdman's user avatar
0 votes
1 answer
501 views

how to find all pics in a directory and its subdirectories and run a command on them

how to find all images in a directory and its sub-directories, with types gif, jpg, jpeg, png, ico, and run mogrify -strip your_filename.jpg on them? Can the command mogrify -strip corrupt an image? ...
stacking and exchanging woohoo's user avatar
2 votes
2 answers
205 views

Copy directory tree and then recursively convert all JPG files in-place

I would like to run the command convert -strip -interlace Plane -gaussian-blur 0.05 -quality 75% 002-02.jpg test .jpg on all .jpg files in the following subdirectory ├── House Altar Data │   ├── ...
Reuben's user avatar
  • 21
-1 votes
1 answer
177 views

png images to single pdf

I have Version: ImageMagick 6.9.10-23 Q16 x86_64 20190101 on Ubuntu 20.04. I tried convert *.png out.pdf to convert 70 png files into a pdf, but strangely always only 18 pages in the pdf file. I didn'...
wsdzbm's user avatar
  • 2,786
0 votes
2 answers
246 views

How to use jpegoptim to have files only 20kb in size?

I have tried using jpegoptim and even tried the manpage but am stumped. Here is a file I want to reduce to 50k and even open to reducing quality of the data - Image: Filename: shirish.jpg Format: ...
shirish's user avatar
  • 12k
1 vote
1 answer
358 views

Convert JPG to A4 PDF without white space on top with Imagemagick

I am trying to convert JPGs documents of varying sizes to A4 paper. (photos of documents taken from the NextCloud Android App "scan document" function). But the problem is also reproduceable ...
Alex's user avatar
  • 436
3 votes
2 answers
722 views

Convert each line of a text file into a separate image using imagemagick convert

I would like to take a text file with about 1,000 lines and create a separate png image for each line in the file using possibly ImageMagick convert. The image should be 1920x1080 with a black ...
Designs Edge's user avatar
1 vote
1 answer
1k views

How to remove a specific color from a whole pdf document?

Is their a way, with imagemagick, pdftk or other stuff, to remove a specific color from a whole pdf document? I mean, I give an html hex color code to a tool, and it remove all occurences of this ...
fauve's user avatar
  • 1,140
0 votes
2 answers
179 views

Scale images to fixed target pixel size

I want to reduce the size of my JPG images to the same total pixel size (e.g. 6MPx) no matter of the input size or ratio. Of course mogrify or convert can resize: This ... mogrify -resize 3000x3000 ...
pLumo's user avatar
  • 22.3k
1 vote
2 answers
605 views

Resizing Images in Linux

I have various folders with high res images sizes some more than 6000px x 4000px. some are 5000px x 3000px, size varies with folder to folder. I want to resize all images for saving resources like ...
user1757774's user avatar
1 vote
0 answers
326 views

How to concatenate multiple images in 2d directions using Imagemagick?

I have a bunch of images of the same size. I want to stack them onto and beside each other in 2d space. (tl: top-left) tl | tr bl | br I'm currently first stacking horizontally, then stacking ...
Zeta.Investigator's user avatar
0 votes
1 answer
636 views

ImageMagick not converting grayscale to RGB

Trying to use ImageMagick to resize, convert images from grayscale to RGB, and from jpg to png. Using the flags to convert to RGB as per: https://stackoverflow.com/a/34875248 convert test.jpg -...
cat pants's user avatar
  • 753
2 votes
1 answer
1k views

How to convert output of a terminal app to an image?

Suppose the CLI application my_bin produces an output in terminal which consists of colored text, Unicode symbols and emojis. How can I convert the output to a svg or an image on Ubuntu? For example, ...
Zeta.Investigator's user avatar
1 vote
1 answer
80 views

How can I limit an operation in imagemagick to just the lower half of the picture?

Starting with the command below, I would like to apply -fill red on the top half of the picture and -fill green on the bottom half. (I know I could break up the picture, and reassemble it after the ...
pkrauss6171's user avatar
0 votes
0 answers
70 views

Enumeration Stamping pdf pages with Imagemagick

A .pdf file has 100 pages of images. The goal is to enumerate pages 81-90 in the upper left hand corner. I have been able to enumerate .jpg (Raster) images with imagemagick top=/Users/user/Desktop/...
gatorback's user avatar
  • 1,214
4 votes
3 answers
2k views

Point out my mistake while converting TIFF to PNG/JPG

This is a input tiff image, which I want to convert to JPG/PNG. googledrive-link-to-download-sample As general rule of thumb, I always use following command to convert between 2 image formats (mainly ...
Garid Z.'s user avatar
  • 500
0 votes
1 answer
44 views

Combine Multiple pdfs with a new page with text between each

I've read through and tried multiple posts on similar topics and none satisfied my purpose. I have multiple pdfs which are project reports for each week of a 16-week project and are titled Week1.pdf, ...
Ananth_Rao's user avatar
0 votes
2 answers
223 views

check width of image before convert it

I use the following script to convert all jpg and png images: # absolute path to image folder FOLDER="/home/*/public_html/" # max width WIDTH=1280 # max height HEIGHT=720 #resize png or ...
Mikel Tawfik's user avatar
0 votes
0 answers
338 views

The process was killed by the system. Why?

I was trying to convert large pdf file to jpg images by command line, using ImageMagick 6.9.7-4 tool (Ubuntu 18.04). convert -density 300 file.pdf page_%.jpg It gave no output, just message that the ...
Untitled's user avatar
2 votes
1 answer
1k views

Set PDF tags while converting images to PDF with ImageMagick

I'm converting images to a single PDF-file using convert utility: $ convert "document-*.tiff" -compress jpeg -quality 60 "output.pdf" Resulting document has the following tags set ...
anlar's user avatar
  • 4,096
0 votes
1 answer
99 views

How can I use one input file into several separate operations

I would like to read one file, do an operation with several different parameters on it and finally save each output as a separate file. Currently I do it as shown in the code snipped below. This reads ...
Jona Engel's user avatar
0 votes
1 answer
1k views

how to use ImageMagick's crop to remove "watermark"

How can I use ImageMagick's command line utils to crop several iamges so that I remove the watermark on the bottom of them? Context I have a personal website for my family where I post our photos. A ...
user avatar
1 vote
1 answer
1k views

How to scale down PDF file (in pixels and in cm)?

I need to automatically convert my pupils' solutions which are photos and scans of various orientations, resolution, quality and file format into a single PDF with fitting dimensions. The dimensions ...
Photon's user avatar
  • 119
1 vote
1 answer
665 views

efficient way to compose all frames in a video to a single image

I've got a 720p video file that is about 20 minutes long. I want to compose each frame in the video using a single operator (e.g. lighten, darken, etc.) to produce a single image output. My thought ...
Michael's user avatar
  • 534
1 vote
1 answer
537 views

Pipe from xwd to ImageMagick's convert produces cropped image

I'm trying to take a screenshot of a remote host (using xwd) and convert it to png (using convert). I need it to be an unattended oneliner, so this is what I'm doing: sshpass -p THE_PASSWORD ssh user@...
José Tomás Tocino's user avatar
1 vote
1 answer
419 views

ImageMagick -gravity: portrait-photo frame-of-reference rotated +90

Context iPhone photos of both: portrait & landscape to be time-stamped with EXIF data, via ImageMagick 7.0.10-62 Q16 x86_64 2021-02-07 + Catalina MacOs. ImageMagick installed via:brew install ...
gatorback's user avatar
  • 1,214
0 votes
1 answer
716 views

How to loop sequentially through images in one folder and compare with the latest image in another folder

I am trying to use the shell to loop sequentially through images in one folder and compare with the latest image in another folder. One error i'm getting is - zsh: no matches found: /TiffOut/*.tiff(....
shfury's user avatar
  • 101
3 votes
2 answers
1k views

How can you compress images in a PDF?

How can you increase the JPEG compression level on a PDF using batch tools under Linux? Obviously you can use gs -dPDFSETTINGS=/screen or /ebook, but that downsamples the PDF - it reduces the DPI. It'...
Zaz's user avatar
  • 2,499
0 votes
0 answers
191 views

Linking to wrong .so file on Fedora 33 (libx265) when compiling ImageMagic

On Fedora 33, I'm trying to compile ImageMagic from git. libx265 and libheif are installed from the Fedora fusion repos, along with their -devel packages. When running ./configure --prefix=$HOME --...
polemon's user avatar
  • 11.2k
0 votes
1 answer
408 views

bulk resize height*width problem

I'm trying to resize all images in a directory using this bash script : for i in *.jpg; do printf "Resize $i\n" convert "$i" -resize 336x336 "$i" done But when ...
Maifee Ul Asad's user avatar
0 votes
0 answers
88 views

Treatment of a scanned logo with ImageMagick

I have an image produced by a scan of a logo, that is supposed to have only one tonality. The pixels close to the edge of the logo have various levels of density. The use will require it to go over ...
TeX Apprentice's user avatar
1 vote
1 answer
1k views

ImageMagick generated PDF renders as blank pages in Chrome

I have drawn a png file using Krita: I then converted this file to a pdf file using convert: convert test.png test.pdf When I open this file in my PDF viewer (Evince), I see the image above, just as ...
Scriptim's user avatar
  • 205
0 votes
1 answer
359 views

Output files of mogrify on raw image file conversion to jpg are overly dark

I'm performing a simple transformation of a batch of files taken in RAW mode with an Olympus OM-D EM1 camera (extension is "ORF") to jpeg using ImageMagick. When I run the command, mogrify -...
Jeremy Kidwell's user avatar
0 votes
1 answer
264 views

ImageMagick - transparent background showing as black pixel in 'histogram:info:' output

My script is this… convert test.png -alpha off -format %c histogram:info: Unfortunately, the output treats any transparent background in the PNG as a black pixel, meaning that the count of black ...
Mercuriel's user avatar
1 vote
0 answers
228 views

scanimage returns a broken image

i want to use a raspberry pi (Debian) as scan-Server. For this job I installed SANE and ImageMagick. If I scan with ... Bash: scanimage -p --resolution=25 --mode=Color -l 0 -t 0 -x 210mm -y 297mm >...
Baum's user avatar
  • 11
2 votes
1 answer
1k views

Superimpose multiple images

I have multiple pictures that are look alike, they're all black and differ only in the one dot of the screen, I want to combine them in one picture so I can see all the dots in one picture. How can I ...
Arzybek's user avatar
  • 125
0 votes
1 answer
641 views

Rotate image if width is greater than height

I have a few thousand rectangular images of various sizes. I want them all to have a longer height than a width. I want to do this by rotating all images whose height is shorter than their width 90 ...
Boris Verkhovskiy's user avatar
2 votes
1 answer
2k views

ImageMagick compare without generating diff image

I'm using ImageMagick compare to calculate the difference between two images every five minutes on a Raspberry Pi. This takes almost a minute, and I suspect much of the CPU load is due to the ...
OZ1SEJ's user avatar
  • 175
2 votes
1 answer
2k views

ImageMagick - how to preserve exact palette in .PNG

I'm trying to use convert(1) from ImageMagick to convert from .tga to .png (and back again later), while preserving exact palette that was used. Source image is TARGA color indexed file, having a ...
Matija Nalis's user avatar
  • 3,071
2 votes
1 answer
877 views

ImageMagick refused to convert the animated GIF and killed the process silently due to CPU

I tried with these solutions below, but unsuccessfully: ImageMagick convert problem, command killed or silently exits Using disk for processing of huge images ImageMagick convert out of memory ...
Oo'-'s user avatar
  • 233
2 votes
1 answer
1k views

imagemagic: Convert -gravity center not working

I have a bunch of images and trying to convert them to pdf using the below command: $ convert *.jpg -resize 1240x1753 \ -extent 1240x1753 -gravity center -background white \ ...
Santhosh's user avatar
  • 359
1 vote
1 answer
361 views

How can I use mogrify to target a specific pixel value of the largest dimension so if vertical set height to 'x' or if horizontal, set width to 'x'

So I've successfully used $ mogrify -resize 3000 to accomplish setting dimension on batches of images. What this yields me is exactly that- a group of images that have a 3000px width. The issue lies ...
visyoual's user avatar

1
2 3 4 5 6