[FFmpeg-devel] [PATCH] mpeg12enc: Use Closed Captions if available

Mathieu Duponchelle mathieu at centricular.com
Thu Feb 7 20:15:21 EET 2019


On 2/7/19 6:28 PM, Carl Eugen Hoyos wrote:
> Should you check here if the size is not bigger than a certain maximum
> value ...
>
>> +            int i = 0;
>> +
>> +            put_header (s, USER_START_CODE);
>> +
>> +            put_bits(&s->pb, 8, 'G');                   // user_identifier
>> +            put_bits(&s->pb, 8, 'A');
>> +            put_bits(&s->pb, 8, '9');
>> +            put_bits(&s->pb, 8, '4');
>> +            put_bits(&s->pb, 8, 3);                     //
>> user_data_type_code
>> +            put_bits(&s->pb, 8,
>> +                ((side_data->size / 3) & 0x1f) | 0x40); // flags, cc_count
> ... because of this calculation?

Indeed, fixed, attached the updated patch, I'm afraid I'm not entirely familiar
with git send-email and the update was posted as an answer to the original
post :)


More information about the ffmpeg-devel mailing list