- About metaguru
- Running the program
- Sample output
- Port to other platforms
- Known bugs and limitations
- Copyright
- Download
- Release Notes
About metaguru
First, thanks and apologies to Marc Bolan for the inspiration for the name.
metaguru came out of a problem I had diagnosing MP3 indexing and cataloguing problems I was having, particularly with the Sonos music system. I was using various tag editors and ripping programs but they were all using different terms to report the tags created. What I needed was a program that would look at the file (not modify it) and report exactly what was there. Hence metaguru came about. Since those days it has expanded and it now supports Windows Media Audio (wma), flac, tar and JPEG image files.
The program is open source and command line only. At present I have compiled a MacOS X (Intel) version, and now a Windows version (as a CMD tool), but I know it works on other Unix systems.
The full list of what it currently supports is…
- mp3
- ID3v1 & v1.1 TAG structure
- TAG+ extensions to ID3v1 (not tested)
- ID3v2.2 frames [added v1.3]
- ID3v2.3 & 2.4 frames
- APE v2 keys [supported from v1.1]
- LYRICS3 blocks v1 & v2 (not tested)
- embedded JPEG images
- wma
- ASF v1 objects
- ASF v2 objects when discovered
- FLAC native files (not ogg containers yet) [v1.2]
- embedded JPEG images
- jpg
- JFIF markers
- Exif markers
- SOF0 markers
- tar [added in v1.3]
- embedded files of any of the above types
Running the program
The program is a command line system, no GUI I'm afraid, but it is very simple.
metaguru filename.ext
If you fail to enter the file name then it will prompt:—
Enter command : filename.ext
This will produce output to the screen—lots of it. For convenience you can redirect it to a file to look at using a more convenient viewer.
metaguru filename.ext > filename.txt
Optionally specify verbose output.
metaguru -v filename.ext
it is a pretty verbose listing but if you want even more add another "-v" (that is -v -v not -vv). You will almost certainly need to redirect this output.
Sample output
brecon:metaguru rick$ ./metaguru 07* Processing 07 J'ai Été Au Bal.mp3 MPEG (MP3) file start ID3v2.3 tag TLEN {175853} TPE1 {Eddie LeJeune} TALB {Cajun Soul} TPE2 {Eddie LeJeune} TIT2 {J'ai \00c9t\00e9 Au Bal} TPUB {Rounder} TRCK {7} TSSE {LAME 32bits version 3.98.2 (http://www.mp3dev.org/)} TYER {1988} TDRC {1988} RGAD Peak: 0.523865, Track Gain (DJMR algorithm) -0.9, Volume Gain (DJMR algorithm) -0.1 TXXX {replaygain_track_gain} = {0.91 dB} TXXX {replaygain_track_peak} = {0.523865} TXXX {replaygain_album_gain} = {0.12 dB} ID3v1 tag Track : {J'ai ?t? Au Bal} Artist : {Eddie LeJeune} Album : {Cajun Soul} Year : {1988} Comment: { } Track #: 7 Genre : 255 Statistics Data Frames: 6735 Running time: 2m 55.110s Average bitrate: 220kbps (vbr) File length: 5242880bytes MPEG (MP3) file end brecon:metaguru rick$and verbose
brecon:metaguru rick$ ./metaguru -v 07* metaguru v1.0 MP3 file: 07 J'ai Été Au Bal.mp3 Frame header <0x49443303> ID3v2.3 tag, Revision: 0, Flags: <0x00>, Length: 2134 TLEN [Length (ms)] Length: 7, Flags: <0x4000>, ASCII{175853} TPE1 [Lead performers(s)/soloist(s)] Length: 14, Flags: <0x0000>, ASCII{Eddie LeJeune} TALB [Album/movie/show title] Length: 11, Flags: <0x0000>, ASCII{Cajun Soul} TPE2 [Band/orchaestra/accompaniment] Length: 14, Flags: <0x0000>, ASCII{Eddie LeJeune} TIT2 [Title/songname/content description] Length: 33, Flags: <0x0000>, UTF-16(+BOM){J'ai \00c9t\00e9 Au Bal} TPUB [Publisher] Length: 8, Flags: <0x0000>, ASCII{Rounder} TRCK [Track number/position in set] Length: 2, Flags: <0x0000>, ASCII{7} TSSE [Software/hardware and settings used for encoding] Length: 52, Flags: <0x0000>, ASCII{LAME 32bits version 3.98.2 (http://www.mp3dev.org/)} TYER [Year (yyyy)] Length: 5, Flags: <0x0000>, ASCII{1988} TDRC [Recording time] Length: 5, Flags: <0x0000>, ASCII{1988} RGAD [Replay gain adjustment] Length: 8, Flags: <0x4000>, Length: 8 bytes <0x000000002e1b0000> TXXX [User defined text information] Length: 31, Flags: <0x0000>, ASCII{replaygain_track_gain} = ASCII{-2.70 dB} Padding 1814 bytes Frame header <0xfffb9064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 128k, Frame Length: 417, Frequency: 44.1kHz, Flags: <0x0064> Frame header <0xfffb1064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 32k, Frame Length: 104, Frequency: 44.1kHz, Flags: <0x0064> Frame header <0xfffb1064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 32k, Frame Length: 104, Frequency: 44.1kHz, Flags: <0x0064> Frame header <0xfffb1064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 32k, Frame Length: 104, Frequency: 44.1kHz, Flags: <0x0064> Frame header <0xfffb1064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 32k, Frame Length: 104, Frequency: 44.1kHz, Flags: <0x0064> Frame header <0xfffb1064> Data frame, mpg-i layer III, Err. prot.: off, Bit Rate: 32k, Frame Length: 104, Frequency: 44.1kHz, Flags: <0x0064> and lots more like this... ID3v1 tag Track : {J'ai ?t? Au Bal} Artist : {Eddie LeJeune} Album : {Cajun Soul} Year : {1988} Comment: { } Track #: 7 Genre : 255 End of file Statistics Data Frames: 6735 Running time: 2m 55.110s Average bitrate: 220kbps (vbr)
Port to other platforms
Porting should be pretty straight forward. The code should compile just as it is on any Unix or Linux system. For Windows there is one line to change at the top of the main file (commented). Then you just need to compile it. The C compiler on MacOS X comes as part of the free xcode package, the Windows compiler I used is part of the MinGW system.
brecon:metaguru rick$ cc -o metaguru twrapper.c metaguru.c
The wrapper is mainly there for Windows systems and allows you to drop files onto the application icon or double click it and a prompt window is displayed. It also pauses at the end before closing the window so you can read the output.
Known bugs and limitations
- It gets an "Abort Trap" after the end of the program with some very long files.
- It has very limited testing; only with files I have come across.
Contact information can be found on my Home Page.
Copyright
Copyright ©2010 Rick Parsons, Bristol, England.
This software is published Open Source Freeware. You are free to use the programs either in full or part without charge. I would ask however that this notice is included with any extract or onward distribution.
No charge may be made for the use of this code, however there is no objection to including modest extracts (with acknowledgement) in otherwise commercial software.
No warranty is given or implied by the use of the software which you do at your own risk. No compensation can be considered regarding damage to data, computers or any thing else arising as a result of using these programs.
Download
The zip file contains the full source code and executables for MacOS X (Intel) and Windows.
13 Jan 2017—Version 1.5
metaguru.zip (110K)
Unzip the files into any convenient location.
Release Notes
V1.0—Initial release.
V1.1—Add support for Ape v2 keys and add frame offsets for easier diagnosis of problems
V1.2—Add support for native FLAC audio files.
V1.3—Add support for tar files and multiple inputs. System made fully recursive e.g. tar with mp3 with jpeg. Multiple verbose levels. Cleaner output. ID3v2.2 tags.
V1.3.1—Fix bug in ID3v2.2 & add some iTunes Podcast tags.
V1.4—Add support for RGAD tag and compile for Windows.
V1.4.1—Add support for COMM iTunNORM and fix unsynchronisation.
V1.4.2—Add support for ID3 extended header and footer.
V1.4.3—Support long file names.
V1.4.4—Add support for COMM iTunSMPB.
V1.4.5—Allow for file names containing '.' (thanks Igor for spotting this)
v1.4.6 - Fix MPEG-i Layer II decoding
v1.4.7 - Print some Hex data with ascii transcription to make it more readable
v1.5 - Add support for USLT frame