Fred Weinhaus on wrote...
| Here is an even easier way to extend the edges of the Northwest corner:
|
| # crop and make transparent
| convert fancy_add.jpg[60x88+2+2] -fuzz 20% -transparent
| "rgb(255,255,255)" +repage fancy_add2.gif
| http://www.fmwconcepts.com/misc_tests/Framing/fancy_add2.gif
|
|
| # flop to get Northwest corner
| convert fancy_add2.gif -flop fancy_add4.gif
|
| # extend Northwest corner to 100x150 (quarter size)
| convert -size 100x150 xc:"#ffffffff" -channel RGBA fancy_add4.gif
| -fx "v" fancy_add5.gif
|
| Then do something similar to the last step below to montage
| rearranged quadrants.
|
NOTE that this relies on the use of the default -virtual-pixel setting
of 'Edge'.
See http://imagemagick.org/Usage/misc/#virtual
And only the color of the actual edge pixels are extended over the
larger area. For this particular image this produces a distinct color
distortion that was caused originally by the use of the lossy JPEG image
file format.
Because of this type of effect a better method is tile a copy of
just the top edge, and ditto for the sid edges.
ASIDE: you can generate a faster -virtual-pixel enlargement of an image
using the new -distort operator using a special 'viewport' setting, to
define the output 'view' of the distorted (no distort used) image.
That is a faster form of the last command is...
convert fancy_add4.gif -set option:distort:viewport 100x150+0+0 \
-filter point -distort SRT 0 fancy_add5.gif
Of course it also will have the same 'edge replaction' problem.
| http://www.fmwconcepts.com/misc_tests/Framing/fancy_add_frame2.gif
|
|
Also note that this corner image is not a good one for framing.
The shading effect for the top/bottom and left/right edges should be
different. However the width of the two parts in the corner image are
not the same, which can be seen in the 45 degree join mis-match on the
outside of the frame.
Because of this you can not get the correct shading effects needed using
this corner image!
Anyone like to contribute a better corner image?
Or better still two seperate edge images of the same width.
Anthony Thyssen ( System Programmer ) <[EMAIL PROTECTED]>
-----------------------------------------------------------------------------
This signature is lying to you.
-----------------------------------------------------------------------------
Anthony's Home is his Castle http://www.cit.gu.edu.au/~anthony/
_______________________________________________
Magick-users mailing list
[email protected]
http://studio.imagemagick.org/mailman/listinfo/magick-users