Search found 8879 matches

by anthony
2019-01-14T22:27:40-07:00
Forum: Users
Topic: OCR image preprocessing with ImageMagic
Replies: 7
Views: 341

Re: OCR image preprocessing with ImageMagic

If the image is from a screen dump... Make the image BIGGER.... tesseract is designed for scanned documents at about 600dpi, but displays are typically only 90 to 100dpi so scaling by 600% often works wonders. I also find some fonts make go bad. For example a 'serif f' will often be thought of as a ...
by anthony
2019-01-14T22:21:22-07:00
Forum: Users
Topic: How would you go about separating elements from their background?
Replies: 3
Views: 182

Re: How would you go about separating elements from their background?

Also how 'fuzzy' and 'shaped' the border is between background and foreground. For example rotated square images? Or other odd shapes. What other 'junk' is on the page... Text? It is all a matter of defining what is foreground and background in a way the computer can understand. The trouble with com...
by anthony
2019-01-14T21:43:02-07:00
Forum: Users
Topic: replace white with transparency
Replies: 6
Views: 65316

Re: replace white with transparency

Compare it with a white image, and generate a mask, with anti-aliased transparent edges... See http://www.imagemagick.org/Usage/masking/#semi-trans Though it is simpler as the background is just white. Basically work out what IS fully-opaque (foreground), and you know what is fully-transparent (back...
by anthony
2018-10-13T16:23:30-07:00
Forum: Users
Topic: Optimizing Imagemagick convert & composite code
Replies: 14
Views: 10169

Re: Optimizing Imagemagick convert & composite code

Getting full lines and spaces requires careful quoting. You need to read, not concatenate into a work list. Note the use of "$line" in the loop.. while read line; do convert canvas.jpg \ \( -size 100x100 -background white -font arial.ttf \ -fill black label:"$line" -trim +repage -depth 8 \) \ -gravi...
by anthony
2018-09-24T17:50:18-07:00
Forum: Users
Topic: How to draw with tranparent color / how draw erasures?
Replies: 3
Views: 2148

Re: How to draw with tranparent color / how draw erasures?

A Number of ways... Here are two... Using Masks with Images http://www.imagemagick.org/Usage/masking/#masks Composing using Duff-Porter methods, Specifically with Dst-Out http://www.imagemagick.org/Usage/compose/#dstout But essentially you want to manipulate the images alpha channel, either directly...
by anthony
2018-08-07T16:31:31-07:00
Forum: Users
Topic: Is it possible to combine 2 images & make a transparent PNG?
Replies: 8
Views: 17908

Re: Is it possible to combine 2 images & make a transparent PNG?

I think this is similar to the example... http://www.imagemagick.org/Usage/masking/#two_background Two images same foreground different background... Recover the foreground on transparency. Also see discussion "undo a composite -dissolve" http://www.imagemagick.org/discourse-server/viewtopic.php?t=1...
by anthony
2018-08-05T16:50:46-07:00
Forum: Users
Topic: How do I Apply Multiple Screen and Multiply to one image?
Replies: 22
Views: 7029

Re: How do I Apply Multiple Screen and Multiply to one image?

I was unaware at Associate and Disassociate options as well. Any idea as to what they actually do? does it actually add/delete the alpha channel data from the image? The page is not exactly clear (needs some examples I suppose). Also the aliases 'On' and 'Off' are missing from the list as being the ...
by anthony
2018-06-24T21:45:12-07:00
Forum: Bugs
Topic: [CLOSED] possible bug +distort polynomial
Replies: 12
Views: 6153

Re: [CLOSED] possible bug +distort polynomial

Using +disort to map the source image bounds to destination image to calculate the bit-fit of the destination image viewport, needs the reverse of the distortion function. That is not possible with polynomial EWA calculations requires the derivative (slope) of the function going from destination ima...
by anthony
2018-06-24T18:28:25-07:00
Forum: Bugs
Topic: [CLOSED] possible bug +distort polynomial
Replies: 12
Views: 6153

Re: [CLOSED] possible bug +distort polynomial

Lancos is a resampling filter and as such needs a resampling area (that is a Elliptical Weighted Average). Without EWA you can't use Lancos, but you can use a 'scale-less' single point lookup... That is Interpolation! The EWA may actually work, as the function derivative, which is what is needed for...
by anthony
2018-06-23T05:45:30-07:00
Forum: Bugs
Topic: [CLOSED] possible bug +distort polynomial
Replies: 12
Views: 6153

Re: possible bug +distort polynomial

The difference in -distort and +distort is supposed to only be in the calculation of the 'viewport' of the final result. You can also override the viewport of BOTH of those operators using -define distort:viewport=WxH+X+Y See http://www.imagemagick.org/Usage/distorts/#distort_viewport You can get mo...
by anthony
2018-05-15T20:56:13-07:00
Forum: Bugs
Topic: ephemeral: no longer works
Replies: 2
Views: 2993

ephemeral: no longer works

ephemeral coder no longer appears to work.

Is this intentional?
by anthony
2018-02-07T17:52:33-07:00
Forum: Developers
Topic: Crop to an aspect ratio with "-crop 3:2"
Replies: 9
Views: 11518

Re: Crop to an aspect ratio with "-crop 3:2"

Whether to actually switch from 3:2 to 2:3 depending on image orientation may need to a option for users that do NOT want to do it (EG; they are fitting photos into a thumbnail array). I do think this will need to be a separate option, as there is currently no way to determine if a ':' was used in a...
by anthony
2018-02-07T17:08:52-07:00
Forum: Developers
Topic: Crop to an aspect ratio with "-crop 3:2"
Replies: 9
Views: 11518

Re: Crop to an aspect ratio with "-crop 3:2"

This is a viewport crop, which is similar to the calculated 'Centered Square Crop' http://www.imagemagick.org/Usage/distorts/#centered_square of course with IMv7 you can do this using -extent instead ;-) It is also related to a rotate-and-resize-crop method http://www.imagemagick.org/Usage/distorts/...
by anthony
2018-01-21T20:14:21-07:00
Forum: Users
Topic: How do I Apply Multiple Screen and Multiply to one image?
Replies: 22
Views: 7029

Re: How do I Apply Multiple Screen and Multiply to one image?

If you are composing multiple images together with the same compose method then you can also use the laying operators to do this... http://www.imagemagick.org/Usage/layers/#compose The only tricky part about this is that the first image (the background color) needs to be selected to be white, black,...