Object plugins (Was: Re: Article in Inter.net (Was: RE: Bug 51471- Possible bugfix))
Andreas Zehender <[email protected]>
| Newsgroups | gmane.comp.kde.devel.kpovmodeler |
|---|---|
| Message-ID | <[email protected]> |
Hi! On Friday, 07. March 2003 21:34, CARVALHO Luis Passos wrote: > > I think the rules belong to the objects, not the renderers > > and that's what the > > insert rules system was designed for. Each plugin that adds > > new objects adds > > the insert rules for these objects. > > I don't want the scene to become invalid if you change the renderer. > > I see. Well, we could add the base ruleset used to the scene specification, > but I agree with you that the rules belong to the objects, not the renderer > or kpovmodeler. > It would be just a way to make it easier for a user to use the application > with a specific renderer that doesn't support the rules specified for > povray. My suggestion: We have a number of templates that can be choosen by the user when he creates a new scene. "Empty povray scene", "Small povray scene", "Empty renderman scene"... Dependent on the selected template the correct set of object plugins is chosen. If the user loads additional plugins with objects not supported by the current renderer, it is his fault. The only problem so far: The insert rules system object is a singleton. Imagine the user opens a povray _and_ a renderman scene. These two parts are in the same process space and will share the singleton instance. The system will contain the rules of both plugins and therefore the rules of all renderman and povray objects. Same with the prototype manager. The plugins are loaded on a per part basis. That means the actions for the plugins objects (menu and toolbar items) are only visible in the corresponding window. There will be no actions for renderman objects in the menubar and toolbar for the povray scene. But if the user copies renderman objects into the povray scene, the objects are known globally by the system and will be inserted without any warning into the povray scene, although the renderman plugin is not loaded The only solution seems to be for me to remove many singletons like the insert rules system and the prototype manager, add an own instance of these classes to the part and add a pointer to the part to all objects. Greetings, Andreas -- -------------------------------------------------- Andreas Zehender Master of Computer Science, Dipl. Ing. (BA) http://www.azweb.de [email protected] | [email protected] -------------------------------------------------- List archive and information: http://mail.kde.org/mailman/listinfo/kpovmodeler-devel