简体   繁体   English

是否可以从 Spotify 应用程序访问歌曲的波形?

[英]Is possible to acces the waveform of a song from a spotify app?

I am thinking on how to build an spotify app that does beat detection (extract bpm of a song).我正在考虑如何构建一个可以进行节拍检测(提取歌曲的 bpm)的 Spotify 应用程序。 For that I need to access the raw audio, the waveform, and analyze it.为此,我需要访问原始音频、波形并对其进行分析。

I am new to building spotify apps.我是构建 Spotify 应用程序的新手。 I know that with "libspotify" you can access raw audio.我知道使用“libspotify”可以访问原始音频。 Can you do the same through the spotify apps API?你能通过 Spotify 应用程序 API 做同样的事情吗? And how?如何?

For the record, currently exist two spotify apps apis:作为记录,目前存在两个 Spotify 应用程序 api:

Unless you're really keen on writing that beat detection code yourself, you should look at the APIs provided by the EchoNest , which include that (and many other awesome things).除非您真的很想自己编写节拍检测代码,否则您应该查看EchoNest提供的 API,其中包括它(以及许多其他很棒的东西)。

see Getting the tempo, key signature, and other audio attributes of a song请参阅获取歌曲的速度、调号和其他音频属性

In a word: no.一句话:没有。 That isn't currently available in the Apps API.目前在 Apps API 中不可用。

There's a new endpoint I guess.我猜有一个新的端点。 See an example https://medium.com/swlh/creating-waveforms-out-of-spotify-tracks-b22030dd442b?source=linkShare-962ec94337a0-1616364513查看示例https://medium.com/swlh/creating-waveforms-out-of-spotify-tracks-b22030dd442b?source=linkShare-962ec94337a0-1616364513

That uses the endpoint https://developer.spotify.com/documentation/web-api/reference/tracks/get-audio-analysis/使用端点https://developer.spotify.com/documentation/web-api/reference/tracks/get-audio-analysis/

Edit: I agree with commenter @wizbcn that this does not answer this question.编辑:我同意评论者@wizbcn 的观点,即这不能回答这个问题。 Is it sort of incorrect to leave it here because I found this SO post while searching for info about visualizing the tack's waveform as in the linked article?将它留在这里是否有点不正确,因为我在搜索有关链接文章中有关可视化大头钉波形的信息时发现了这篇 SO 帖子? Maybe I should make this a comment instead?也许我应该把它作为评论?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM