Skip to main content

Questions tagged [image-manipulation]

Use this tag for questions related to the changing/combining of files containing pictures or other images. (Dumps of filesystems are often called images, but handling those is not called image-manipulation)

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

difference between convert -quality and convert -resize and convert -density

I'm trying to reduce file size of a .png in the terminal with Imagemagick convert Does anyone know the difference between convert -quality , convert -resize and convert -density ? convert -quality ...
cardamom's user avatar
  • 602
0 votes
2 answers
39 views

imagemagick convert: limit trim to max X px

Using ImageMagick (6.9.11-60 on debian stable), I'd like to shave off 24px left and right of an scanned page (jpg or TIFF), but only if that area would actually be "empty" (i.e. mostly white)...
Jan's user avatar
  • 7,782
0 votes
1 answer
50 views

Print two half-sized copies of a two-sided document at once

I have a two-sided, us-letter format document that I'd like to print two copies at once, by resizing it to half letter (a.k.a. statement, or organizer L). My current workflow is very inconvenient: ...
Clément's user avatar
  • 378
0 votes
0 answers
129 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
  • 535
2 votes
0 answers
32 views

Flip an xcursor in the console

I'm left-handed and I want to be able to correctly flip any arbitrary xcursor theme so that I can use it as a left-handed version. I’m surprised this isn’t build in. So a way to flip an xcursor file, ...
user avatar
1 vote
0 answers
185 views

Splitting a 2up PDF MuTool ‘poster’ style

There are many command line tools to convert a 2-up PDF, where two actual pages from a book are combined to form 1 page in a PDF, into a single page format, where 1 PDF page is 1 actual page. The ...
mbr50's user avatar
  • 11
0 votes
1 answer
408 views

Best command-line OCR software for recognizing typed text over colorful background

I need to extract text from images like the one below: As you can see, the text is typed not handwritten. Moreover, the background is colorful. I've tried Tesseract OCR, and while it works some of ...
user avatar
3 votes
1 answer
1k views

How does `pdfimages` differ from `pdftoppm`?

For the purpose of processing pdf with Scan Tailor (in order to remove the background of photographed pdf pages, or to split pdf pages) given that this program needs input of images - it cannot input ...
cipricus's user avatar
  • 1,629
1 vote
0 answers
34 views

Can I transform colors of scanned pdf files and reduce the scan resolution to save memory keeping an existing text layer from OCR?

I have a pile of pdf files which have been scanned long ago and which are already searchable (i.e. they went through OCR). However the light level and contrast settings were not optimal. Is it ...
Adalbert Hanßen's user avatar
3 votes
2 answers
956 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
0 answers
497 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
1 vote
2 answers
1k views

Edit PDF On The Command Line

