patch for sh4 and actual ffmpeg versions (thx DBoxOldie)

This commit is contained in:
BPanther
2020-02-04 22:20:44 +01:00
committed by Thilo Graf
parent 5e3736a0a8
commit 83437c3656
10 changed files with 281 additions and 100 deletions

View File

@@ -83,9 +83,9 @@ bool WriterH264::Write(AVPacket *packet, int64_t pts)
unsigned int len = 0;
if (initialHeader) {
initialHeader = false;
iov[ic].iov_base = stream->codec->extradata;
iov[ic++].iov_len = stream->codec->extradata_size;
len += stream->codec->extradata_size;
iov[ic].iov_base = get_codecpar(stream)->extradata;
iov[ic++].iov_len = get_codecpar(stream)->extradata_size;
len += get_codecpar(stream)->extradata_size;
}
iov[ic].iov_base = packet->data;
iov[ic++].iov_len = packet->size;
@@ -104,7 +104,7 @@ bool WriterH264::Write(AVPacket *packet, int64_t pts)
// convert NAL units without sync byte sequence to byte-stream format
if (initialHeader) {
avcC_t *avcCHeader = (avcC_t *) stream->codec->extradata;
avcC_t *avcCHeader = (avcC_t *) get_codecpar(stream)->extradata;
if (!avcCHeader) {
fprintf(stderr, "stream->codec->extradata == NULL\n");