next up previous contents index
Next: Paste Up: Image menu Previous: Erase background   Contents   Index

Copy/Move

Copies or moves part of an image or drawing to another region. Before selecting `copy' or `move', click and drag on the image to select a region to copy; or double-click to make imal automatically find the edges of the object to copy.

The region is copied and pasted in the new location as soon as the mouse button is released. If the pasted portion falls partly on an image and partly on the background, the portion that falls on the image sticks to the image and the part that falls on the background sticks to the background.

If the ``move'' button in the information window is depressed, the pixels will be moved instead of copied.

The mode of interaction of the moved region with the background or other images can be changed by changing the ``Pixel interaction mode'' from the ``Config'' menu. For example, if the pixel interaction mode is ``subtract'' the moved region will be subtracted from whatever is there. (See Pixel interaction mode below).

The source and destination do not have to be in the same window. To copy or move an area from the main window to an image in another window, continue pressing the mouse button and move the mouse cursor to the new window. The copied area will be invisible while the cursor is outside one of imal's windows and will reappear when the cursor moves to the new window. Copying to other programs is not yet supported.

The colormap of the destination image is considered inviolate during a copy. The reason for this is that changing the destination colormap would require remapping the preexisting image, and after several copy operations it could eventually get corrupted, that is, the original correspondence between intensity and pixel value would be lost.

Therefore, the copied region is converted to the image depth and color type of the destination. Thus, a region moved from a 32-bit color image and pasted onto a grayscale image will be converted to grayscale values. Pixels copied onto indexed-color images are converted to the pixel value with the closest matching color so as not to disturb the existing colormap. The tradeoff of this is that, for indexed-color images, the copied region may appear slightly different from the original; thus it is recommended that indexed-color images be converted to 24 bits/pixel before cut/paste operations.

This is illustrated in the image below, where copies of the explosion at left were pasted onto an image of a purple reptile and onto a grayscale image. The pixels falling onto the grayscale image were automatically converted to grayscale, while pixels falling on the background or the dinosaur retained their original colors.


\begin{picture}( 100,200 )(0,0)
\put(0,-18){ \epsfig{file = tnimage_fig13.ps, width=5in }}
\end{picture}


next up previous contents index
Next: Paste Up: Image menu Previous: Erase background   Contents   Index
root 2010-04-22