Gracefully handling BPP in a python plugin

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



  Hello,

I'm writing a plugin that takes a drawable as input for pixel values. 
What kind of BPP can I expect? I'd say 4 and 3 are color layers with and 
without alpha. Will I encounter 2 and 1 for grey-levels with and without 
alpha, too? I can't find a way to create a layer in grey levels (or to 
change an existing color one to grey levels). Am I overlooking the 
obvious or would that only apply to layer masks?

I'm actually using the drawable pixels fro set the foreground color for 
various operation (selection stroke and bucket fill). Is there a general 
function to convert the pixel values betwen drawables of different 
"depth"? or can I put in gimp_context_set_foreground() whatever I get 
from gimp_drawable_get_pixel()?



_______________________________________________
Gimp-developer mailing list
Gimp-developer@xxxxxxxxxxxxxxxxxxxxxx
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer


[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux