Page MenuHomePhabricator

Support Ogg metadata in image:img_metadata
Closed, ResolvedPublic


Author: avarab

As well as exif metadata for JPEG images Ogg metadata should be supported,
however implementing this won't be as easy as exif for numerous reasons:

  • There's no standard libary for it, we could use File_Ogg (see but it's in beta state currently,
alternetively we could parse the raw output from ogginfo(1)

  • We can't use img_type to determine that it's an Ogg file which should be

parsed, we could fall back to anything with an .ogg extension

Version: 1.5.x
Severity: enhancement



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 8:18 PM
bzimport set Reference to bz1948.
bzimport added a subscriber: Unknown Object (MLST).

avarab wrote:

I tried mucking around with the Ogg::Vorbis::Header::PurePerl Perl module and it
works very well, time to make Vorbis.php that parses the output of a custom

avarab wrote:

An Ogg tag reader using Ogg::Vorbis::Header::PurePerl;

This is an Ogg Vorbis tag reader using Ogg::Vorbis::Header::PurePerl, I think
the best way to support Ogg metadata currently is to use something like this,
the php implementations seem to be really immature.

We could just use STDIN and STDOUT to communicate with the program:

$ ./ogginf jly.ogg
title = Just Like You Imagined
artist = Nine Inch Nails
album = The Fragile - Left Disc
tracknumber = 7
encodedby = Ari
genre = Industrial
date = 1999
bitrate_upper = 0
framing_flag = 1
channels = 2
version = 0
blocksize_0 = 4096
blocksize_1 = 512
rate = 44100
length = 229
bitrate_nominal = 224963
bitrate_window = -1
bitrate_lower = 0
offset = 304


I think this is pretty much being done in the OggHandler extension...

OggHandler extension stores OGG metadata.