1
# Copyright 2007 Joe Wreschnig
3
# This program is free software; you can redistribute it and/or modify
4
# it under the terms of the GNU General Public License version 2 as
5
# published by the Free Software Foundation
7
# $Id: spc.py 4047 2007-04-30 03:49:58Z piman $
13
from formats._audio import AudioFile
17
if gst.registry_get_default().find_plugin("spcdec") is None:
20
class SPCFile(AudioFile):
21
format = "SPC700 DSP Data"
23
def __init__(self, filename):
25
self.sanitize(filename)
27
def sanitize(self, filename):
28
super(SPCFile, self).sanitize(filename)
29
self["title"] = os.path.basename(self["~filename"])[:-4]
34
def can_change(self, k=None):
35
if k is None: return ["artist"]
36
else: return k == "artist"