CompuServe Messages

#Help! Buggy macro

    15-Jul-94 23:28:37
Sb: #Help! Buggy macro
Fm: Charles Blaquiere 76046,1756
To: Black Belt Systems 76004,1771
Ben, I've created a wondrous macro to perform automated background removal on a series of images. The user just samples the background color to be keyed out, and away it goes, creating one anti-aliased alpha mask after another. Unfortunately, it has a bug which I can't solve. I tried it with a few images of an ampersand on a green background. When processing the first frame, the macro asks the user to sample the background; I circle some green. The macro then proceeds, using "color key max merge", to replace all non-green areas (the ampersand) with a black background; then, it replaces the green areas with white, using "color key MIN merge". A bit of fudging around, and the alpha channel is ready to be saved. No problemo. The bug occurs on all remaining frames: I only wanted the user to sample the background on the first frame, and it seems that Imagemaster loses track of the defined key color after frame 1 has been processed. Oh, I did try and have the AREXX macro save the 'cdef' red/green/blue/avg/var values on frame 1, and impose them on Imagemaster by using 'colchange' as indicated by your tech support person, but to no avail. Even though my RGB key color is 0,255,0 on frame 1, by the time all frames have been processed, manually clicking on any color key operation shows the key color has been changed to 0,100,0 — a far cry from pure green. As a result, all frames except the first one get improperly processed. I uploaded the REXX script, along with two tiny files needed for its use. All 3 files are to be stored in RXPI: and have been uploaded as BLUESC.RX, WHITE.24, and BLACK.24. Would you mind taking a look? I've got a real gem of a macro, a friend needs it pronto, and I'm one step away from making it work. Won't you help? Thanks. Blaq!