OpenGLContext.loaders.vrml97
index
/home/mcfletch/pylive/OpenGLContext/loaders/vrml97.py

VRML97 loader module for OpenGLContext
 
This module implements VRML97-parser handler for the
loader module.  The parser is provided by the
vrml.vrml97 module.  Of particular interest to the
end-developer is the standardPrototype function, which
allows you to register prototypes as standard features
for your VRML97 files.
 
By default, the standard prototype namespace is the
union of:
    vrml.vrml97.basenodes and
    OpenGLContext.scenegraph.basenodes
 
with prototypes from the second replacing those in the
first.

 
Modules
       
OpenGLContext.loaders.base
vrml.vrml97.basenamespaces
OpenGLContext.scenegraph.basenodes
vrml.vrml97.linearise
logging
vrml.node
vrml.vrml97.nodetypes
vrml.vrml97.parseprocessor
vrml.vrml97.parser
vrml.protofunctions
threading
urllib

 
Classes
       
BaseHandler(object)
VRML97Handler

 
class VRML97Handler(BaseHandler)
    Handler for loading VRML97-encoded scenegraphs
 
This is a load handler for the loader module which
will be instantiated by the load or loads function
in order to handle the result of downloading/opening
a VRML97-encoded file.
 
The prototypes argument is normally a pointer to
the STANDARD_PROTOTYPES namespace, so that prototype
registration during downloading will be available
during parsing.
 
 
Method resolution order:
VRML97Handler
BaseHandler
object

Methods defined here:
__init__(self, prototypes)
Initialise the file-handler
 
prototypes -- prototype namespace provided by the
    vrml.protonamespace package
parse(self, data, baseURL, *args, **named)
Parse the loaded data (with the provided meta-information)

Class methods defined here:
dump(cls, node, file) from type
Dump node's representation to a VRML97-formatted file
dumps(cls, node) from type
Dump node's representation to a VRML97 string

Data and other attributes defined here:
LOCK = <_RLock owner=None count=0>
filename_extensions = ['.wrl', '.wrl.gz', '.wrz', '.vrml', '.vrml.gz']

Methods inherited from BaseHandler:
__call__(self, baseURL, filename, file, *args, **named)
Load encoded scenegraph from the file
 
baseURL -- the URL from which the file was loaded
filename -- the local filename for the file
file -- open read-only file handle
 
Returns a scenegraph or None
getData(self, baseURL, filename, file)
Retrieve data to be parsed
 
Will handle gunzipping data which has .gz extension

Class methods inherited from BaseHandler:
gunzip(cls, file) from type
Get a gzip-aware file for the given file handle
isGzip(cls, file) from type
Determine whether the data is a gzip stream

Data descriptors inherited from BaseHandler:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
Functions
       
defaultHandler()
Produce a default handler object
 
This is registered in the setup.py as the entry point for this plug-in
standardPrototype(prototype, key)
Make the given prototype available as a standard prototype
 
What this means is that VRML97 files loaded
with this module will be able to access the prototype
without needing to declare a PROTO within the
file.
 
The name registered is the result of protofunctions.name
for the prototype.

 
Data
        STANDARD_PROTOTYPES = {'Anchor': <class 'vrml.vrml97.basenodes.Anchor'>, 'Appearance': <class 'OpenGLContext.scenegraph.appearance.Appearance'>, 'AudioClip': <class 'vrml.vrml97.basenodes.AudioClip'>, 'Background': <class 'OpenGLContext.scenegraph.background.Background'>, 'Billboard': <class 'OpenGLContext.scenegraph.billboard.Billboard'>, 'Box': <class 'OpenGLContext.scenegraph.box.Box'>, 'Collision': <class 'OpenGLContext.scenegraph.collision.Collision'>, 'Color': <class 'vrml.vrml97.basenodes.Color'>, 'ColorInterpolator': <class 'OpenGLContext.scenegraph.interpolators.ColorInterpolator'>, 'Cone': <class 'OpenGLContext.scenegraph.quadrics.Cone'>, ...}
__file__ = '/home/mcfletch/pylive/OpenGLContext/loaders/vrml97.pyc'
__name__ = 'OpenGLContext.loaders.vrml97'
__package__ = 'OpenGLContext.loaders'
_parser = <simpleparse.parser.Parser object>
key = 'FloatUniform1f'
log = <logging.Logger object>
name = 'FloatUniform1f'