-region not working

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Locked
Lars-Daniel
Posts: 37
Joined: 2015-09-20T05:55:17-07:00
Authentication code: 1151

-region not working

Post by Lars-Daniel »

Code: Select all

wget "http://www.imagemagick.org/Usage/warping/koala.gif"
convert koala.gif  -region 30x30+10+10 -resize 75% -fill red -colorize 30%  koala_region_shrink.gif
expected result: http://www.imagemagick.org/Usage/maskin ... shrink.gif
result: a complete colorized image

version: "Version: ImageMagick 7.0.6-0 Q8 x64 2017-06-11"

User avatar
fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: -region not working

Post by fmw42 »

I do not understand why you are doing a -resize 75% inside the region command. Can you explain? What are you trying to resize -- just the region or the whole image?

I do agree that one gets different result for IM 6.9.8.10 and IM 7.0.6.0. I also get an error when adding +region at the end in IM 7.

Code: Select all

magick koala.gif -region 30x30+10+10 -resize 75% -fill red -colorize 30% +region koala_region_shrink.gif
magick: invalid argument for option '+region' '(null)' at CLI arg 10 @ error/operation.c/CLISimpleOperatorImage/3109.

Lars-Daniel
Posts: 37
Joined: 2015-09-20T05:55:17-07:00
Authentication code: 1151

Re: -region not working

Post by Lars-Daniel »

fmw42 wrote:
2017-06-24T15:01:54-07:00
I do not understand why you are doing a -resize 75% inside the region command. Can you explain? What are you trying to resize -- just the region or the whole image?
Because I've RTFM and it's an example in there :) http://www.imagemagick.org/Usage/maskin ... _internals

User avatar
fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: -region not working

Post by fmw42 »

Lars-Daniel wrote:
2017-06-24T15:14:39-07:00
fmw42 wrote:
2017-06-24T15:01:54-07:00
I do not understand why you are doing a -resize 75% inside the region command. Can you explain? What are you trying to resize -- just the region or the whole image?
Because I've RTFM and it's an example in there :) http://www.imagemagick.org/Usage/maskin ... _internals
OK. Thanks. I understand now from Anthony's examples. But you do not need to be irritated or vulgar about it. You could have just said where you got the example and it was not working. I just wanted to understand the question and try to verify it. I did not know which was correct.

Lars-Daniel
Posts: 37
Joined: 2015-09-20T05:55:17-07:00
Authentication code: 1151

Re: -region not working

Post by Lars-Daniel »

Sorry, didn't want to sound vulgar. "RTFM" is a fixed term and never meant vulgar. It's even part of modern dictionaries: http://www.dictionary.com/browse/rtfm

Actually, I just wanted to make a joke, since everyone says: RTFM ... "RTM" sounds like "ready to manufacture", which also is a fixed term.

User avatar
fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: -region not working

Post by fmw42 »

FYI, from Wikipedia:

RTFM is an initialism for the expression "read the f...ing manual" or, in the context of the Unix computer operating system, "read the f...ing man page". The RTFM comment is usually expressed when the speaker is irritated by another person's question or lack of knowledge.

But I accept your apology. Don't worry about it.

Lars-Daniel
Posts: 37
Joined: 2015-09-20T05:55:17-07:00
Authentication code: 1151

Re: -region not working

Post by Lars-Daniel »

Let's name it: "Read the fine manual". I'm sorry and I won't use it in future.

User avatar
fmw42
Posts: 26383
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: -region not working

Post by fmw42 »

Lars-Daniel wrote:
2017-06-24T15:37:21-07:00
Let's name it: "Read the fine manual".
Good idea! I will try to read it that way in the future.

Locked