mirror of https://bitbucket.org/ausocean/av.git
Trying to get it to build
This commit is contained in:
parent
94a9f8fe77
commit
79710f27f6
|
@ -30,28 +30,29 @@ package h264FileToRtmpTest
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"bitbucket.org/ausocean/av/revid"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
inputFile = "bitbucket.org/ausocean/test/test-input/av/betterInput.h264"
|
inputFile = "bitbucket.org/ausocean/test/test-input/av/betterInput.h264"
|
||||||
rtmpUrl = "rtmp://a.rtmp.youtube.com/live2/w44c-mkuu-aezg-ceb1"
|
rtmpUrl = "rtmp://a.rtmp.youtube.com/live2/v70c-qu3x-2bs4-esek"
|
||||||
frameRate = "25"
|
frameRate = "25"
|
||||||
runDuration = 120 * time.Second
|
runDuration = 120 * time.Second
|
||||||
)
|
)
|
||||||
|
|
||||||
// Test h264 inputfile to flv format into rtmp using librtmp c wrapper
|
// Test h264 inputfile to flv format into rtmp using librtmp c wrapper
|
||||||
func TestRtmpOutputUsingLibRtmp(t *testing.T) {
|
func TestRtmpOutputUsingLibRtmp(t *testing.T) {
|
||||||
config := Config{
|
config := revid.Config{
|
||||||
Input: File,
|
Input: revid.File,
|
||||||
InputFileName: inputFile,
|
InputFileName: inputFile,
|
||||||
InputCodec: H264,
|
InputCodec: revid.H264,
|
||||||
Output: Rtmp,
|
Output: revid.Rtmp,
|
||||||
RtmpMethod: LibRtmp,
|
RtmpMethod: revid.LibRtmp,
|
||||||
RtmpUrl: rtmpUrl,
|
RtmpUrl: rtmpUrl,
|
||||||
Packetization: Flv,
|
Packetization: revid.Flv,
|
||||||
FrameRate: frameRate,
|
|
||||||
}
|
}
|
||||||
revidInst, err := NewRevidInstance(config)
|
revidInst, err := revid.New(config)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Errorf("Should not of have got an error!: %v\n", err.Error())
|
t.Errorf("Should not of have got an error!: %v\n", err.Error())
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in New Issue