334 Commits

Author SHA1 Message Date
Deluan
9e79b5cbf2 Fix potential SQL injection in Smart Playlists 2022-01-18 21:36:29 -05:00
Deluan
0714f08274 Recover from SIGSEGVs in taglib's code 2021-11-20 12:33:06 -05:00
Deluan
cbeaadf8e2 Fix logging smart playlist's song count 2021-11-20 12:29:09 -05:00
Deluan
48a627885c Simplify prototype definition for taglib_read 2021-11-13 12:18:42 -05:00
Deluan
f645c4769c Fix double escaped lyrics and comments 2021-10-26 19:33:21 -04:00
Deluan
cc1659aa73 Better way to match top songs from external sources (Last.fm) 2021-10-23 20:26:30 -04:00
Deluan
2c860edeb5 Don't import invalid .nsp files 2021-10-23 20:25:28 -04:00
Deluan
1a96e9fe65 Import smart playlists (extension .nsp) 2021-10-23 20:25:28 -04:00
Deluan
c72add516a Add methods to Playlist model
Also, don't load genres for Playlists tracks (not necessary for now)
2021-10-23 20:25:28 -04:00
Deluan
174ad9e9da Fix ffmpeg bitrate parsing for flac files 2021-10-12 22:02:24 -04:00
Deluan
f0c11916ca Revert: Small optimization in genre mapping 2021-10-04 17:28:45 -04:00
Deluan
73a2271cdd Small optimization in genre mapping 2021-09-21 13:37:44 -04:00
Samarjeet
0c0bd2967d
Replace expanded with a dialog (#1258)
* Replace expanded with a dialog

* Change `info` label to "Get Info"

* Rename things for consistency

Co-authored-by: Deluan <deluan@navidrome.org>
2021-09-20 20:30:43 -04:00
Deluan
15ae3d47cf Only apply audioStreamRx once 2021-09-20 19:33:50 -04:00
Deluan
1365adbb39 Support 7.1 (8) channels 2021-09-20 19:33:50 -04:00
Miguel A. Arroyo
e12a14a87d feat: Adds Audio Channel Metadata - #1036 2021-09-20 19:33:50 -04:00
Deluan
86479a6d06 More info when recovering from panic 2021-09-20 18:16:22 -04:00
Deluan
76bd20e8ff Recover from any possible taglib panics. Fixes #1343 2021-09-20 18:09:39 -04:00
Deluan
ab2912b4fa Only import playlists from configured paths in option PlaylistsPath. Closes #1181
Syntax is Ant-style Globs, with support for '**' (any subfolder). Default: '.:**' (or '.;**' in Windows`, meaning all folders and subfolders under `MusicFolder`
2021-09-12 21:07:51 -04:00
caiocotts
54f98497c2
Use wchar_t for TagLib filenames on Windows (#1310)
* Use wchar_t for tagLib filenames on Windows

* Make TagLib default extractor for all platforms.

* Organize imports

Co-authored-by: Deluan <deluan@navidrome.org>
2021-08-28 19:35:54 -04:00
Deluan
d481864035 Some small refactorings 2021-08-22 12:16:49 -04:00
Deluan
143f5ba9d5 Import song duration with hundredths when using TagLib
This is how ffmpeg extractor currently works, and it makes album durations more precise.
2021-08-20 21:42:01 -04:00
caio
e9d0abe0bc Support local paths as urls in playlists. 2021-08-02 23:53:47 -04:00
Deluan
b66c39451f Fix build 2021-07-24 11:45:46 -04:00
Deluan
4ed01bad86 Use ffmpeg extractor by default on Windows
This is to avoid issue with unicode chars in filenames. See #810
2021-07-24 11:35:49 -04:00
Deluan
d3975d206a Reorganize metadata extractors code 2021-07-24 11:10:19 -04:00
Deluan
6c550819fd Use TagLib to detect whether a media file has embedded cover or not 2021-07-24 01:59:53 -04:00
Deluan
91325071a6 Change fallback extractor to taglib, the default option 2021-07-22 23:08:47 -04:00
Deluan
876dda83f2 Reduce number of calls to lstat.
Should make the scanner a bit faster, specially in networked filesystems
2021-07-21 22:17:37 -04:00
Deluan
8afa2cd833 Remove dependency of deprecated ioutil package 2021-07-20 20:12:28 -04:00
Deluan
2742977c63 Fix multiple id3v2.4 genres appearing as one big concatenated genre 2021-07-20 17:45:08 -04:00
Deluan
69f71be98a Add more tests 2021-07-20 17:45:08 -04:00
Deluan
3a356499ae Fix lint error 2021-07-20 17:45:08 -04:00
Deluan
39da741a80 Add multiple genres to MediaFile 2021-07-20 17:45:08 -04:00
Deluan
7cd3a8ba67 Add genre tables, read multiple-genres from tags 2021-07-20 17:45:08 -04:00
Deluan
882b02c747 Fix forceRescan not re-importing all tracks 2021-07-19 10:32:33 -04:00
Deluan
e61cf3217d Reapply the fix from #1054, but without getting into an infinite look in case of SMB fs errors. See #1164 2021-07-17 21:06:53 -04:00
Deluan
eb8ffc6f76 Fix infinite loop when the fs fails. Closes #1164 2021-07-16 09:38:58 -04:00
Deluan
8d56ec898e Use AlbumArtist tag even for compilations, when it is specified.
If the tracks' AlbumArtists are different, then use "Various Artists"
2021-07-15 11:53:08 -04:00
Deluan
5bd33455a1 Fix deadlock situation when events are sent too fast to the broker 2021-07-01 10:42:00 -04:00
Deluan
b65e76293a Only send events to clients who need it
- User events (star, rating, plays) only sent to same user
- Don't send to the client (browser window) that originated the event
2021-06-15 18:59:26 -04:00
Deluan
667701be02 Less warning messages when first running it.
They are actually `info` messages
2021-06-13 19:27:01 -04:00
Deluan
7f85ecd515 Trigger a UI refresh when the scanner finds changes.
Closes #1025
2021-06-09 21:02:20 -04:00
Deluan
9da9d73c1d Don't panic when taglib returns an error 2021-05-31 18:26:46 -04:00
Deluan
cd242695ba Foundational work to enable multi-valued tags 2021-05-31 18:08:12 -04:00
Deluan
fa0e6dda5b Remove C++11 warning in macOS 2021-05-14 16:03:11 -04:00
Deluan
e047008f7d Fix test 2021-05-14 15:38:28 -04:00
Deluan
3cac00ad13 Upgrade TagLib to 1.12 2021-05-14 14:31:07 -04:00
Deluan
f8dbc41b6d Breaking change: Add ScanSchedule, allows interval and cron based configurations.
See https://pkg.go.dev/github.com/robfig/cron#hdr-CRON_Expression_Format for expression syntax.

`ScanInterval` will still work for the time being. The only situation it does not work is when you want to disable periodic scanning by setting `ScanInterval=0`. If you want to disable it, please set `ScanSchedule=""`

Closes #1085
2021-05-06 17:56:10 -04:00
Brian Schrameck
30bb3f7b43
BPM metadata enhancement (#1087)
* BPM metadata enhancement

Related to #1036.

Adds BPM to the stored metadata about MediaFiles.

Displays BPM in the following locations:
- Listing songs in the song list (desktop, sortable)
- Listing songs in playlists (desktop, sortable)
- Listing songs in albums (desktop)
- Expanding song details

When listing, shows a blank field if no BPM is present. When showing song details, shows a question mark.

Updates test MP3 file to have BPM tag. Updated test to ensure tag is read correctly.

Updated localization files. Most languages just use "BPM" as discovered during research on Wikipedia. However, a couple use some different nomenclature. Spanish uses PPM and Japanese uses M.M.

* Enhances support for BPM metadata extraction

- Supports reading floating point BPM (still storing it as an integer) and FFmpeg as the extractor
- Replaces existing .ogg test file with one that shouldn't fail randomly
- Adds supporting tests for both FFmpeg and TagLib

* Addresses various issues with PR #1087.

- Adds index for BPM. Removes drop column as it's not supported by SQLite (duh).
- Removes localizations for BPM as those will be done in POEditor.
- Moves BPM before Comment in Song Details and removes BPM altogether if it's empty.
- Omits empty BPM in JSON responses, eliminating need for FunctionField.
- Fixes copy/paste error in ffmpeg_test.
2021-05-05 21:35:01 -04:00