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

Problem in Playing recorded streams #317

Open
ahmedkhak opened this issue Jun 29, 2015 · 2 comments
Open

Problem in Playing recorded streams #317

ahmedkhak opened this issue Jun 29, 2015 · 2 comments

Comments

@ahmedkhak
Copy link

I am unable to play recorded videos. What we are are doing is we are recording videos on page "room.php" and save video name and url in DB. When user access recording.html then user play its videos. I am using that code for video playback

var createToken = function(userName, role, callback)
{
callback();
};

createToken("user", "presenter", function (response) 
    {
    var token = response;
    room = Erizo.Room({token: "eyJ0b2tlbklkIjoiNTU5MTJjOWZmZmQ1ZjExMzA2MzI0YmI1IiwiaG9zdCI6Ijc4LjEzNy45Ni4yMTY6ODA4MCIsInNlY3VyZSI6ZmFsc2UsInNpZ25hdHVyZSI6IlpUaG1NbVJpWW1VNE9HVXlaakEzTnpFMU9XSmtNakEwTkRSalpqZzJOek5qTVRNeE5XRm1Ndz09In0="}); 

    var stream = Erizo.Stream({video: true, audio: false, recording: "http://78.137.96.216:3001/recordFiles/203557275468483550.mkv"});
    room.publish(stream);
    });

But it give an error in console which is

Uncaught TypeError: a.socket.emit is not a function. Plz help

@lodoyun
Copy link
Contributor

lodoyun commented Jun 30, 2015

That url is not right.
As seen here, you have to use either the id that was generated when recording or the actual path to the file where licode is installed and recorded the file (should be "file:///path/to/the/file.mkv")

@ahmedkhak
Copy link
Author

Okay so i tried to play file using recording id, it gives no error in console and do not play any video just display black screen

var stream2 = Erizo.Stream({audio:true, video:true, recording: '751057150308042800',attributes: {name:"playing"}});
room.publish(stream2);

I use that code, and debug information which is shown in console is

erizo.js:161 DEBUG: Event: stream-added
erizo.js:161 INFO: Subscribing to: 823187613626942100
erizo.js:161 INFO: Subscribing to: 309197848429903360
erizo.js:161 INFO: Subscribing to: 885017883963882900
erizo.js:161 INFO: Subscribing to: 312544808490201860
erizo.js:161 INFO: Subscribing to: 100134832086041570
erizo.js:161 INFO: Subscriber added
erizo.js:161 DEBUG: Stable!
erizo.js:161 INFO: Sending message Object {type: "offer", sdp: "v=0
↵o=- 875932325593038991 2 IN IP4 127.0.0.1
↵s=…90000
↵a=rtpmap:96 rtx/90000
↵a=fmtp:96 apt=100
↵"}
erizo.js:116 Set remote and local description v=0
o=- 0 0 IN IP4 127.0.0.1
s=LicodeMCU
t=0 0
a=group:BUNDLE audio video
a=msid-semantic: WMS UJLMVrzfhR
m=audio 1 RTP/SAVPF 0 126
c=IN IP4 0.0.0.0
a=rtcp:1 IN IP4 0.0.0.0
a=candidate:1 1 udp 2013266431 78.137.96.216 37233 typ host generation 0
a=ice-ufrag:7Q+j
a=ice-pwd:T9oE9J6ryEL1mTPvvJuyBY
a=fingerprint:sha-256 B4:CA:9A:EA:F7:05:B8:68:14:80:B6:E4:86:B7:38:BB:F0:3E:8B:E7:2C:CC:EA:A0:F0:B5:EA:67:B6:47:49:B6
a=sendonly
a=mid:audio
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=rtcp-mux
a=rtpmap:0 PCMU/8000
a=rtpmap:126 telephone-event/8000
a=maxptime:60
a=ssrc:32745 cname:o/i14u9pJrxRKAsu
a=ssrc:32745 msid:UJLMVrzfhR a0
a=ssrc:32745 mslabel:UJLMVrzfhR
a=ssrc:32745 label:UJLMVrzfhRa0
m=video 1 RTP/SAVPF 100 116 117
c=IN IP4 0.0.0.0
a=rtcp:1 IN IP4 0.0.0.0
a=candidate:1 1 udp 2013266431 78.137.96.216 37233 typ host generation 0
a=ice-ufrag:7Q+j
a=ice-pwd:T9oE9J6ryEL1mTPvvJuyBY
a=extmap:2 urn:ietf:params:rtp-hdrext:toffset
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=fingerprint:sha-256 B4:CA:9A:EA:F7:05:B8:68:14:80:B6:E4:86:B7:38:BB:F0:3E:8B:E7:2C:CC:EA:A0:F0:B5:EA:67:B6:47:49:B6
a=sendonly
a=mid:video
a=rtcp-mux
a=rtpmap:100 VP8/90000
a=rtcp-fb:100 ccm fir
a=rtcp-fb:100 nack
a=rtcp-fb:100 nack pli
a=rtcp-fb:100 goog-remb
a=rtpmap:116 red/90000
a=rtpmap:117 ulpfec/90000
a=ssrc:2069462296 cname:o/i14u9pJrxRKAsu
a=ssrc:2069462296 msid:UJLMVrzfhR v0
a=ssrc:2069462296 mslabel:UJLMVrzfhR
a=ssrc:2069462296 label:UJLMVrzfhRv0

erizo.js:116 Candidates to be added: 0 []
erizo.js:116 Local candidates to send: 0
erizo.js:161 INFO: Stream subscribed
erizo.js:161 DEBUG: Event: stream-subscribed
erizo.js:161 DEBUG: Creating URL from stream [object MediaStream]
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:161 INFO: Sending message Object {type: "candidate", candidate: Object}
erizo.js:112 End of candidates.

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