Brian Paul wrote:
> 
> Keith Whitwell wrote:
> >
> > I'm committing my initial implementation of the CVA extension as I write
> > this email.
> 
> CVA = compiled vertex arrays, for those of you who may be wondering.
> It's an extension introduced by SGI which lets the developer give
> hints to indicate that vertex array data won't change between draws.
> 
> > Also noteworthy are:
> >         - new runtime config file (/etc/mesa.conf)
> 
> Interesting idea.  What's the syntax?  When is it read?

Lisp-like because it is arbitarily extensible and very easy to parse.

The file consists of a number of clauses each of the form

(config-mesa <name> <list of configurations>)

Implemented configurations are:
        (default-hint HINT VALUE)
        (disable-extension EXTENSION-STRING)

More can be easily added, and if necessary even higher level conditional
constructs should be quite simple.

By default the configuration with the same name as the version of mesa
is executed.  If the environment variable MESA_CONFIG is present, mesa
will use that configuration instead.  Thus I do something like
'MESA_CONFIG=quake2 ./quake2'.

Because mesa is often run as root, I have hardcoded the pathname
/etc/mesa.conf.  

The file is read after the context is created, by a callback from the
driver.  This is a little contorted, but hard to avoid because we want
to have all the extensions and other 'normal' initializations done
before the config file is read.

Keith

Reply via email to