Start READMEs

This commit is contained in:
Sean DuBois 2022-09-20 23:09:04 -04:00
parent 38e75cb5cf
commit 59ab961a93
2 changed files with 64 additions and 0 deletions

28
README.md Normal file
View file

@ -0,0 +1,28 @@
<h1 align="center">
<br>
Opus
<br>
</h1>
<h4 align="center">Pure Go implementation of the Opus Codec</h4>
<p align="center">
<a href="https://pion.ly"><img src="https://img.shields.io/badge/pion-opus-gray.svg?longCache=true&colorB=brightgreen" alt="Opus"></a>
<a href="https://pion.ly/slack"><img src="https://img.shields.io/badge/join-us%20on%20slack-gray.svg?longCache=true&logo=slack&colorB=brightgreen" alt="Slack Widget"></a>
<br>
<a href="https://pkg.go.dev/github.com/pion/opus"><img src="https://godoc.org/github.com/pion/opus?status.svg" alt="GoDoc"></a>
<a href="https://codecov.io/gh/pion/opus"><img src="https://codecov.io/gh/pion/opus/branch/master/graph/badge.svg" alt="Coverage Status"></a>
<a href="https://goreportcard.com/report/github.com/pion/opus"><img src="https://goreportcard.com/badge/github.com/pion/opus" alt="Go Report Card"></a>
<a href="LICENSE"><img src="https://img.shields.io/badge/License-MIT-yellow.svg" alt="License: MIT"></a>
</p>
<br>
This package provides a Pure Go implementation of the [Opus Codec](https://opus-codec.org/)
### Why Opus?
### Why Opus in Go?
### Running
### Get Involved!
### Roadmap

36
examples/decode/README.md Normal file
View file

@ -0,0 +1,36 @@
# decoder
decoder demonstrates decoding a ogg file and saving the results to a single file
## Instructions
### Install decoder
Download and install the decoder
```
go install github.com/pion/opus/examples/decoder@latest
```
### Create a ogg file to decode
Encode Opus into an ogg file, or use one that you already have. This implementation doesn't
support most Opus features yet, so encoding will be constrained.
```
ffmpeg -i $INPUT_FILE -c:a libopus -ac 1 -b:a 10K output.ogg
```
### Decode
Demux and decode the provided `ogg` file. The output audio samples will be saved to disk.
```
decoder `pwd`/output.ogg `audio-samples.pcm`
```
### Play your audio
Now play the audio with the tool of your choice.
```
gst-launch-1.0 filesrc location=pion-out ! audio/x-raw, format=F32LE, rate=16000,channels=1 ! autoaudiosink -v
```
```
ffplay -f f32le -ar 16000
```