Search found 12908 matches

by snibgo
2013-02-01T03:17:14-07:00
Forum: Users
Topic: [Solved] Convert BMP to 8-bit with specific colormap order
Replies: 3
Views: 5680

Re: Convert BMP to 8-bit with specific colormap order

Update: we don't need "-colorspace Gray", so the command simplifies to:

Code: Select all

"%IMG%convert" palette.bmp -set colorspace RGB -type Palette p.bmp
by snibgo
2013-02-01T02:36:23-07:00
Forum: Users
Topic: [Solved] Convert BMP to 8-bit with specific colormap order
Replies: 3
Views: 5680

Re: Convert BMP to 8-bit with specific colormap order

I don't think there is a way to guarantee a particular palette order. However, it seems that this does what you want (in IM v 6.7.9 on Windows7): "%IMG%convert" palette.bmp -set colorspace RGB -colorspace Gray -type Palette p.bmp "identify -verbose" shows the palette in p.bmp, and "compare" verifies...
by snibgo
2013-02-01T02:03:27-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

Any ideas on how to make this work on all files in one directory and create a directory of the cropped images within it?
http://www.imagemagick.org/Usage/basics/#mogrify
by snibgo
2013-01-31T12:15:07-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

Instead of out\%2, just put whatever directory and filename you want. If you are putting this in a Windows batch file, you need to double up the % signs. If you are typing at the command line, don't double them. I showed it as one command. If you want it as two commands, here they are: "%IMG%convert...
by snibgo
2013-01-31T10:58:07-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

Oh. Ah. Um. A script is a text file that contains commands. How you create one depends on what type of computer you are using -- in particular the operating system. This isn't a scripting forum, and I wouldn't attempt to explain it. There many guides on the net. Likewise, this isn't a camera forum. ...
by snibgo
2013-01-31T10:08:29-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

The camera exposure varies, according to the size of the receipt. It's better to use manual control, where the camera has it, so backgrounds and foregrounds are consistent. Of course, a scanner would be even better. The "black" background has light smudges, needing some heavy manipulation to remove....
by snibgo
2013-01-31T09:47:31-07:00
Forum: Bugs
Topic: Only first page of PDF is converted by IM under Windows
Replies: 3
Views: 4778

Re: Only first page of PDF is converted by IM under Windows

v6.8.0-9 was also broken.
by snibgo
2013-01-31T09:43:33-07:00
Forum: Bugs
Topic: Only first page of PDF is converted by IM under Windows
Replies: 3
Views: 4778

Re: Only first page of PDF is converted by IM under Windows

Confirmed, on Windows 7. Example of 6.8.1-10, then 6.7.9-6: D:\web\im> D:\web\im>"%IMG681%convert" -verbose j.pdf jj.jpg [ghostscript library] Files (x86)/gs/gs8.71/bin/gswin32c.exe" -q -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dEPSCrop -dAlignToPixels=0 -dGridFitTT=2 "-sDE...
by snibgo
2013-01-31T09:27:20-07:00
Forum: Users
Topic: remap problem
Replies: 1
Views: 2314

Re: remap problem

What is "-colorspace RGB" doing in your commands? When I use that, I get your (bad) result. When I omit it, I get what I think is the correct result. You don't need to change the colorspace, and I think you shouldn't. (As an aside, I would rather like to be able to specify an image and map in some o...
by snibgo
2013-01-31T04:37:15-07:00
Forum: Users
Topic: Overlapped images (what can you do with it)
Replies: 15
Views: 36047

Re: Overlapped images (what can you do with it)

Blurring will find the corners of a white line on black background, because there is a greater density of white at a corner. For example, if we draw the white outline of a square on a black background, and then blur it, the corners are lighter than the edges. "%IMG%convert" ^ -size 100x100 xc:Black ...
by snibgo
2013-01-30T23:23:36-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

The exposure varies across the images, so you don't know what levels are best. Instead, I'd use "-contrast-stretch", eg:

Code: Select all

convert in.jpg -colorspace RGB -contrast-stretch 10%%,10%% out.png
And "+repage" might be useful.
by snibgo
2013-01-30T22:42:09-07:00
Forum: Users
Topic: Overlapped images (what can you do with it)
Replies: 15
Views: 36047

Re: Overlapped images (what can you do with it)

Here's a standard deviation version of the entropy map, though I don't claim that it is better: "%IMG%convert" map_a4_south_jungle.png ^ ( +clone -channel RGB -separate +channel ^ -statistic standard-deviation 2x2 ^ -compose plus -flatten -compose over ) ^ -delete 0 ^ -threshold 50%% ^ map_sd.png Fo...
by snibgo
2013-01-30T15:09:06-07:00
Forum: Users
Topic: How to remove black background.
Replies: 15
Views: 15072

Re: How to remove black background.

A large fuzz does the trick.

Code: Select all

convert "2013-01-30 144035.jpg" -fuzz 60% -trim t.jpg
by snibgo
2013-01-30T05:39:18-07:00
Forum: Users
Topic: convert to icon darkens colours?
Replies: 6
Views: 4884

Re: convert to icon darkens colours?

Good stuff. I should add: IM has changed considerably since 6.4.0. In particular, it now assumes input and output images are sRGB ("non-linear"), but monochrome images (including separations) are RGB ("linear"). See any number of threads here where people have upgraded and the results are darker or ...
by snibgo
2013-01-30T05:27:44-07:00
Forum: Users
Topic: convert to icon darkens colours?
Replies: 6
Views: 4884

Re: convert to icon darkens colours?

You can probably figure out for yourself more than I know, but the basic idea is: - If you are happy installing from source, that's fine. - The binary Windows release works fine under Cygwin. By default, it installs into "\program files (x86)" or somwhere horrible, but you can change that, or move t...