hey plone devs,
while analyzing the collective.flowplayer code i came across the hachoir
library which is used by p4a.video for metadata parsing of binary files.
the hachoir [1] library handles much more file types (e.g. mp4) than the
FLVHeader parser implementation in collective.flowplayer.flv.
i've created an development branch on my github site [2] (no discussion
about using github for development branches, please) where the hachoir
library is used (besides a minor code cleanup).
is there any reason why the hachoir library isn't used by collective
flowplayer?
one thing against hachoir might be that it's slower than the FLVHeader
implementation. i've written a test (test_metadata_profiling) which
tracks the time for parsing the barsandtones.flv file found in the tests
package of c.flowplayer (it's not a unittest in the correct sense). the
results on my machine are:
- FLVHeader: about 0.00053 seconds
- Hachoir: about 0.06162 seconds
so FLVHeader is much faster. but in my opinion this might not be a
problem for c.flowplayer since parsing flvfiles doesn't happen too
often.
if you use mr.developer and want to try out my branch, just add the
following to the appropriate places in your buildout config:
"""
[buildout]
always-checkout = true
auto-checkout +=
collective.flowplayer
[sources]
collective.flowplayer = git
git://github.com/thet/collective.flowplayer.git
"""
[1] http://pypi.python.org/pypi/hachoir-metadata
[2] http://github.com/thet/collective.flowplayer
_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers