Search found 313 matches

by whugemann
2020-03-18T11:23:55-07:00
Forum: Users
Topic: Set 4 borders of different widths
Replies: 5
Views: 1547

Re: Set 4 borders of different widths

OK, I see: The offsets must be negative, then they do the trick! Your code is possibly somewhat more transparent than that for -splice.
by whugemann
2020-03-18T00:25:32-07:00
Forum: Users
Topic: Set 4 borders of different widths
Replies: 5
Views: 1547

Re: Set 4 borders of different widths

I couldn't verify the secret -extent options you mentioned, but anyway -splice is probably the more direct approach. Thus the code is something like magick -size 400x300 xc:yellow -background gray -splice 50x100 -gravity southeast -splice 20x200 test.jpg and you have to use -splice only twice.
by whugemann
2020-03-17T12:21:40-07:00
Forum: Users
Topic: Set 4 borders of different widths
Replies: 5
Views: 1547

Set 4 borders of different widths

How can I create four borders of different widths? I would have expected this to be something along the lines of magick in.jpg -border 20x50+10+20 out.jpg but the usual geometry nomenclature doesn't seem to work over here. And the alternative -frame seems to use the geometry settings for the 3D desi...
by whugemann
2019-12-26T11:33:12-07:00
Forum: Users
Topic: -geometry widthxheight<
Replies: 13
Views: 5490

Re: -geometry widthxheight<

Correction: The most efficient code is of cause

Code: Select all

-extent "%%[fx:max(w,%OW%)]x%%[fx:max(h,%OH%)]"
as you can address the input image's width and height directly.
However, this code does only work with IM 7. In my understanding the functionaly of fx has been extended with IM 7 (?).
by whugemann
2019-12-24T09:27:59-07:00
Forum: Users
Topic: Trimming montage-d images
Replies: 3
Views: 2350

Re: Trimming montage-d images

So far I thought that ":-" defaults to miff.
But you are right: When using "png:-", "miff:-" or just "-", piping works correctly with IM 7.
by whugemann
2019-12-24T08:45:29-07:00
Forum: Users
Topic: Trimming montage-d images
Replies: 3
Views: 2350

Trimming montage-d images

When doing a montage with some distance between the individual images, one gets a white border surrounding the montage image. With IM 6 I used to get rid of this white border by piping it to convert and using either -trim or -shave , i.e. montage rose: rose: rose: rose: -tile 2x2 -geometry x+8+8 :- ...
by whugemann
2019-12-24T08:26:30-07:00
Forum: Users
Topic: How can I merge this 8 small images into 1 big image?
Replies: 4
Views: 2791

Re: How can I merge this 8 small images into 1 big image?

montage.exe resp. magick.exe montage is the suitable tool:

Code: Select all

magick montage out_%02d.jpg -tile 4x2 -geometry x+0+0 module_again.jpg
The option -geometry x+0+0 garantuees seamless montaging.
by whugemann
2019-12-22T01:35:46-07:00
Forum: Users
Topic: Point picker GUI under Windows?
Replies: 6
Views: 2984

Re: Point picker GUI under Windows?

Thanks, the decisive hint was the sparse-color: format, which I didn't know of. In order to make the point marker extraction reliable in a JPEG environment, I would have to make the user draw larger dots. Which is fine, as these can be seen more easily on a large photo. After applying the +transpare...
by whugemann
2019-12-21T09:34:47-07:00
Forum: Users
Topic: Point picker GUI under Windows?
Replies: 6
Views: 2984

Re: Point picker GUI under Windows?

snibgo wrote:
2019-12-21T09:00:04-07:00
The script then finds the four red pixels.
Well, could you make a suggestion how this could actually be done? How can I get IM to spit out the coordinates of the four red pixels to the console or a text file?
by whugemann
2019-12-21T08:10:07-07:00
Forum: Users
Topic: Point picker GUI under Windows?
Replies: 6
Views: 2984

Point picker GUI under Windows?

This might be a little bit off topic, but could you think of a suitable GUI that could run a Windows cmd-Script or alike, providing it with a file with pixel coordinates? The question arises in the context of a recently written script that rectifies photographs by means of IM's -distort perspective ...
by whugemann
2019-12-21T00:13:23-07:00
Forum: Users
Topic: -geometry widthxheight<
Replies: 13
Views: 5490

Re: -geometry widthxheight<

magick wizard: -extent %[fx:max(1000/w,3000/h)*100)]% result.png Your answer set me on the right track. The most efficient code for me is -extent "%%[fx:max(%IW%,%OW%)]x%%[fx:max(%IH%,%OH%)]" where IW and IH are the input images width and height and OW and OH are the output images width and height....
by whugemann
2019-12-16T08:53:33-07:00
Forum: Users
Topic: can't estimate the jpeg quality
Replies: 2
Views: 2225

Re: can't estimate the jpeg quality

The JPEG quality was not defined by the original JPEG standard. It was introduced only later by the Independent JPEG Group's code (IJG), setting the quality of the DQTs in the original JPEG standard to 50% and providing a scaling algorithm for the matrix elements. Thus the JPEG quality can only be r...
by whugemann
2019-12-16T08:36:23-07:00
Forum: Users
Topic: -geometry widthxheight<
Replies: 13
Views: 5490

Re: -geometry widthxheight<

Returning to my original problem after a few days off, I had to discover that the trick doesn't work with -extent , as magick -size 300x200 xc:yellow -extent 200x400^<! rs2.png does not yield the same dimensions as magick -size 300x200 xc:yellow -resize 200x400^<! rs.png With -extent it's still 200x...
by whugemann
2019-12-06T15:39:26-07:00
Forum: Users
Topic: -geometry widthxheight<
Replies: 13
Views: 5490

Re: -geometry widthxheight<

Thank you, Fred,

Code: Select all

magick -size 300x200 xc:yellow -resize 200x400^<! rs.png
does the trick I need here under Windows. I did not know that you can combine the modifiers. Is that mentioned anywhere? Surely not in the corresponding section of Anthony's Usage pages (?).
by whugemann
2019-12-06T01:56:55-07:00
Forum: Users
Topic: Spreadsheet Fed Variable Inputs?
Replies: 4
Views: 2735

Re: Spreadsheet Fed Variable Inputs?

If I would have all the information in a spreadsheet, I would use the spreadsheet application to create the right commands and export them to a script file. Thus the basic trick is to do something like (Excel code): =concatenate("magick -size ",A1," label:",A2," ",A3) assuming you have the sizes in ...