EasyManua.ls Logo

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE - Page 458

MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
1378 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
458 ActionScript classes
A matrix convolution is based on an n x m matrix, which describes how a given pixel value in
the input image is combined with its neighboring pixel values to produce a resulting pixel
value. Each result pixel is determined by applying the matrix to the corresponding source pixel
and its neighboring pixels.
For a 3 x 3 matrix convolution, the following formula is used for each independent color
channel:
dst (x, y) = ((src (x-1, y-1) * a0 + src(x, y-1) * a1....
src(x, y+1) * a7 + src (x+1,y+1) * a8) / divisor) + bias
When run by a processor that offers SSE (Streaming SIMD Extensions), certain filter
specifications perform faster.
The filter must be a 3 x 3 filter.
All the filter terms must be integers between -127 and +127.
The sum of all the filter terms must not have an absolute value greater than 127.
If any filter term is negative, the divisor must be between 2.00001 and 256.
If all filter terms are positive, the divisor must be between 1.1 and 256.
The bias must be an integer.
A filter is not applied if the resulting image would exceed 2880 pixels in width or height. For
example, if you zoom in on a large movie clip with a filter applied, the filter is turned off if the
resulting image reaches the 2880-pixel limit.
Availability: ActionScript 1.0; Flash Player 8
See also
applyFilter (BitmapData.applyFilter method), filters (MovieClip.filters
property)
, cacheAsBitmap (MovieClip.cacheAsBitmap property)

Table of Contents

Related product manuals