Shayton Equilibrium Kitchen Utensil 2003 User Manual

Page of 194
MediaScript Objects and Methods 67 
• 
• 
• 
layers
 - for PSD files, specifies the layers to be converted. Specify the layers to collapse 
and the order in which to collapse them. The layer numbers begin at 0 (background) and 
go up. For more information see “load()” on page 101.
Example
var image = new Media();
image.load(name @ "peppers.tga");
image.convert(rtype @ "Grayscale", dither @ 5);
image.save(type @ "jpeg");
c o n v o l v e ( )
Convolves the image with the specified filter.
Syntax
convolve( 
filter @ <"filter list"> 
);
Parameters
filter
 - specifies the standard filter to be applied. Available filters are: 
“Blur” - standard blur filter.
“Smooth” - standard smooth filter.
“Sharpen” - standard sharpen filter.
“Emboss1” - standard emboss filter.
“Emboss2” - alternate emboss filter.
“Edges” - edge filter.
c r o p ( )
Crops/resizes the media to a specified size. This function fully supports CMYK.
The background color may vary with this function, depending on the original Media 
object. If the object has a set background color, or it is set with the 
 function, 
MediaRich uses the set color. However, if the object has no set background color, 
MediaRich does the following:
For objects with 256 colors or less, MediaRich uses the first color index
For objects with 15-bit or greater resolution (including the CMYK color-space), 
MediaRich uses black