On Fri, 10 Nov 2000, "wolfgang hofer" <wolfgang.hofer@xxxxxxxxx> wrote: > For painting Animations it can be useful > to see the previous or next frame(s) > more or less transparent. > > Here are 2 Variants A) and B) how to implement such features in GIMP. [...] > B) OnionLayer is a new 'special' layertype, > known to the GIMP core app. > GIMP offers a PDB Interface > > - gimp_image_add_onionlayer(image_id, src_image_id, > OnionPosition, > OnionRevers, > OnionOpacity, > OnionMode) > > (do we need a special PDB interface for remove ?) > > GIMP should display the OnionLayer like any other Layer, > but set to ReadOnly. (if possible) > > The Display of image_id colud be updated on > every change of src_image_id > as long as src_image_id is valid. [...] This looks very similar to the concept of "active layers" or "shadow layers" that I explained some time ago on this list. Other proposals have been discussed as well, using different or similar names ("action layers", "plug-in layers") and doing different or similar things, so it is a bit difficult to remember what each proposal is about (because the similar names are confusing but the underlying concepts are sometimes different). The concept that I am refering to is the following: - You could add an "active layer" to an image. This layer takes as parameters the name of a PDB function, plus some other parameters such as references to other layers or layer groups (the layer groups are planned for 2.0, I think). - The references to other layers can be relative (N layers above or below the current one) or absolute (layer number X in the stack). - The "active layer" cannot be edited by the user. - The layer shown or hidden, its opacity can be changed like a normal layer, and it can be moved up or down in the stack (as long as the contstraints of the relative references are respected). - When you create the layer or whenever one of the referenced layers changes, the PDB function associated with the "active layer" is run (taking its input from the other layers) and the result is stored in the tiles of the "active layer". - It is possible to disable the automatic updating of the "active layer" and to switch to manual updates for performance reasons. Originally, I was thinking about using layer references inside the current image only, because then you can save all parameters of the active layer into the XCF file and they would have no dependencies on other files. But your proposal for "onion layers" looks like a natural extension of this concept, if you allow an "active layer" to reference some layers in another image. These layers with external dependencies could not be saved in the XCF file (or we would have to come up with a very clever mechanism for maintaining the dependencies between images) but that would be enough for what you want to do with them. In this case, the PDB function would be a simple copy of the referenced layer. There are some plans to implement something like this for 2.0, so we could start thinking about the details as soon as 1.2 is out. -Raphael