I am having issues re-writing one of the default logo scripts in GIMP(using Script-fu based on scheme). For one thing the alpha layer is not shown in the layer browser after the image is shown. I am re-writing the Create Neon Logo script(neon-logo.scm) and I want it to do the following before it displays the new image:
- add an alpha channel
- change black(background color) to transparent via colortoalpha
return the generated image as an object to be used in another python script(using for loops to generate 49 images) I have tried modifying the following code to the default script:
(gimp-image-undo-disable img) (apply-neon-logo-effect img tube-layer size bg-color glow-color shadow) *Generates neon logo (set! end-layer (car (gimp-image-flatten img))) *Flattens image (gimp-layer-add-alpha end-layer) *Adds alpha layer as last layer in img(img=the image) (plug-in-colortoalpha img 0 (255 255 255)) *Uses color to alpha-NOT WORKING (gimp-image-undo-enable img) *Enables undo (gimp-display-new img) *Displays new image
For number 3 my python code is this:
for str1 in list1:
for color1 in list3:
img = pdb.script_fu_neon_logo(str1,50,"Swis721 BdOul BT",(0,0,0),color1,0)
But img is a "Nonetype" object. I would like to make it so that instead of displaying the generated image in a new window, it just returns the generated image for use with my python script. Can anyone help?