Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 11:00
    SuisChan opened #945
  • 05:21
    JasonLG1979 commented #942
  • 05:18
    JasonLG1979 commented #942
  • 05:15
    JasonLG1979 synchronize #942
  • 02:10
    JasonLG1979 synchronize #942
  • Jan 24 20:11
    JasonLG1979 commented #942
  • Jan 24 18:58
    SuisChan commented #944
  • Jan 24 16:52
    JasonLG1979 commented #942
  • Jan 24 15:20
    JasonLG1979 commented #942
  • Jan 24 13:16
    SuisChan commented #944
  • Jan 24 13:11
    roderickvd commented #944
  • Jan 24 13:09
    roderickvd commented #944
  • Jan 24 13:07
    roderickvd commented #942
  • Jan 24 13:06
    SuisChan commented #944
  • Jan 24 13:04
    JasonLG1979 commented #942
  • Jan 24 12:51
    roderickvd commented #944
  • Jan 24 12:50
    SuisChan commented #944
  • Jan 24 12:48
    roderickvd commented #942
  • Jan 24 12:47

    roderickvd on dev

    examples/playlist_tracks: Use n… Merge pull request #929 from jf… (compare)

  • Jan 24 12:47
    roderickvd closed #929
Roderick van Domburg
@roderickvd
@JasonLG1979 no reason other than it was all slapped on historically. So definitely room for improvement. I’m not sure having a global buffer fixes that. We pretty much already have one, that’s the AudioPacket::Samples that’s mutated all the time. The real solution would be a Sample<T>pipeline that I mentioned in an earlier issue.
Roderick van Domburg
@roderickvd
First reduction looks in order. Second one I need more coffee for. Honestly I think either will save one or two CPU ops? Not saying that won’t help but in the scope of things.
Jason Gray
@JasonLG1979
It's not really about saving CPU cycles it's about the most simplified equation being potenti
*potentially the easiest for people to understand
Roderick van Domburg
@roderickvd
In that case I’d leave it as is, because these formulas are exactly the ones found in the AES article if anyone tries to understand and look it up.
Jason Gray
@JasonLG1979
I will have to read the paper more carefully. I find it hard to believe that a paper was submitted with un-simplified equations?
Roderick van Domburg
@roderickvd
The paper is attached to the original PR if you want to see. You are finding opportunities to reduce the equations because they are now chained / substituted where the paper specifies them block-by-block.
Roderick van Domburg
@roderickvd
Hey @devgianlu cool to see you implementing more HTTP endpoints in librespot-java! What does the client-token do, is that necessary to access those endpoints?
Florian
@heeen:matrix.highteq.net
[m]
hmm
I can't choose librespot running on my windows box from my linux box
but I can choose librespot on my linux box from spotify on my windows box
[2022-01-19T09:25:26Z ERROR libmdns::fsm] ResponderRecvPacket Error: Os { code: 10040, kind: Uncategorized, message: "A message sent on a datagram socket was larger than the internal message buffer or some other network limit, or the buffer used to receive a datagram into was smaller than the datagram itself." }
maybe related?
SuisChan
@SuisChan_gitlab

Hey @devgianlu cool to see you implementing more HTTP endpoints in librespot-java! What does the client-token do, is that necessary to access those endpoints?

This isn't necessary if you are mimic an android lite app, otherwise client-token is required to access the API.

Abhay
@AbhayAysola
Hi, quick question about the protocol described here - https://github.com/librespot-org/librespot/wiki/Connection, after the client solves the challenge and sends a ClientResponsePlaintext, does the server return anything or does the client just directly begin authentication?
2 replies
Roderick van Domburg
@roderickvd

Hey @devgianlu cool to see you implementing more HTTP endpoints in librespot-java! What does the client-token do, is that necessary to access those endpoints?

This isn't necessary if you are mimic an android lite app, otherwise client-token is required to access the API.

Thanks. And the Authentication-Token still too, I suppose?

Vincent Ulitzsch
@viniul:matrix.org
[m]

Hello All,

I want to contribute to spotify-connect projects and try to find a good point to get started. I would have two questions so far:

  1. Is there a general overview of the spotify-connect protocols where I could read up on the protocol?
  2. Do I understand correctly that there is a discovery phase which searches for the devices in the local network, but after that, the devices communicate with the spotify server themself?
SuisChan
@SuisChan_gitlab

Hey @devgianlu cool to see you implementing more HTTP endpoints in librespot-java! What does the client-token do, is that necessary to access those endpoints?

This isn't necessary if you are mimic an android lite app, otherwise client-token is required to access the API.

Thanks. And the Authentication-Token still too, I suppose?
Which Authentication-Token are you talking about? Bearer or...?

Roderick van Domburg
@roderickvd
Yeah Bearer.
Roderick van Domburg
@roderickvd
Hi Vincent, we'd be glad to have you!
  1. There is some documentation in the docs directory of course but reading the source code of librespot and the more up-to-date librespot-java in that regard brings you the most.
  2. Yes, discovery is mDNS / zeroconf which on client connection gets the authentication credentials, then instantiates what's in connect and that's what talks with Spotify. You can run connect even without discovery by supplying the credentials yourself.
  3. What are parts you are interested in to contribute? Depending on where you're at with Rust you might want to check up on librespot-org/librespot#917 and see what's on the list. Something like the lyrics metadata structs, or the futures-related stuff to refresh the CDN URL's might be fun points to dive in.
