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

i am not able to record the media #55

Open
punitmundra opened this issue Dec 30, 2019 · 2 comments
Open

i am not able to record the media #55

punitmundra opened this issue Dec 30, 2019 · 2 comments

Comments

@punitmundra
Copy link

this is my code
var incomingStream *mediaserver.IncomingStream
var outgoingStream *mediaserver.OutgoingStream

		for _, stream := range offer.GetStreams() {
			//var record *mediaserver.Recorder
			//record := mediaserver.NewRecorder("30jan", false, 0)

			incomingStream = transport.CreateIncomingStream(stream)
			outgoingStream = transport.CreateOutgoingStream(stream.Clone())

			outgoingStream.AttachTo(incomingStream)
			//record.RecordStream(outgoingStream)

			answer.AddStream(outgoingStream.GetStreamInfo())
		}

		ws.WriteJSON(Message{
			Cmd: "answer",
			Sdp: answer.String(),
		})

		record := mediaserver.NewRecorder("30jan", true, 0)
		record.RecordStream(incomingStream)

i am getting an error

[0x7fb9ac1d3700][1577729629.864][LOG]-DTLSConnection::SetRemoteSetup() | [remote:2]
[0x7fb9ac1d3700][1577729629.864][LOG]>DTLSConnection::Init()
[0x7fb9ac1d3700][1577729629.864][LOG]<DTLSConnection::Init()
[0x7fb9ac1d3700][1577729629.865][LOG]-DTLSICETransport::AddIncomingSourceGroup() [mid:'',rid:'',ssrc:1720278854,fec:0,rtx:0]
[0x7fb9ac1d3700][1577729629.865][LOG]-RemoteRateEstimator adding stream [ssrc:1720278854]
[0x7fb9ac1d3700][1577729629.865][LOG]-DTLSICETransport::AddIncomingSourceGroup() [mid:'',rid:'',ssrc:3228106187,fec:0,rtx:346119931]
[0x7fb9ac1d3700][1577729629.865][LOG]-RemoteRateEstimator adding stream [ssrc:3228106187]
[0x7fb9ac1d3700][1577729629.865][LOG]-DTLSICETransport::AddOutgoingSourceGroup() [group:0x7fb9a4016360,ssrc:1720278854,fec:0,rtx:0]
[0x7fb9ac1d3700][1577729629.865][LOG]-DTLSICETransport::AddOutgoingSourceGroup() [group:0x7fb9a4015400,ssrc:3228106187,fec:0,rtx:346119931]
[0x7fb9ac1d3700][1577729629.866][LOG]-MP4Recorder::Create() Opening mp4 recording [30jan]
[0x7fb9a986e700][1577729629.926][LOG]-DTLSConnection::onSSLInfo() | DTLS handshake done
[0x7fb9a986e700][1577729629.926][LOG]-DTLSICETransport::onDTLSSetup() [suite:1]
[0x7fb9a986e700][1577729629.926][LOG]-DTLSICETransport::SetLocalCryptoSDES() | [suite:AES_CM_128_HMAC_SHA1_80]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:1720278854,OK]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:3228106187,OK]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:346119931,OK]
[0x7fb9a986e700][1577729629.926][LOG]-DTLSICETransport::SetRemoteCryptoSDES() | [suite:AES_CM_128_HMAC_SHA1_80]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:1720278854,OK]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:3228106187,OK]
[0x7fb9a986e700][1577729629.926][LOG]-SRTPSession::AddStream() | [ssrc:346119931,OK]
OnDTLSStateChange 2
[0x7fb9a986e700][1577729629.957][LOG]-MP4Recorder::Stop()
[0x7fb9a986e700][1577729629.973][LOG]-MP4Recorder::Stop()
[0x7fb9a986e700][1577729629.994][LOG]-MP4Recorder::Stop()
[0x7fb9a986e700][1577729630.009][LOG]-MP4Recorder::Stop()
[0x7fb9a986e700][1577729630.035][LOG]-MP4Recorder::Stop()
[0x7fb9a986e700][1577729630.050][LOG]-MP4Recorder::Stop()

@punitmundra
Copy link
Author

Any update on recording ?

@a48772986
Copy link

a48772986 commented Apr 28, 2021

I have the same problem,and i find it's Compilation problems

image

this is no {} after for loop
and i set {} after for loop
image

and run swig -go -c++ -cgo -intgosize 64 mediaserver.i

rebuild demo
Code executed correctly

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