Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsSupportedExt ¶
IsSupportedExt checks if a file extension is a supported audio format.
params:
ext: file extension including the dot (e.g. ".mp3")
returns:
bool
TODO: replace hardcoded format resolver with accurate tag
Types ¶
type TrackMeta ¶
type TrackMeta struct {
Path string `json:"path"`
Title string `json:"title"`
Artist string `json:"artist"`
Album string `json:"album"`
Format string `json:"format"`
CoverData []byte `json:"-"` // raw cover art bytes (JPEG/PNG), excluded from JSON
}
func ResolveTrack ¶
ResolveTrack reads metadata from a single audio file.
params:
path: absolute path to the audio file
returns:
TrackMeta: populated metadata (falls back to filename if tags are missing)
func ScanFolder ¶
ScanFolder reads a directory and returns metadata for all supported audio files.
params:
folder: absolute path to the music directory
returns:
[]TrackMeta: metadata for each audio file found
error
Click to show internal directories.
Click to hide internal directories.