![]() |
MAC-flake transcoding scripts
Hi there,
when downloading lossless albums copies from the ed2k I often notice that these copies are encoded with the Monkey's Audio (APE) codec. My problem was that MAC isn't well supported on Linux (BSD, Unix, etc.) because the license isn't GPL and the author doesn't seem to interested in having a broad support of operating systems. So in the past I always transcoded the APE file to wave via foobar2k (run through wine) and after that processing the WAVs with flac-1.1.2. Since flac-1.1.4 came out I wanted to test it but the package wasn't marked stable in my distribution (gentoo linux). I knew however that the Windows binary was stable and wrote some scripts for automatic encoding with verification and so on (also using wine). The tagging was done manually with foobar2k (I often change the style of tags, because I have my own system). Now I had some free time and I was rather unsatisfied with the use of closed source software to transcode the music. So I decided to look for alternatives. I found the flake compressor which encodes to FLAC, but better than the reference 1.1.4 encoder. Sadly it doesn't have a verification mode. The next thing was to get some MAC decoding tool. I found JMAC, a MAC decoding (and encoding) tool that was implemented in Java. I wrapped some (tiny) bash script around it so I could use it for decoding. Now the problem was that the lossless copies always came with just one large APE file and the corresponding cuesheet indicating the start- and endpoints of the track. I already had the possibility to decode from APE to WAV, only splitting was the problem. For this I use the cuetools together with shntool, some general audio tool first written for use with the shorten codec. Now here the scripts: mac_decode.sh Code:
#!/bin/sh flac_encode.sh Code:
#!/bin/sh mac_transcode.sh Code:
#!/bin/sh Some very good lossless score.ape Some very good lossless score.cue I finished writing the scripts yesterday and tested them with the 2 disc Prometheus Cutthroat Island release and they produce identical results when using foobar2k. Only thing that is lacking is maybe the transfer of the tags. Since I do this manually (see above) I don't intend to write anything for that. Could be easily done with apetag and metaflac. EDIT: 1) The jmac decoder could be easily exchanged with the mac-port tool floating around on the net. It was taken down from sf.net by the author, so I don't know if there are some legal problems. Maybe mac-port is facter when decoding, but I'm not sure. At least jmac works for me. 2) The destination codec can also be easily exchanged if someone wants to encode to TAK, which should give much better compression ratio than flac with nearly same decompression speed. |
All times are GMT -5. The time now is 12:54 AM. |
Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2025, vBulletin Solutions, Inc.