Incoming RSPT stream

Yossi

New Member
Hi! I new to this server and I'm using Web Call Server 5 trial version.
I'm trying to send my stream as rtsp to the server using ffmpeg.
My command line is:
ffmpeg -loglevel verbose -re -i music.m4a -c:a aac -ac 2 -ar 48000 -b:a 96K -f rtsp -rtsp_transport tcp rtsp://server-ip:554/live/test.sdp

And I'm getting an error:
method ANNOUNCE failed: 501 Not Implemented

In Flashphoner logs I see (this is the only line that were written for this session):
11:48:42,502 WARN RTSPServerHandler - RTSP-pool-32-thread-12 Received unknown rtsp request ANNOUNCE

I'll appreciate your help here.
Thanks
Yossi
 

Max

Administrator
Staff member
FFmpeg is supported for streaming RTMP
Please try this way
Code:
ffmpeg -re -i music.m4a -ar 48000 -acodec aac -strict -2 -f flv rtmp://server-ip:1935/live/stream
 

Yossi

New Member
And, when publishing rtmp with audio only, I can't play it with WebRTC.

Source video codecs (video.mp4): h264, aac 2 channels, 44100Hz

Can play: ffmpeg -re -i video.mp4 -c:a copy -c:v copy -f flv rtmp://3.235.251.44:1935/live/stream
Can not play: ffmpeg -re -i video.mp4 -c:a copy -vn -f flv rtmp://3.235.251.44:1935/live/stream

Thanks!
 

Max

Administrator
Staff member
Known, but I want to use pulse audio codec which is not supported by rtmp.
WCS supports the following codecs for publishing:
1611632901322.png

Can play: ffmpeg -re -i video.mp4 -c:a copy -c:v copy -f flv rtmp://3.235.251.44:1935/live/stream
Can not play: ffmpeg -re -i video.mp4 -c:a copy -vn -f flv rtmp://3.235.251.44:1935/live/stream
To play audio only stream in browser, you should use constraints:
Code:
session.createStream({
    name: streamName,
    display: remoteVideo,
    constraints: {
           video: false,
           audio: true
    }
    ...
}).play();
Please check this in Media Devices example by disabling "Play video" check box
1611633203182.png
 

Yossi

New Member
Thanks!
I'm still need to publish rtsp to WCS because I want to pass opus codec, see my first post here.

ffmpeg -loglevel verbose -re -i music.m4a -c:a libopus -ac 2 -ar 48000 -b:a 96K -f rtsp -rtsp_transport tcp rtsp://WSC-server-ip:554/live/test

Returns:
[rtsp @ 000001b9b19ef440] method ANNOUNCE failed: 501 Not Implemented
 

Max

Administrator
Staff member
I'm still need to publish rtsp to WCS because I want to pass opus codec, see my first post here.
WCS does not support RTSP publishing now. You can pull H264+Opus RTSP stream from other server as described here.
If you'are using m4a file as source, there is probably AAC audio inside, so you can stream it to WCS as RTMP and (if this is audio only stream) play it in browser with constraints as mentioned here. The audio will be transcoded from AAC to Opus at server side.
 

Max

Administrator
Staff member
We raised the ticket WCS-1595 to implement RTSP interleaved publishing, but this is not a priority feature.
 

Max

Administrator
Staff member
Good day.
Since build 5.2.902 it is possible to publish RTP stream via RTSP directly to WCS using ffmpeg
Code:
ffmpeg -stream_loop -1 -re -i bunny360p.mp4 -c:a libopus -ac 2 -ar 48000 -c:v copy -b:a 96K -b:v 500K -f rtsp -rtsp_transport tcp rtsp://test1.flashphoner.com:554/test
Please read the details here.
 
Top