Hi,
I try to produce h264 encoded videos in mp4 container using libav* instead of
ffmpeg directly. I have compiled and tested output_example.c like that:
./output_example test.mp4
But it produces mp4 file with mp4 encoded video stream. So I have modified
output_example.c to force CCODEC_ID_H264 instead of default codec
CODEC_ID_MPEG4:
.....
/* allocate the output media context */
oc = av_alloc_format_context();
if (!oc) {
fprintf(stderr, "Memory error\n");
exit(1);
}
/* need h264 codec */
fmt->video_codec = CODEC_ID_H264;
oc->oformat = fmt;
snprintf(oc->filename, sizeof(oc->filename), "%s", filename);
.....
But when I launch output_example like above the program crash with a segfault.
Does anyone know what else I have modify in output_example to produce h264
encoded video stream in mp4 file format ?
Regards
--
David REGADE
_______________________________________________
libav-user mailing list
[email protected]
https://lists.mplayerhq.hu/mailman/listinfo/libav-user