Is there a way to blacken parts of a pdf file (i.e. personal data that I don't want to send with the pdf)? Maybe from the command line where I can say make everything black on page 2 from pixel X455 ...
theerrormagnet's user avatar
3 votes
1 answer
2k 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
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
  • 552
0 votes
0 answers
21 views

Document scanner on PC like with mobile apps

I'm impressed with the abilities of document scanner apps for mobile devices. I've tried a few and they do a very similar thing very well: Take a camera picture/photo of a paper document, detect it's ...
Robert Cutajar's user avatar
3 votes
1 answer
69 views

pic(1): graphic cut off at right border

I created a graphic in the pic language as follows (v-modell.pic): .PS AF: box wid 1.6 ht 0.25 "Anforderungen" SA: box same "Systemarchitektur" at AF.se + (0.1, -0.5) KA: box same &...
Patrick Bucher's user avatar
0 votes
1 answer
115 views

Image get distorted after being sent via broswer

Hello I am using parrot OS, and My problem is whenever i capture the screenshot at my linux machine and try to send it via browser or web.whatsapp. The image get's distorted. Please Have a look at ...
Sameer Katija's user avatar
0 votes
0 answers
687 views

Editing images with feh

According to the feh man page: --edit     Enable basic editing of files. This makes rotation and mirroring (bound to "<", ">", "|", and "_" by default) ...
Yehuda's user avatar
  • 301
1 vote
1 answer
124 views

How do I resize image jpg/png files in AIX based systems through linux commands (Not UNIX)

How do I resize image jpg/png files in AIX based systems through linux commands (Not UNIX). I have already seen ImageMagick tool in many forums but it's only for unix based systems like ubuntu but it ...
Pramod's user avatar
  • 19
1 vote
1 answer
542 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,394
14 votes
4 answers
13k views

How to blur webcam background in Microsoft Teams

I am currently using Teams for a master and I would like to blur my backgrounds, do you know any way to do it?
Alessio_110's user avatar
0 votes
1 answer
418 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
3 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
  • 135
0 votes
1 answer
777 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 ...
user avatar
1 vote
1 answer
471 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
  • 167
0 votes
4 answers
2k views

Batch conversion of ".tif" images to ".jpg"

I am using Manjaro GNU/Linux. I have a directory named files; under this directory, I have around 650 subdirectories with names such as file1, file2, file3, etc. Under each subdirectory, there are ...
Arun's user avatar
  • 127
2 votes
1 answer
67 views

How to take annotated screenshots with keyboard only?

Workflow: Take a screenshot. Select a region on the screenshot (an overlay displays keys). Input a text. Repeat step #2 or save/imgur upload. All steps should be handled by keyboard only. Does ...
jjk's user avatar
  • 411
1 vote
3 answers
1k views

How can I modify the contents of an image with a bash script?

Say I want to overwrite the top half of a file "image.png" with white pixels. Can I do that with a bash script?
Vishnu Prasad's user avatar
6 votes
1 answer
4k views

Cwebp -resize only if image is larger

cwebp - Compress an image file to a WebP file -resize width height Resize the source to a rectangle with size width x height. If either (but not both) of the width or height parameters is 0, the ...
Garvit Jain's user avatar
0 votes
2 answers
157 views

A bash script to square a tall image of a long text column?

Ever seen a print of a long discussion thread? Looks like the picture of a skyscraper… with only the building in it! So what I generally do — manually! — is break up the image into segments, and then ...
André Levy's user avatar
1 vote
3 answers
123 views

After installing ImageMagick I don't have the tool imgout

uname -a Linux localhost.localdomain 4.13.16-100.fc25.x86_64 #1 SMP Mon Nov 27 19:52:46 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux I tried to install ImageMagick using the command: yum install ...
69 420 1970's user avatar
2 votes
0 answers
721 views

Create small high-quality GIF/APNG from a bunch of PNGs

I have 50 PNGs (like those ones here) and I would like to create a GIF (or APNG) animation from it that approximately retains the quality and is small. What I'm doing so far is to rescale and throw ...
Nico Schlömer's user avatar
1 vote
1 answer
163 views

How can I quickly preview an image with a circular frame?

Some images are displayed in a circular frame after uploading. For example, GitLab project icons: When tweaking an image on the desktop, I don't really know how it will look in a circular frame ...
lofidevops's user avatar
  • 3,189
4 votes
3 answers
5k views

Automatically restoring verticality of the edges of a scanned photo

I want to scan a collection of rectangular photos, both color and black-and-white. I am generally quite happy with the scanning, but I run into some practical problems, due to the fact that photos are ...
babou's user avatar
  • 858
0 votes
1 answer
1k views

How to use ubifs image with modprobe? To extract ubifs image

I try to do something like this - link. All examples in the web are not working at all. modprobe ubi mtd=0 modprobe: module ubi not found in modules.dep modprobe ubi modprobe: module ubi not found ...
Bulat's user avatar
  • 103
3 votes
1 answer
465 views

How to merge 2 images under linux console (via sh script)

I have jpeg image on the server from IP camera. This is every 1-second snapshot. Because of privacy, I need to cover the closest balcony. I was prepared a cover png image. Is it possible to make a ...
Oldřich Švéda's user avatar
1 vote
2 answers
509 views

Lossless crop JPEG to whole 8x8 blocks

Since JPEG images are compressed in chunks of 8x8 pixels, if a JPEG has a width or height that is not divisible by 8, is it technically possible to remove the 1-7 pixels of the outer edge losslessly? ...
forthrin's user avatar
  • 2,339
0 votes
1 answer
568 views

get coords of all instances of a subimage

This command: compare -metric mse -subimage-search image.jpg subimage.jpg null: gives me value for given metric and coordinates of an occurence of a subimage. What if I want coordinates for all the ...
Bartłomiej Wach's user avatar
1 vote
0 answers
1k views

Clear image background and remove vertical line

I want to clear vertical line and other black spot which is near to number. Here is my Input image:- I tried below command but it's remove vertical line but also cut number and still black spot ...
Dhaval Bhavsar's user avatar
0 votes
0 answers
78 views

Gimp Plugin to batch-export several different color shades

I hope someone can give me some info on whether or not a plugin exists for Gimp which will automatically do the following... I've created an icon which I want to save as several different color ...
Ev-'s user avatar
  • 639
19 votes
9 answers
10k views

How can I split each PDF page into two pages, using the command line?

I have a few ebooks scanned from originals. They're formatted so that a single PDF page contains two actual pages: one on the left, and one on the right. I want to programmatically split each PDF ...
Philip Kirkbride's user avatar
0 votes
1 answer
313 views

Triangular 2d mesh linear image deformation

I'm in need of an application that would let me define a set of vertices (handles) on top of an image layer, derive a DeLaunay triangulated mesh from those handles, and allow me to reposition the ...
loop's user avatar
  • 159
1 vote
1 answer
555 views

CLI Tool to manipulate / compress images in pdf

In a large pdf with high image quality (20 pages, around 400 MB): For Linux, is there a CLI tool that reduces the file size by reducing the quality of all (or single) images within the pdf allows me ...
Philipp's user avatar
  • 559
2 votes
1 answer
5k views

Imagemagick 'convert' text to image: ReadTEXTImage: Assertion

I'm trying the following command to convert text to an image: $ echo test | convert text:- text_box_trimmed.png convert: ../../coders/txt.c:198: ReadTEXTImage: Assertion `exception->signature == ...
ealfonso's user avatar
  • 953
3 votes
1 answer
18k views

How to convert an image to a 24-bit BMP in commandline?

I'm writing a wrapper Bash script for ARSS to make it easier to use. The program converts images to sounds and vice-versa but it only accepts 24-bit BMP images, which I was only able to produce using ...
unfa's user avatar
  • 1,745
0 votes
1 answer
2k views

Bulk Resize images in sub directories with Imagemagick

I'm trying to resize all images in a directory and sub directories. I have this script which I got from here: Use mogrify to resize large files while ignoring small ones and adjusted to: identify -...
mmc501's user avatar
  • 103
0 votes
0 answers
148 views

How to split an image with offset using ImageMagic? [duplicate]

I planning to print a large map(6400x15360) and I want to split that image to multiple images(1123x794). I found that -crop 1123x794 do that but How I can add offset so it will be easier for me to ...
sh1omi's user avatar
  • 9
3 votes
1 answer
2k views

Crop and resize image to fit a5 pdf

I have an image (png, size 4288x2848) that I want to fit in a landscape a5 pdf with a 1cm border. I know I can do it with ImageMagick but don't know how.
Juanjo Conti's user avatar
  • 2,733
1 vote
1 answer
106 views

What is the highest Format Version of PDF that free software can produce?

I am on Debian Stretch. I made couple of pdf files from img2pdf using $ img2pdf --output sample2.pdf sample.jpg I then tried uploading to a web-service and it rejected the pdf file. Looking at the ...
shirish's user avatar
  • 12.5k
6 votes
2 answers
243 views

How to find y-axis joint similarity in two pictures?

I want to merge two pictures but I do not know how to find the cut location in y-axis by any Linux/Unix tools, but here ImageMagick as the first idea. Any approach is welcome: a programmatic solution ...
Léo Léopold Hertz 준영's user avatar