Open dgcampea opened 1 year ago
case-insensitive systems.
What does that mean?
MPD supports standards-compliant CUE sheets, and they mandate that FILE is all-uppercase. CUE sheets that use lower case are not standards compliant and thus ill-formed, and will not be supported by MPD.
MPD supports standards-compliant CUE sheets, and they mandate that FILE is all-uppercase. CUE sheets that use lower case are not standards compliant and thus ill-formed, and will not be supported by MPD.
Do you mean the FILE
directive itself or must the value of FILE
itself also be uppercase? (i.e. FILE "FOO.WAV"
)
AFAIK the values do accept lowercase names, at least the file extension can be lowercase as seen below.
Over here, I'm experiencing different behavior for .cue files that are embedded in a ZIP file.
This doesn't work: Listing of foo.zip:
Foo/
Foo/Foo.cue
Foo/Foo.flac
First lines of Foo.cue:
PERFORMER "Foo"
TITLE "FOO"
FILE "FOO.flac" WAVE
...
This works: Listing of bar.zip:
Bar/
Bar/Bar.cue
Bar/01-track.flac
Bar/02-track.flac
...
First lines of Bar.cue:
TITLE "Bar"
FILE "01 - track.flac" WAVE
TRACK 01 AUDIO
TITLE "Track A"
INDEX 01 00:00:00
TRACK 02 AUDIO
TITLE "Track B"
INDEX 00 04:13:60
FILE "02 - track.flac" WAVE
INDEX 01 00:00:00
TRACK 03 AUDIO
TITLE "Track C"
INDEX 00 04:28:07
FILE "03 - track.flac" WAVE
...
MPD version: 0.23.11
$ mpd --version
Music Player Daemon 0.23.11 (0.23.11)
Copyright 2003-2007 Warren Dukes <warren.dukes@gmail.com>
Copyright 2008-2021 Max Kellermann <max.kellermann@gmail.com>
This is free software; see the source for copying conditions. There is NO
warranty; not even MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Database plugins:
simple proxy upnp
Storage plugins:
local udisks nfs curl
Neighbor plugins:
upnp udisks
Decoders plugins:
[mad] mp3 mp2
[mpg123] mp3
[vorbis] ogg oga
[oggflac] ogg oga
[flac] flac
[opus] opus ogg oga
[sndfile] wav aiff aif au snd paf iff svx sf voc w64 pvf xi htk caf sd2
[audiofile] wav au aiff aif
[dsdiff] dff
[dsf] dsf
[hybrid_dsd] m4a
[faad] aac
[wavpack] wv
[openmpt] mptm mod s3m xm it 669 amf ams c67 dbm digi dmf dsm dtm far imf ice j2b m15 mdl med mms mt2 mtm nst okt plm psm pt36 ptm sfx sfx2 st26 stk stm stp ult wow gdm mo3 oxm umx xpk ppm mmcmp
[modplug] 669 amf ams dbm dfm dsm far it med mdl mod mtm mt2 okt s3m stm ult umx xm
[mikmod] amf dsm far gdm imf it med mod mtm s3m stm stx ult uni xm
[sidplay] sid mus str prg P00
[wildmidi] mid
[fluidsynth] mid
[ffmpeg] 16sv 3g2 3gp 4xm 8svx aa3 aac ac3 adx afc aif aifc aiff al alaw amr anim apc ape asf atrac au aud avi avm2 avs bap bfi c93 cak cin cmv cpk daud dct divx dts dv dvd dxa eac3 film flac flc fli fll flx flv g726 gsm gxf iss m1v m2v m2t m2ts m4a m4b m4v mad mj2 mjpeg mjpg mka mkv mlp mm mmf mov mp+ mp1 mp2 mp3 mp4 mpc mpeg mpg mpga mpp mpu mve mvi mxf nc nsv nut nuv oga ogm ogv ogx oma ogg omg opus psp pva qcp qt r3d ra ram rl2 rm rmvb roq rpl rvc shn smk snd sol son spx str swf tak tgi tgq tgv thp ts tsp tta xa xvid uv uv2 vb vid vob voc vp6 vmd wav webm wma wmv wsaud wsvga wv wve rtp:// rtsp:// rtsps://
[pcm]
Filters:
libsamplerate soxr
Tag plugins:
id3tag
Output plugins:
shout null fifo pipe alsa ao oss openal pipewire pulse jack httpd snapcast recorder
Encoder plugins:
null vorbis opus lame twolame wave flac
Archive plugins:
[bz2] bz2
[zzip] zip
[iso] iso
Input plugins:
file io_uring archive alsa qobuz curl ffmpeg nfs mms cdio_paranoia
Playlist plugins:
extm3u m3u pls xspf asx rss soundcloud flac cue embcue
Protocols:
file:// alsa:// cdda:// ftp:// ftps:// gopher:// hls+http:// hls+https:// http:// https:// mms:// mmsh:// mmst:// mmsu:// nfs:// qobuz:// rtmp:// rtmpe:// rtmps:// rtmpt:// rtmpte:// rtmpts:// rtp:// rtsp:// rtsps:// scp:// sftp:// smb:// srtp://
Other features:
avahi dbus udisks epoll icu inotify ipv6 systemd tcp un
After issuing mpc rescan <path to album>
update: removing Music/Foo.zip/Foo/Foo.flac
update: added Music/Foo.zip/Foo/Foo.flac
Snippets below are added to mpd.conf through include <file.conf>
# Reads CUE sheets from the CUESHEET tag of song files.
playlist_plugin {
name "embcue"
enabled "false"
}
# Reads the cuesheet metablock from a FLAC file.
playlist_plugin {
name "flac"
enabled "false"
}
playlist_plugin {
name "soundcloud"
enabled "false"
}
resampler {
plugin "libsamplerate" # Best Sinc Interpolator | Band limited sinc interpolation, best quality, 97dB SNR, 96% BW.
type "0"
}
# problem is that this breaks DSD playback! (slowmotion)
#resampler {
# plugin "soxr"
# quality "very high"
# threads "0"
# precision "32"
#}
database {
plugin "simple"
path "~/.local/state/mpd/database"
cache_directory "~/.local/share/mpd/cache"
hide_playlist_targets "yes"
}
Do you mean the
FILE
directive itself or must the value ofFILE
itself also be uppercase
What did you mean? Your feature request was ambiguous, but apparently ou meant the value (the actual file name), not the directive. But I don't think MPD should support that; that would require scanning the whole directory each time a CUE sheet gets loaded. Instead of doing that, you can better switch the Linux kernel to be case insensitive.
But I don't think MPD should support that; that would require scanning the whole directory each time a CUE sheet gets loaded. Instead of doing that, you can better switch the Linux kernel to be case insensitive.
I've looked a bit into this and unfortunately only some of the filesystems in Linux can be made case-insensitive (NFS isn't one of them). Some suggest that this task would be easier to accomplish from the application side if the FS doesn't natively support this.
Feature request
Allow cuesheet FILE directive to be case-insensitive, to interoperate with cuesheets that were originally created on case-insensitive systems.
For consistency, FILE should first match with case-sensitivity and then fallback to non case-sensitive match. This feature could be made into a mpd.conf setting under the
cue
playlist plugin to give some control over whether it should be enabled or not.