FS-7500: fix play_fsv for WebRTC
This commit is contained in:
parent
dcb9d3c99e
commit
ba43facf91
|
@ -306,8 +306,6 @@ SWITCH_STANDARD_APP(play_fsv_function)
|
||||||
switch_frame_t *read_frame;
|
switch_frame_t *read_frame;
|
||||||
switch_codec_implementation_t read_impl = { 0 };
|
switch_codec_implementation_t read_impl = { 0 };
|
||||||
|
|
||||||
switch_channel_set_flag(channel, CF_VIDEO_PASSIVE);
|
|
||||||
|
|
||||||
switch_core_session_refresh_video(session);
|
switch_core_session_refresh_video(session);
|
||||||
|
|
||||||
switch_core_session_get_read_impl(session, &read_impl);
|
switch_core_session_get_read_impl(session, &read_impl);
|
||||||
|
@ -351,7 +349,8 @@ SWITCH_STANDARD_APP(play_fsv_function)
|
||||||
vid_frame.data = vid_buffer + 12;
|
vid_frame.data = vid_buffer + 12;
|
||||||
vid_frame.buflen = SWITCH_RECOMMENDED_BUFFER_SIZE - 12;
|
vid_frame.buflen = SWITCH_RECOMMENDED_BUFFER_SIZE - 12;
|
||||||
switch_set_flag((&vid_frame), SFF_RAW_RTP);
|
switch_set_flag((&vid_frame), SFF_RAW_RTP);
|
||||||
switch_set_flag((&vid_frame), SFF_PROXY_PACKET);
|
// switch_set_flag((&vid_frame), SFF_PROXY_PACKET);
|
||||||
|
switch_set_flag((&vid_frame), SFF_RAW_RTP_PARSE_FRAME);
|
||||||
|
|
||||||
if (switch_core_timer_init(&timer, "soft", read_impl.microseconds_per_packet / 1000,
|
if (switch_core_timer_init(&timer, "soft", read_impl.microseconds_per_packet / 1000,
|
||||||
read_impl.samples_per_packet, switch_core_session_get_pool(session)) != SWITCH_STATUS_SUCCESS) {
|
read_impl.samples_per_packet, switch_core_session_get_pool(session)) != SWITCH_STATUS_SUCCESS) {
|
||||||
|
@ -389,8 +388,6 @@ SWITCH_STANDARD_APP(play_fsv_function)
|
||||||
}
|
}
|
||||||
switch_core_session_set_read_codec(session, &codec);
|
switch_core_session_set_read_codec(session, &codec);
|
||||||
|
|
||||||
switch_core_service_session_av(session, SWITCH_FALSE, SWITCH_TRUE);
|
|
||||||
|
|
||||||
while (switch_channel_ready(channel)) {
|
while (switch_channel_ready(channel)) {
|
||||||
|
|
||||||
if (read(fd, &bytes, sizeof(bytes)) != sizeof(bytes)) {
|
if (read(fd, &bytes, sizeof(bytes)) != sizeof(bytes)) {
|
||||||
|
@ -504,7 +501,7 @@ SWITCH_STANDARD_APP(play_fsv_function)
|
||||||
}
|
}
|
||||||
|
|
||||||
done:
|
done:
|
||||||
switch_channel_clear_flag(channel, CF_VIDEO_PASSIVE);
|
switch_core_session_video_reset(session);
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t art[14][16] = {
|
uint8_t art[14][16] = {
|
||||||
|
|
Loading…
Reference in New Issue