Search found 13038 matches

by snibgo
2010-03-07T00:51:49-07:00
Forum: Bugs
Topic: Unicode BOM header
Replies: 2
Views: 7916

Re: Unicode BOM header

That is "Notepad++", which is a different program. There are lots of workarounds. For this purpose, I use a program that strips out any BOMs from a file. But it is annoying; the correct behaviour for IM, I feel, is to act like any text editor and not to display the "?" glyph or any other glyph for a...
by snibgo
2010-03-06T23:51:19-07:00
Forum: Bugs
Topic: Unicode BOM header
Replies: 2
Views: 7916

Unicode BOM header

Windows 7, IM 6.5.8-8: convert -size 1920x1080 -gravity South ^ -background None ^ -fill blue ^ -font Verdana -pointsize 100 ^ caption:@captCopy.txt ^ captCopy.png captcopy.txt is encoded in UTF-8: {ef}{bb}{bf}Copyright {c2}{a9} 2010 Alan Gibson\r\n Where {ef} is the single byte, represented in hex ...
by snibgo
2010-03-05T08:43:50-07:00
Forum: Users
Topic: Can someone explain what the difference is?
Replies: 8
Views: 17835

Re: Can someone explain what the difference is?

You are missing +0+0 on the crop.

Rule of thumb: geometry (axb+c+d) with no offsets always needs "+0+0".
by snibgo
2010-03-04T17:47:12-07:00
Forum: Users
Topic: repairing jpegs
Replies: 23
Views: 71364

Re: repairing jpegs

I dumped them using a filter called DumpBin that converts nonprintable characters to hex. Then I counted the characters until I reached FF D8 FF, which is hex for the octal "\377\330\377", which IM expects to be at the start. You might find other files have a different number of spurious bytes. If s...
by snibgo
2010-03-04T07:24:37-07:00
Forum: Users
Topic: Can someone explain what the difference is?
Replies: 8
Views: 17835

Re: Can someone explain what the difference is?

The extra output files will be because your shave or splice or both will need zero offsets: "+0+0". If you post your original file, we can test with what you've got, so our advice may be more precise.

Also, let us know what IM version you are using.
by snibgo
2010-03-04T05:49:24-07:00
Forum: Users
Topic: Can someone explain what the difference is?
Replies: 8
Views: 17835

Re: Can someone explain what the difference is?

Brackets don't localise the gravity change to within the brackets. To get the multi-command to give the same version as the all-in-one, insert "-gravity northeast" at the start of the final command: convert .\done1\3_%filenameext% -gravity northeast -background white -splice 100x100 -gravity center ...
by snibgo
2010-03-04T05:01:20-07:00
Forum: Users
Topic: Can someone explain what the difference is?
Replies: 8
Views: 17835

Re: Can someone explain what the difference is?

I haven't tested this, but I suspect the problem is "-gravity". In the all-in-one command, the value "northeast" is carried through until you change it to "center". In the separate commands, it will be reinitialise (to "northwest"?) at each command.
by snibgo
2010-03-04T02:06:28-07:00
Forum: Users
Topic: repairing jpegs
Replies: 23
Views: 71364

Re: repairing jpegs

By comparing imgfoo.jpg, a valid jpg file, the JPEG spec at http://www.w3.org/Graphics/JPEG/jfif3.pdf, and /usr/share/ImageMagick-6.4.5/config/magic.xml which contains the line: <magic name="JPEG" offset="0" target="\377\330\377"/> it seems imgfoo contains 21 spurious bytes at the start. These can b...
by snibgo
2010-03-04T01:00:21-07:00
Forum: Users
Topic: libMagickCore.so.3
Replies: 6
Views: 23395

Re: libMagickCore.so.3

Hi Bonzo. I can't remember if you run Mac, Windows or *nix. On Ubuntu, I have spent a frustrating few days compiling IM and especially ffmpeg, and all their various dependancies. It turns out the trick for IM (and ffmpeg) both is to ensure I have done both: $ export LDFLAGS="-L/usr/local/lib -Wl,-rp...
by snibgo
2010-03-03T12:50:30-07:00
Forum: Users
Topic: SAve lossless copies of images (JP2 -> JP2)
Replies: 3
Views: 8565

Re: SAve lossless copies of images (JP2 -> JP2)

JPEG 2000 can be lossy, so I would guess the exact command/parameters would be relevant if you want it to be lossless.

You might post a link to the image.

And you might update IM.
by snibgo
2010-03-03T12:30:42-07:00
Forum: Users
Topic: repairing jpegs
Replies: 23
Views: 71364

Re: repairing jpegs

Have you looked at the first 4 (or whatever) magic bytes? Maybe that's all that is wrong. If so, a simple C program could fix it.
by snibgo
2010-03-03T01:43:20-07:00
Forum: Users
Topic: How to identify dropframes/missing frames
Replies: 7
Views: 16656

Re: How to identify dropframes/missing frames

I'm currently converting my brain from Windows. The actual script isn't important, except as a proof of concept. You would have to determine how to process the output numbers, perhaps highlighting returned values that are either higher or lower than expected. As you say, 0 = no change. I reckon it s...
by snibgo
2010-03-02T22:57:30-07:00
Forum: Users
Topic: How to identify dropframes/missing frames
Replies: 7
Views: 16656

Re: How to identify dropframes/missing frames

It works quite well. #!/bin/bash rm framediffs.lis ffmpeg -i MPEG0004.AVI f%d.png framenum=1 while [ $framenum -lt 50 ] do file1=f$(( $framenum )).png file2=f$(( $framenum + 1 )).png compare -metric RMSE $file1 $file2 NULL: 2>diff.lis fdiff=`cat diff.lis |cut -d ' ' -f 1` echo $file1 $file2 $fdiff>>...
by snibgo
2010-03-02T20:32:58-07:00
Forum: Users
Topic: How to identify dropframes/missing frames
Replies: 7
Views: 16656

Re: How to identify dropframes/missing frames

compare -metric RMSE f200.png f201.png NULL: will return a numerical measure of the difference between the two frames. Higher numbers are more different. You could write a script to generate a list of such differences, then look for entries that are peaks, or are more than say 10% greater then the ...
by snibgo
2010-03-02T10:24:13-07:00
Forum: Users
Topic: Resizing to 100% x 1pixel
Replies: 3
Views: 8953

Re: Resizing to 100% x 1pixel

Inelegant solution (Ubuntu):

Code: Select all

convert input.png -resize `convert input.png -format %[fx:w] info:`x1! output.png