Difference between revisions of "Xmerge"

From Christoph's Personal Wiki
Jump to: navigation, search
 
 
Line 1: Line 1:
 
'''Xmerge''' is a [[image stitching]] [[:Category:Linux Command Line Tools|command line tool]] developed by Johan Borg.
 
'''Xmerge''' is a [[image stitching]] [[:Category:Linux Command Line Tools|command line tool]] developed by Johan Borg.
  
== External links ==
+
==Command line options==
* [http://xmerge.sourceforge.net/ Official site]
+
''Note: From "<code>xmerge -h</code>".''
* [http://xmerge.sourceforge.net/ Xmerge documentation / manual]
+
 
 +
;<code>-h</code>:this message
 +
;<code>-o</code>:set output file for final image, if written (default test.ppm)
 +
;<code>-O</code>:set output file for mapping data, if written
 +
;<code>-l</code>:load saved mapping data, mutually exclusive to specifying ppm files
 +
;<code>-m</code>:magnification applied when solution is calculated (default 1.0)
 +
;<code>-M</code>:magnification applied if mapping data are loaded
 +
;<code>-b</code>:background colour (default: 255,0,0 (red))
 +
;<code>-r</code>:reference-colour for gain calculation (gui: b) (default 255,255,255)
 +
;<code>-R</code>:colour gain applied if mapping data are loaded (default 0,0,0)
 +
;<code>-B</code>:black level used when final image is created (default: 0,0,0) (colour gain or reference level must be adjusted accordingly)
 +
 
 +
*options implying non interactive operation: (in order of execution)
 +
;<code>-s</code>:solve loaded problem
 +
;<code>-W</code>:write current mapping data
 +
;<code>-w</code>:write final image
 +
 
 +
Input file(s) can be either <code>-l</code> OR a list of ppm(P6) files. When image files are specified, the images are placed on rows from left to right. The special file name / causes remaining images to be placed on a new row one position down. Empty arguments ("" in most shells) can be used to create empty locations.
 +
 
 +
==Keyboard commands==
 +
There are two main modes of operation, referred to as "Source" and "Target". Generic navigation in both modes are performed by clicking with the 2nd (center/middle) button of the pointing device at the point about which the image is to be centered. This is the only means for moving around on an image zoomed to a size larger than the program window.
 +
 
 +
;<code>m</code>:switch between source and target mode
 +
;<code>+</code>:zoom in
 +
;<code>-</code>:zoom out
 +
;<code>w</code>:write the final image to disk
 +
;<code>W</code>:write a loadable listfile describing the current state of the problem
 +
;<code>s</code>:solve the problem specified by the relations set in the Source mode
 +
;<code>r</code>:reset the solution to its initial state, useful if solving for impossible relations has been attempted, with a solution from which the solver is unable to continue, even if the relations are corrected.
 +
;<code>a</code>:auto-improve the matching of the regions specifying point-relations, by using the current solution when mapping pixels. This command usually mess things up more than it improves, and all point relations are affected, even those manually matched.
 +
;<code>q</code>:exists xmerge
 +
 
 +
==Example usage==
 +
xmerge -o foo.ppm -O foo.txt foo00.ppm foo01.ppm foo02.ppm / foo10.ppm foo11.ppm foo12.ppm
 +
will start <tt>xmerge</tt> with six images in two rows and three columns, write final the final image (when requested in the GUI, by pressing "<code>w</code>") to the file <code>foo.ppm</code>, and write the current state of the variables used in the mapping to the file <code>foo.txt</code> (when "<code>W</code>" is used in the GUI). This file can later be loaded into <tt>xmerge</tt> using "<code>xmerge -l foo.txt</code>". Using the command line option "<code>-w</code>" together with "<code>-l</code>" it is possible to write the final image corresponding to the saved data, without using the GUI.
 +
 
 +
==External links==
 +
*[http://xmerge.sourceforge.net/ Official site]
 +
*[http://xmerge.sourceforge.net/readme.html Xmerge documentation / manual]
  
 
[[Category:Graphics software]]
 
[[Category:Graphics software]]

Latest revision as of 06:49, 20 April 2007

Xmerge is a image stitching command line tool developed by Johan Borg.

Command line options

Note: From "xmerge -h".

-h
this message
-o
set output file for final image, if written (default test.ppm)
-O
set output file for mapping data, if written
-l
load saved mapping data, mutually exclusive to specifying ppm files
-m
magnification applied when solution is calculated (default 1.0)
-M
magnification applied if mapping data are loaded
-b
background colour (default: 255,0,0 (red))
-r
reference-colour for gain calculation (gui: b) (default 255,255,255)
-R
colour gain applied if mapping data are loaded (default 0,0,0)
-B
black level used when final image is created (default: 0,0,0) (colour gain or reference level must be adjusted accordingly)
  • options implying non interactive operation: (in order of execution)
-s
solve loaded problem
-W
write current mapping data
-w
write final image

Input file(s) can be either -l OR a list of ppm(P6) files. When image files are specified, the images are placed on rows from left to right. The special file name / causes remaining images to be placed on a new row one position down. Empty arguments ("" in most shells) can be used to create empty locations.

Keyboard commands

There are two main modes of operation, referred to as "Source" and "Target". Generic navigation in both modes are performed by clicking with the 2nd (center/middle) button of the pointing device at the point about which the image is to be centered. This is the only means for moving around on an image zoomed to a size larger than the program window.

m
switch between source and target mode
+
zoom in
-
zoom out
w
write the final image to disk
W
write a loadable listfile describing the current state of the problem
s
solve the problem specified by the relations set in the Source mode
r
reset the solution to its initial state, useful if solving for impossible relations has been attempted, with a solution from which the solver is unable to continue, even if the relations are corrected.
a
auto-improve the matching of the regions specifying point-relations, by using the current solution when mapping pixels. This command usually mess things up more than it improves, and all point relations are affected, even those manually matched.
q
exists xmerge

Example usage

xmerge -o foo.ppm -O foo.txt foo00.ppm foo01.ppm foo02.ppm / foo10.ppm foo11.ppm foo12.ppm

will start xmerge with six images in two rows and three columns, write final the final image (when requested in the GUI, by pressing "w") to the file foo.ppm, and write the current state of the variables used in the mapping to the file foo.txt (when "W" is used in the GUI). This file can later be loaded into xmerge using "xmerge -l foo.txt". Using the command line option "-w" together with "-l" it is possible to write the final image corresponding to the saved data, without using the GUI.

External links