Search found 10486 matches

by snibgo
2018-08-14T09:51:55-07:00
Forum: Users
Topic: How to disable policy on case by case basis?
Replies: 4
Views: 58

Re: How to disable policy on case by case basis?

Yes. Or create another installation of IM, with its own policy.xml.
by snibgo
2018-08-14T08:27:28-07:00
Forum: Bugs
Topic: Problems with -density if -unit PixelsPerInch not specificied before input image
Replies: 10
Views: 2833

Re: Problems with -density if -unit PixelsPerInch not specificied before input image

You've quoted the resolution but not the units. I note that 350 dpi = 889 dpcm.
by snibgo
2018-08-14T08:20:59-07:00
Forum: Users
Topic: How to disable policy on case by case basis?
Replies: 4
Views: 58

Re: How to disable policy on case by case basis?

policy.xml sets limits that can't be relaxed. Other mechanisms such as MAGICK_MEMORY_LIMIT apply extra limits, in addition to limits imposed by policy.xml.
by snibgo
2018-08-14T08:17:19-07:00
Forum: Users
Topic: Resize Image with restrictions
Replies: 2
Views: 43

Re: Resize Image with restrictions

So, you can make all your images 5000 by 5000 pixels and your customer will be happy? Maybe not.

I would do this in three steps:

1. Find the current size.

2. Do some processing to calculate the new size.

3. Resize, or crop, or whatever is wanted, to the new size.
by snibgo
2018-08-14T08:12:38-07:00
Forum: Users
Topic: How to pass a var into the "new" magick script engine ?
Replies: 2
Views: 39

Re: How to pass a var into the "new" magick script engine ?

For the changes within IM, including command line and internal IM scripting, see https://www.imagemagick.org/script/porting.php IM has no control over scripting facilities provided by your shell, eg bash or Windows CMD or Windows BAT. They will continue to work as before, and shells will translate e...
by snibgo
2018-08-13T10:42:49-07:00
Forum: MagickWand
Topic: convert multiple images to single pdf with library MagicWand
Replies: 1
Views: 45

Re: convert multiple images to single pdf with library MagicWand

Here's a wand program, but with no error-checking, that writes two images to a PDF: #include <MagickWand/MagickWand.h> int main(void) { MagickWandGenesis(); MagickWand *mw = NewMagickWand(); MagickReadImage(mw,"rose:"); MagickWand *aw = NewMagickWand(); MagickReadImage(aw,"toes.png"); MagickAddImage...
by snibgo
2018-08-13T04:44:29-07:00
Forum: IMagick
Topic: Set blending mode as "screen" and opacity to 50%
Replies: 4
Views: 60

Re: Set blending mode as "screen" and opacity to 50%

mjamal wrote:I need to know how to Set blending mode as "screen" for a single image...
I don't know what that means. If you set a blending mode for a single image, what do you expect to happen? Do you expect that this will change the image somehow?
by snibgo
2018-08-13T04:01:22-07:00
Forum: IMagick
Topic: Set blending mode as "screen" and opacity to 50%
Replies: 4
Views: 60

Re: Set blending mode as "screen" and opacity to 50%

At the command line, use "-compose Screen". In IMagick, the mode is a parameter of the compositeImage() function. See http://phpimagick.com/Imagick/compositeImage

To set opacity to anything, use "-evaluate set" at the command line, and evaluateImage() in IMagick.
by snibgo
2018-08-12T15:42:13-07:00
Forum: Users
Topic: I can't make this script to run in
Replies: 9
Views: 181

Re: I can't make this script to run in

1. Can I create a PDF file from the all pages I've just created in the code above using magick image code? If they all fit into memory at the same time: magick *.jpg out.pdf 2. Can I apply this type of code (the code from the 1st post) to a multiple page PDF file? I'm sick of spliting the PDF in mu...
by snibgo
2018-08-12T14:16:00-07:00
Forum: Users
Topic: I can't make this script to run in
Replies: 9
Views: 181

Re: I can't make this script to run in

As Fred says. I suggest you write your command using "magick" without "mogrify". When you have tested it, put it inside a "for" loop, eg "for %F in (*.jpg) do ....

Type "help for" for help.
by snibgo
2018-08-12T13:25:55-07:00
Forum: Users
Topic: Edit images of sub-folders in one attempt
Replies: 1
Views: 32

Re: Edit images of sub-folders in one attempt

You can use "for" to loop through directories, eg "for /R %D in (.) do ..."

Type "help for" for help.
by snibgo
2018-08-12T11:39:11-07:00
Forum: Magick.NET
Topic: How to make part of picture same during comparison
Replies: 2
Views: 87

Re: How to make part of picture same during comparison

diffImage tells you the difference is mostly vertical. Looking closely at the two inputs, we see there is a small (less than one pixel) displacement between the images. A small vertical blur eg -morphology Convolve Blur:0x1,90" smooths over that difference. diffImage tells you where differences are,...
by snibgo
2018-08-12T10:31:38-07:00
Forum: Users
Topic: I can't make this script to run in
Replies: 9
Views: 181

Re: I can't make this script to run in

In bash, parentheses () are special character so have to be escaped, and the bash escape character is backslash, so \( and \). Windows uses a different escape character, the caret ^ , and parentheses don't normally need to be escaped. In Windows BAT, percent % is a special character, and need to be ...
by snibgo
2018-08-12T07:42:03-07:00
Forum: Users
Topic: extracting biggest square from a rotated image
Replies: 3
Views: 64

Re: extracting biggest square from a rotated image

manit wrote:...but am not sure what should be the size of biggest black square...
My high-school geometry says that:

W' = W / (sin(A) + cos(A))

where W is the width and height of the unrotated square, W' is the width and height of the new square contained inside, and A is the angle of rotation.
by snibgo
2018-08-12T07:07:58-07:00
Forum: IMagick
Topic: Composite image onto image with transparency, ADD and BLEND not right
Replies: 5
Views: 80

Re: Composite image onto image with transparency causes rainbow colour distortion

Gimp's "Mode Normal" corresponds to IM's "-compose Over" so if you like the Gimp result, I suggest you use "-compose Over", in the same order as Gimp, with the river scene first then the kitchen photo. magick bRdUfVc.png Ymsusb9.png -background None -compose Over -layers Merge +repage out.png If I u...