Talk:Percentage difference between images: Difference between revisions

From Rosetta Code
Content added Content deleted
(answer)
(→‎examples: response)
Line 8: Line 8:
: diff: 0.004283 percent
: diff: 0.004283 percent
: [[User:Blue Prawn|Blue Prawn]] 00:01, 14 November 2008 (UTC)
: [[User:Blue Prawn|Blue Prawn]] 00:01, 14 November 2008 (UTC)
::Some of us don't have Gimp. Having images would also make the article/task more aesthetically appealing.
::--[[User:DanBron|DanBron]] 15:04, 14 November 2008 (UTC)

Revision as of 15:04, 14 November 2008

examples

Please provide sample inputs and outputs. --DanBron 23:34, 13 November 2008 (UTC)

Any image can be used, open it in Gimp and save it with 2 different jpeg compression ratio.
Then you have img1.jpg and img2.jpg, so call this script this way (followed by its output):
./script.ml img1.jpg img2.jpg
diff: 0.004283 percent
Blue Prawn 00:01, 14 November 2008 (UTC)
Some of us don't have Gimp. Having images would also make the article/task more aesthetically appealing.
--DanBron 15:04, 14 November 2008 (UTC)