Vincent Ulitzsch
@viniul:matrix.org
[m]
Hey @roderickvd -- Thank you very much! The link does not work for me, could you send it again maybe?
Roderick van Domburg
@roderickvd
Oh yeah, it's a discussion and not an issue. https://github.com/librespot-org/librespot/discussions/917
Vincent Ulitzsch
@viniul:matrix.org
[m]
Thank you, I will take a look
Vincent Ulitzsch
@viniul:matrix.org
[m]
Regarding point 2: So the reason that the standard spotify client listens on various tcp/udp ports on the local network is only for the discovery mDNS/zeroconf protocol? Or are there any other protocols that are used in the local network?
SuisChan
@SuisChan_gitlab

Yeah Bearer.

Required anyway, and also may be obtained through login5 endpoint

Roderick van Domburg
@roderickvd
No other protocols. From there on the client talks to the Spotify servers, so does librespot, and the Spotify servers act like a broker.
That's why you can control Spotify Connect devices remotely even from a totally different network as long as they are logged in.
Abhay
@AbhayAysola
Hi, I was wondering about the restriction of only Premium Accounts. It doesn't seem like it is enforced by Spotify since https://github.com/kokarare1212/librespot-python/ works with free accounts as well.
Roderick van Domburg
@roderickvd
In that case they should also enforce ads, content and quality restrictions and limited skips. So we won't support it not only because of dev time to do that, but also because we want to stay on Spotify's good side and have librespot users support Spotify and their artists financially.
devgianlu
@devgianlu

Hey @devgianlu cool to see you implementing more HTTP endpoints in librespot-java! What does the client-token do, is that necessary to access those endpoints?

Not entirely sure, I just started from the first endpoint requested when starting up with clear cache.

Abhay
@AbhayAysola

In that case they should also enforce ads, content and quality restrictions and limited skips. So we won't support it not only because of dev time to do that, but also because we want to stay on Spotify's good side and have librespot users support Spotify and their artists financially.

Ah, that makes sense, imo good decision to keep it that way.

Abhay
@AbhayAysola
Also, question about the roadmap for librespot. Is it planned to implement all the features which are present in librespot-java like the api and such?
Roderick van Domburg
@roderickvd
We don’t really have a roadmap. Things are being worked on by volunteers as they like and usually scratches their own itch. Myself I don’t plan to work on the external playback control API that librespot-java offers, but I’ll certainly accept contributions for it.
Abhay
@AbhayAysola

We don’t really have a roadmap. Things are being worked on by volunteers as they like and usually scratches their own itch. Myself I don’t plan to work on the external playback control API that librespot-java offers, but I’ll certainly accept contributions for it.

Alright that makes sense. So if I understand correctly, the new-api branch is focussed on implementing the same api as the one in librespot-java?

Roderick van Domburg
@roderickvd
Yes and no. You could say there are two API’s. One is the interface to and from the Spotify servers. That is the scope of new-api (amongst other improvements) and mostly ported from librespot-java. The other API is the one offered by librespot-java to let others control its own playback. That’s not being worked on for librespot.
Abhay
@AbhayAysola
So the library here - https://github.com/librespot-org/librespot-java/tree/dev/lib will be implemented but the API here - https://github.com/librespot-org/librespot-java/tree/dev/api will not? Sorry if I'm bombarding you with too many questions, I want to contribute and just trying to get an idea about the state of the project.
Roderick van Domburg
@roderickvd
That seems about right.
At least as far as my work is concerned, again, if anyone else wishes to take it up then I’d certainly welcome that.
Which area are you interested in to contribute to?
Abhay
@AbhayAysola
Not sure, I'm still a beginner at rust, so probably not much I could do but I will definitely take a look at something that looks interesting :D
Roderick van Domburg
@roderickvd
When you look at the new-api discussion, removing the few unsafe parts or doing the deserialization of the lyrics JSON may be fun starting points and getting to know Rust too.
Abhay
@AbhayAysola
Cool, thanks for the pointer, will surely check those out. Excited to contribute :)
Roderick van Domburg
@roderickvd
:+1: welcome
Roderick van Domburg
@roderickvd

As far as I remember it doesn't work

Oh I thought you said you tried with g++

And do PR in which branch, dev or new-api? Or it doesn't matter

To dev is fine I think? We can merge to new-api. Unless that's too much work, then please directly to new-api.

I know playplay-decryptor definitely works under Linux, but what about Mac? I didn't check

I can try later.

nadigo
@nadigo
I am trying to use the pipe device and I'm having multiple issues:
1) there is a known bug that the pulling speed of the pipe will force the player to pull the audio stream too fast and lose sync (that can be mitigated by adding a buffer 'dd status=none iflag=fullblock bs=1024' - still working on a good mbuffer setting for that)
2) I get 'white noise' when I try to use the stream with a native raop_play player https://github.com/philippe44/RAOP-Player (the player works well with other raw streams)
Can someone explain what is the full PCM details of the pipe raw output? What would be the best strategy to convert the output raw just for audio? let's say I want to convert it to AAC, or better off ALAC (apple's RAOP).
What I try to achieve is an 'always-on' docker endpoint that will stream a 'mult-room' setup of airplay speakers on-demand aka only when sound is detected (have a look here -https://github.com/nadigo/airspot)
SuisChan
@SuisChan_gitlab

I know playplay-decryptor definitely works under Linux, but what about Mac? I didn't check

I can try later.

Would be nice

Roderick van Domburg
@roderickvd
@nadigo 1) is not a bug but by design. It's up to the receiving end to block or throttle if it wants to. 2) the PCM stream by default is 16-bit signed integer, 44.1 kHz, 2-channel interleaved stereo. You can use --format to set something other than S16.
Have you looked at JACK Audio for what you're trying to do? Also I know moOde has multi-room audio support, I haven't looked into how they did that.