[asterisk-bugs] [JIRA] (ASTERISK-26554) format_h264: ControlPlayback() running slowly
Adam Caldwell (JIRA)
noreply at issues.asterisk.org
Thu Oct 7 14:50:49 CDT 2021
[ https://issues.asterisk.org/jira/browse/ASTERISK-26554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=256558#comment-256558 ]
Adam Caldwell edited comment on ASTERISK-26554 at 10/7/21 2:49 PM:
-------------------------------------------------------------------
i got rid of the 1/10 speed by patching main/file.c:
In {{static enum fsread_res ast_readvideo_callback(struct ast_filestream *s)}}
Change this line to have /8 as shown:
{{ast_channel_vstreamid_set(s->owner, ast_sched_add(ast_channel_sched(s->owner), whennext / (ast_format_get_sample_rate(s->fmt->format) / 1000)/8, ast_fsread_video, s));}}
It works for me, but I'm not sure it's the right fix.... so just leaving this comment here.
I believe that the correct fix should look at the sample rate for the audio (8000) and divide it by the sample rate for the video (which comes up as 1000), but I'm not certain.
was (Author: alcanzar):
i got rid of the 1/10 speed by patching main/file.c:
In {{static enum fsread_res ast_readvideo_callback(struct ast_filestream *s)}}
Change this line to have /10 as shown:
{{ast_channel_vstreamid_set(s->owner, ast_sched_add(ast_channel_sched(s->owner), whennext / (ast_format_get_sample_rate(s->fmt->format) / 1000)/10, ast_fsread_video, s));}}
It works for me, but I'm not sure it's the right fix.... so just leaving this comment here
> format_h264: ControlPlayback() running slowly
> ---------------------------------------------
>
> Key: ASTERISK-26554
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-26554
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Formats/format_h264, Resources/res_rtp_asterisk
> Affects Versions: 13.12.1
> Environment: Centos 6.8 (64-bit)
> Reporter: Ian Gilmour
>
> If you use Record() to record audio & video and then try to play the audio & video back by using ControlPlayback() the audio plays at normal speed, but the video plays at ~1/10th the normal speed. Problem seen with VP8/H264 video & opus/speex audio codecs.
> The problem isn't present in Asterisk 13.11.2.
> The bug appears to be caused by the changes made to fix ASTERISK-26367. Backing off the change set associated with this issue gets me back to a system that plays the video at the expected speed.
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list