Merge commit 'ed79093222ceb42f0c3a39095a69af0b32be5450'
* commit 'ed79093222ceb42f0c3a39095a69af0b32be5450': rtpdec: Add a terminating null byte at the end of the SDES/CNAME yuv4mpeg: do not use deprecated functions oggdec: fix faulty cleanup prototype idcin: return 0 from idcin_read_packet() on success. Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
commit
ac6e074fb7
@ -345,7 +345,7 @@ static int idcin_read_packet(AVFormatContext *s,
|
|||||||
if (idcin->audio_present)
|
if (idcin->audio_present)
|
||||||
idcin->next_chunk_is_video ^= 1;
|
idcin->next_chunk_is_video ^= 1;
|
||||||
|
|
||||||
return ret;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int idcin_read_seek(AVFormatContext *s, int stream_index,
|
static int idcin_read_seek(AVFormatContext *s, int stream_index,
|
||||||
|
@ -307,13 +307,14 @@ int ff_rtp_check_and_send_back_rr(RTPDemuxContext *s, URLContext *fd,
|
|||||||
avio_w8(pb, (RTP_VERSION << 6) + 1); /* 1 report block */
|
avio_w8(pb, (RTP_VERSION << 6) + 1); /* 1 report block */
|
||||||
avio_w8(pb, RTCP_SDES);
|
avio_w8(pb, RTCP_SDES);
|
||||||
len = strlen(s->hostname);
|
len = strlen(s->hostname);
|
||||||
avio_wb16(pb, (6 + len + 3) / 4); /* length in words - 1 */
|
avio_wb16(pb, (7 + len + 3) / 4); /* length in words - 1 */
|
||||||
avio_wb32(pb, s->ssrc + 1);
|
avio_wb32(pb, s->ssrc + 1);
|
||||||
avio_w8(pb, 0x01);
|
avio_w8(pb, 0x01);
|
||||||
avio_w8(pb, len);
|
avio_w8(pb, len);
|
||||||
avio_write(pb, s->hostname, len);
|
avio_write(pb, s->hostname, len);
|
||||||
|
avio_w8(pb, 0); /* END */
|
||||||
// padding
|
// padding
|
||||||
for (len = (6 + len) % 4; len % 4; len++)
|
for (len = (7 + len) % 4; len % 4; len++)
|
||||||
avio_w8(pb, 0);
|
avio_w8(pb, 0);
|
||||||
|
|
||||||
avio_flush(pb);
|
avio_flush(pb);
|
||||||
|
@ -18,6 +18,8 @@
|
|||||||
* License along with FFmpeg; if not, write to the Free Software
|
* License along with FFmpeg; if not, write to the Free Software
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "libavutil/pixdesc.h"
|
||||||
#include "avformat.h"
|
#include "avformat.h"
|
||||||
#include "internal.h"
|
#include "internal.h"
|
||||||
#include "libavutil/pixdesc.h"
|
#include "libavutil/pixdesc.h"
|
||||||
@ -211,7 +213,7 @@ static int yuv4_write_packet(AVFormatContext *s, AVPacket *pkt)
|
|||||||
if (st->codec->pix_fmt != AV_PIX_FMT_GRAY8 &&
|
if (st->codec->pix_fmt != AV_PIX_FMT_GRAY8 &&
|
||||||
st->codec->pix_fmt != AV_PIX_FMT_GRAY16) {
|
st->codec->pix_fmt != AV_PIX_FMT_GRAY16) {
|
||||||
// Adjust for smaller Cb and Cr planes
|
// Adjust for smaller Cb and Cr planes
|
||||||
avcodec_get_chroma_sub_sample(st->codec->pix_fmt, &h_chroma_shift,
|
av_pix_fmt_get_chroma_sub_sample(st->codec->pix_fmt, &h_chroma_shift,
|
||||||
&v_chroma_shift);
|
&v_chroma_shift);
|
||||||
width >>= h_chroma_shift;
|
width >>= h_chroma_shift;
|
||||||
height >>= v_chroma_shift;
|
height >>= v_chroma_shift;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user