Previous | Next

Image objects

 # Make a new image and layer:
 img = gimp.Image(width, height, RGB)
 drawable = gimp.Layer(img, "Sphere Layer",
   width, height, RGB_IMAGE, 100, NORMAL_MODE)

 img.add_layer(drawable, 0)

 gimp.set_foreground(sphere_colour)
 gimp.set_background(bg_colour)

 pdb.gimp_edit_fill(drawable, BACKGROUND_FILL)
(from sphere.py)