Hi WeSee,
On 18 January 2013 16:36, We See <[email protected]> wrote:
>> By the way, OpenFlight is not the only file format with special attributes,
>> maybe it is a good idea to define a generic rule on how to store these
>> attributes in a node graph, so all plugins should load special attributes in
>> the same way.
>>
>
> Yes, I think so too. Do you know, whethere there exists a kind of process how
> to define and (more important) to announce such a rule? Is discussing it in
> this forum sufficient to be noticed from all plugin-developers? Exists a wiki
> for that.
Using UserData/Value storage in loaders isn't something that we have
documented programatically right now. What we do have is are query
methods for the Protocols, Extensions and Options supported by the
ReaderWriter's the methods are (see include/osgDB/ReaderWriter):
typedef std::map<std::string, std::string> FormatDescriptionMap;
typedef std::list<std::string> FeatureList;
/** Return which protocols are supported by ReaderWriter. */
virtual const FormatDescriptionMap& supportedProtocols() const
{ return _supportedProtocols; }
/** Return which list of file extensions supported by ReaderWriter. */
virtual const FormatDescriptionMap& supportedExtensions()
const { return _supportedExtensions; }
/** Return which list of file extensions supported by ReaderWriter. */
virtual const FormatDescriptionMap& supportedOptions() const {
return _supportedOptions; }
If you run in a console:
osgoconv --formats
You'll see the list of reported extension/options for the various
plugins. Which this isn't exactly what you are after, perhaps this
approach could be taken for in scene graph extensions, i.e. have
supportedUserData() or something similar.
Robert.
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org