imagemagick-convert

Image conversion from IFF and EXR formats to JPEG format

别来无恙 提交于 2019-12-11 02:39:20
问题 I am using convert Desktop/iff_image.iff Desktop/iff_image.jpg to convert my images to JPEG format. But getting as convert: no decode delegate for this image format `Desktop/iff_image.iff' @ error/constitute.c/ReadImage/552. convert: no images defined `Desktop/iff_image.jpg' @ error/convert.c/ConvertImageCommand/3127. For .tif, .tiff, .cin, .dpx extensions it is working properly. The issue is coming only for .iff and .exr extensions. 回答1: IFF I am not familiar with a format named 'IFF'. Sorry

Prevent ImageMagick converting to grayscale

你说的曾经没有我的故事 提交于 2019-12-11 02:36:20
问题 I'm using ImageMagick-6.9.1 on Windows to resize a PNG file before processing it with another tool. The source file is RGBA, but the image data is grayscale (all pixels have the same value for R, G, and B). It appears that ImageMagick is detecting this, and converting the output to grayscale, even if I specify format and colorspace like so: convert.exe src.png -format PNG32 -colorspace sRGB -background transparent -resize 830x540 out.png I've verified the resulting output format is 8-bit

ImageMagick, replace semi-transparent white with opaque white

大憨熊 提交于 2019-12-11 02:34:47
问题 I have an icon with a fully transparent background and a semi-transparent, white foreground. I would like to make the foreground fully opaque, can this be achieved with ImageMagick? I have tried juggling different combinations of these; http://www.imagemagick.org/discourse-server/viewtopic.php?t=12619 http://www.imagemagick.org/discourse-server/viewtopic.php?t=18196 http://www.imagemagick.org/discourse-server/viewtopic.php?t=16718 , but cannot produce the desired result. Any tips? 回答1: It

ImageTragick “fix” broke my script and not sure how to fix

孤街醉人 提交于 2019-12-11 01:14:28
问题 Using Imagick, I'm placing custom jpgs into an svg and then converting them to a jpg. Because of the ImageTragick, my placed jpegs never show up and my font doesn't convert. Because of the vulnerability my host upgraded their policy.xml and now it's broken. <policymap> <!-- <policy domain="system" name="precision" value="6"/> --> <!-- <policy domain="resource" name="temporary-path" value="/tmp"/> --> <policy domain="resource" name="memory" value="32MiB"/> <policy domain="resource" name="map"

Convert a bunch of images from svg to png

我只是一个虾纸丫 提交于 2019-12-11 00:26:38
问题 I need to convert from svg to png all the images in a folder. Lets say that images are called test1.svg, test2.svg, ... , testn.svg. Using the following script: for i in *.svg do convert "$i" PNG24:"$i".png done does the job correctly, and the images are called test1.svg.png, test2.svg.png, ... , testn.svg.png. My questions are: 1) Is it possible to make the output images be called test1.png, test2.png, ... , testn.png, essentially removing the 'svg' part from the name? 2) Is it possible to

Export .svg to .png without (any) antialiasing (`+antialias` doesn't work)

六月ゝ 毕业季﹏ 提交于 2019-12-10 22:16:32
问题 I'm trying to export a svg file to an icon sized .png. The problem is that I can't seem to be able to force ImageMagick to not to use antialiasing. It seems to me that +antialias only turns off between colors aliasing but doesn't prevent to-alpha-channel aliasing. I've tried: convert +antialias -background none plug.svg -resize 32x32 plug.png convert +antialias -background none -size 32x32 plug.svg -resize 32x32 plug.png Putting the +antialias keyword anywhere in the clause... And all of them

How to get a Hex Color Code from a solid-color image for a script?

不羁岁月 提交于 2019-12-10 12:22:07
问题 I was writing a script to change my background on my Linux Machine to a random image from a set of images that contain only solid colors. What I would like to do is expand this script to also theme certain applications (mostly terminal ones) accordingly, at the very least to change the text color, possibly switch from dark to light background, etc. I was wondering what options I have to get the Hex Code for the color in the image. Is there something in bash I can do this with? Would I need to

ImagMagick: How to add a gradient splice to an image using one convert command?

浪尽此生 提交于 2019-12-10 11:39:58
问题 Is it possible to add a gradient splice to the bottom of an image? It seems that gradient option requires -size, which I cannot provide because size of the image may varry. It's possible with convert and compose but I want to use only one command. Something like this (note that this is invalid currently): convert -fill gradient:black-white -gravity south splice 0x20 image1.jpg image2.jpg 回答1: My suggestion to you is to use -append instead of -splice . The image size may vary, but you can

ImageMagick sampling factor

泪湿孤枕 提交于 2019-12-10 03:54:09
问题 I have been using ImageMagick command line tool for jpeg compression of the images. However, I'm trying to understand the role of sampling factor. It says the sampling factor is used to specify the block size i.e. 8x8 or 16x16. However, I can't find the default values used if I omit this parameter. Also, I tried fetching properties of an image by using the following command: identify -verbose image.jpg It shows sampling factor values as 1x1, 1x1, 1x1. What does it mean? Either it should be

Batch command for ImageMagick to convert all files in a directory and sub-directories on windows

人走茶凉 提交于 2019-12-09 10:49:55
问题 I have thousands of SVG's in a folder and sub-folders. What I want is to batch convert all of them to jpg or png images. Can someone help me write a command for ImageMagick (windows), which can find and convert all the svg's to jpg/png with their original names and keep them in the same directories? Here is the example structure: C:\SVG\BusinessMan.svg C:\SVG\Models\Home.svg C:\SVG\Underlines\underline.svg And I want it like this after conversion: C:\SVG\BusinessMan.svg C:\SVG\BusinessMan.jpg