Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Single metadata interface? #7

Open
slimsag opened this issue Oct 1, 2014 · 3 comments
Open

Single metadata interface? #7

slimsag opened this issue Oct 1, 2014 · 3 comments
Assignees

Comments

@slimsag
Copy link
Contributor

slimsag commented Oct 1, 2014

I do not know for sure yet, but I imagine most audio files share similar metadata that we could provide a single interface to within the audio package.

@slimsag slimsag self-assigned this Oct 1, 2014
@mdlayher
Copy link
Contributor

mdlayher commented Oct 1, 2014

I actually was going to request this feature, if you mean metadata in the form of tags, sample rate, bitrate, etc.

I actually did some work on a native Go tagging package, and I'd be happy to contribute what I've learned! https://github.com/mdlayher/taggolib

@slimsag
Copy link
Contributor Author

slimsag commented Oct 1, 2014

I actually was going to request this feature, if you mean metadata in the form of tags, sample rate, bitrate, etc.

This issue would be just about metadata tags (i.e. author, title, track number, etc).

For bitrate I've made #8.

For sample rate and number of channels you can just look at the decoder's configuration:

dec, _, err := audio.NewDecoder(r)
handle(err)

conf := dec.Config()
fmt.Println("Sample Rate: %d Channels: %d\n", conf.SampleRate, conf.Channels)

@mdlayher
Copy link
Contributor

mdlayher commented Oct 1, 2014

Cool! Yeah, metadata tags would be perfect. Vorbis tags, at least, are very easy to parse. ID3 is a lot less sane.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants