Commit graph

238 commits

Author SHA1 Message Date
Roderick van Domburg e1b273b8a1
Fix lyrics retrieval 2021-11-27 08:30:51 +01:00
Roderick van Domburg d19fd24074
Add spclient and HTTPS support
* Change metadata to use spclient
 * Add support for HTTPS proxies
 * Start purging unwraps and using Result instead
2021-11-26 23:28:37 +01:00
Roderick van Domburg 7cd1b7a26a
Merge branch 'dev' into new-api-client 2021-06-26 00:14:20 +02:00
Roderick van Domburg 7d27b94cfb
Document new unknown packet 0xb6 2021-06-25 23:56:17 +02:00
Roderick van Domburg e58934849f
Fix clippy warnings 2021-06-23 21:43:23 +02:00
Roderick van Domburg aa4cc0bee6
Ignore known but unused packets 2021-06-23 21:26:52 +02:00
Roderick van Domburg 12365ae082
Fix comment 2021-06-22 23:58:35 +02:00
Roderick van Domburg 0703630041
Use PacketType instead of hex identifiers 2021-06-22 23:57:38 +02:00
Roderick van Domburg 4fe1183a80
Fix compilation on Rust 1.48 2021-06-22 21:54:50 +02:00
Roderick van Domburg d3074f597a
Remove keymaster and update example 2021-06-22 21:49:36 +02:00
Roderick van Domburg 3a7843d049
Fix refilling with proxies and a race condition 2021-06-22 21:39:38 +02:00
Roderick van Domburg eee79f2a1e
Introduce caching ApResolver component 2021-06-21 23:49:37 +02:00
Roderick van Domburg b6357a27a5
Store token_type and simplify scopes argument 2021-06-21 23:48:53 +02:00
Roderick van Domburg 15628842af
Introduce HTTP client 2021-06-20 23:09:27 +02:00
Roderick van Domburg ce4f8dc288
Remove superfluous status check 2021-06-20 20:45:15 +02:00
Roderick van Domburg e1e265179f
Document known token scopes 2021-06-20 20:40:33 +02:00
Roderick van Domburg 850db43254
Add token provider 2021-06-19 23:46:48 +02:00
Roderick van Domburg 6244515879
Resolve dealer and spclient access points (#795) 2021-06-10 22:24:40 +02:00
Roderick van Domburg 7c975f8ed0
Remove feature gate around apresolve 2021-06-01 20:43:23 +02:00
Roderick van Domburg ad19b69bfb
Various code improvements (#777)
* Remove deprecated use of std::u16::MAX
* Use `FromStr` for fallible `&str` conversions
* DRY up strings into constants
* Change `as_ref().map()` into `as_deref()`
* Use `Duration` for time constants and functions
* Optimize `Vec` with response times
* Move comments for `rustdoc` to parse
2021-05-31 22:32:39 +02:00
johannesd3 3be50fd90f
Corrected documentation 2021-05-27 17:20:49 +02:00
Johannesd3 7ed35396f8
Mostly cosmetic changes in dealer (#762)
* Add missing timeout on reconnect

* Cosmetic changes
2021-05-27 15:33:29 +02:00
johannesd3 049bcf616f
Fix integer overflow in spotify_id 2021-05-27 15:29:36 +02:00
Roderick van Domburg 3a2455d686
Merge branch 'dev' into log-volume-ctrl-optimisations 2021-05-26 20:50:42 +02:00
Roderick van Domburg d8ec98015c
Merge pull request #673 from Johannesd3/discovery-crate
Create separate discovery crate
2021-05-26 20:21:43 +02:00
johannesd3 1ade02b7ad
Add basic websocket support 2021-05-26 16:51:13 +02:00
Johannesd3 28dd842e05 Fix bug in MercurySender 2021-05-24 16:31:34 +02:00
Roderick van Domburg eca505c387
Improve volume controls
This is a squashed commit featuring the following:

Connect:
- Synchronize player volume with mixer volume on playback
- Fix step size on volume up/down events
- Remove no-op mixer started/stopped logic

Playback:
- Move from `connect` to `playback` crate
- Make cubic volume control available to all mixers with `--volume-ctrl cubic`
- Normalize volumes to `[0.0..1.0]` instead of `[0..65535]` for greater precision and performance (breaking)
- Add `--volume-range` option to set dB range and control `log` and `cubic` volume control curves
- Fix `log` and `cubic` volume controls to be mute at zero volume

Alsa mixer:
- Complete rewrite (breaking)
- Query card dB range for the `log` volume control unless specified otherwise
- Query dB range from Alsa softvol (previously only from hardware)
- Use `--device` name for `--mixer-card` unless specified otherwise
- Fix consistency for `cubic` between cards that report minimum volume as mute, and cards that report some dB value
- Fix `--volume-ctrl {linear|log}` to work as expected
- Removed `--mixer-linear-volume` option; use `--volume-ctrl linear` instead
2021-05-24 15:53:32 +02:00
Johannesd3 ebea5397b9
Add librespot-discovery crate 2021-05-19 21:05:19 +02:00
johannesd3 68818758a2
Add timeout to test 2021-05-18 15:17:30 +02:00
johannesd3 041f084d7f Fix warnings 2021-05-13 22:42:55 +02:00
johannesd3 1c62af9160
Unpin protobuf version 2021-05-08 22:09:37 +02:00
Sasha Hilton 3cd5ef32c4 Merge branch 'dev' 2021-05-04 13:16:39 +01:00
Sasha Hilton 7570241d86 Change wildcard env_logger dependency to version 0.8 2021-05-04 13:16:16 +01:00
Sasha Hilton 2ef3928691 Update version numbers to 0.2.0 2021-05-04 13:05:13 +01:00
johannesd3 1681574846
Bump hmac and pbkdf2 2021-05-01 10:53:14 +02:00
johannesd3 ddf41a49f2
Update lower version bound for some deps 2021-05-01 10:40:52 +02:00
Sasha Hilton 9d5ac1b156
Merge pull request #699 from Johannesd3/ready-macro
Use `ready!` macro to reduce boilerplate
2021-05-01 01:25:14 +01:00
johannesd3 de6bc32dea
Add documentation, logging and tests 2021-04-21 11:29:32 +02:00
johannesd3 e9dc9cd839
Add size limit to cache 2021-04-21 11:29:08 +02:00
johannesd3 7d6267c0a2
Use ready macro to reduce boilerplate 2021-04-17 12:23:24 +02:00
johannesd3 4c2fc61d64 Better joining of session tasks 2021-04-12 22:54:32 +02:00
johannesd3 690e0d2e10 Add simple tests to librespot-core
The first test checks whether apresolve works. A second test tries
to create a Spotify sessions with fake credentials and asserts that
an error is returned.
2021-04-10 12:50:30 +02:00
johannesd3 e688e7e886 Almost eliminate util module 2021-04-10 12:50:30 +02:00
johannesd3 9378ae5b6f Bump num-bigint dependency 2021-04-09 22:39:51 +02:00
johannesd3 11ce29077e Fix formatting 2021-04-09 10:45:48 +02:00
johannesd3 7c3d89112d Fix clippy warnings 2021-04-09 10:45:43 +02:00
johannesd3 f5274f5ada Merge branch 'dev' into tokio_migration 2021-04-09 10:39:06 +02:00
Ash d4dfd4890f
Merge pull request #674 from Johannesd3/proxy-support
[Tokio migration] Add back hyper-proxy
2021-03-29 21:00:18 +02:00
johannesd3 95fedf5357 Add back hyper-proxy 2021-03-27 15:36:33 +01:00