[vorbis-dev] Re: [vorbis] Finally, it can be told!

Ignacio Vazquez-Abrams ignacio at openservices.net
Fri Aug 31 15:57:51 PDT 2001



First of all, I must apologize; I haven't actually had time to try out
vorbis-python, I've just looked through the source.

On Fri, 31 Aug 2001, Andrew Chatham wrote:

>  [snip]
> which looks a bit easier to me, and if it matches an existing API for Python,
> that's good too. Comment reading in simple cases is probably easier in his,
> too, whereas mine has this weird dictionary of tuples thing that has raised a
> few questions but is the most correct way I can think of doing it.

There's no "pretty" way to do it; point 5 under the subsection "Implications"
of the section "Content vector format" of the document "Ogg Vorbis comment
field specification" pretty much makes certain of that.

My implementation also uses a "dictionary of tuples" as follows:

{'artist':('Dizzy Gillespie', 'Sonny Rollins', 'Sonny Stitt')}

I couldn't think of any more efficient structure for it:


---
c=t.getcomments()
for i in c['artist']:
  print 'Artist: %s' % i
---

Question: the comment specification talks about the field name being
case-insensitive. Does that mean that vorbisenc or vorbisfile munges them to a
given case, or does that mean that the code using the comments has to?

> It probably wouldn't be very hard to implement most of this in actual Python
> script on top of the existing modules, which seems to be how many Python
> modules go about doing things. Or if there are specific advantages of his C
> functions, those could be merged into the existing modules, or he can just keep
> doing it on his own, which is cool too.

While I agree that layering the modules is possible, I feel that audio
requires high speed for certain applications, e.g., games. IMHO, layering is
fine if all you want to do is fling bits around willy-nilly (e.g., a CL
player) and then having multiple layers is not a problem. Anything where
synchronization is required needs to be "close to the metal". My module is the
API used by Python's existing modules brought close to the metal.

My code isn't perfect, but I will complete the implementation of the
encoding/writing half, as well as apply bugfixes and make improvements to
existing code.

If it is felt that merging vorbismodule into the current set has no value,
then I have no problem continuing to maintain it as a seperate package.

-- 
Ignacio Vazquez-Abrams  <ignacio at openservices.net>

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.




More information about the Vorbis-dev mailing list