#include "mwindow.h"
#include "vframe.h"
+#ifdef FFMPEG3
+#define url filename
+#else
+#define av_register_all(s)
+#define avfilter_register_all(s)
+#endif
#define VIDEO_INBUF_SIZE 0x10000
#define AUDIO_INBUF_SIZE 0x10000
AVCodec *av_codec = !get_codec(video_codec, "video", asset->vcodec) ?
avcodec_find_encoder_by_name(video_codec) : 0;
if( av_codec && av_codec->pix_fmts ) {
- if( edl ) {
+ if( 0 && edl ) { // frequently picks a bad answer
int color_model = edl->session->color_model;
int max_bits = BC_CModels::calculate_pixelsize(color_model) * 8;
max_bits /= BC_CModels::components(color_model);
int FFMPEG::init_decoder(const char *filename)
{
ff_lock("FFMPEG::init_decoder");
+ av_register_all();
char file_opts[BCTEXTLEN];
char *bp = strrchr(strcpy(file_opts, filename), '/');
char *sp = strrchr(!bp ? file_opts : bp, '.');
return 1;
}
ff_lock("FFMPEG::init_encoder");
+ av_register_all();
char format[BCSTRLEN];
if( get_format(format, "format", file_format) )
strcpy(format, file_format);
return 1;
}
+#ifdef HAVE_DV
if( !strcmp(codec_name, CODEC_TAG_DVSD) ) strcpy(codec_name, "dv");
+#endif
else if( !strcmp(codec_name, CODEC_TAG_MJPEG) ) strcpy(codec_name, "mjpeg");
else if( !strcmp(codec_name, CODEC_TAG_JPEG) ) strcpy(codec_name, "jpeg");
int FFVideoStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
{
+ avfilter_register_all();
const char *sp = filter_spec;
char filter_name[BCSTRLEN], *np = filter_name;
int i = sizeof(filter_name);
int FFAudioStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
{
+ avfilter_register_all();
const char *sp = filter_spec;
char filter_name[BCSTRLEN], *np = filter_name;
int i = sizeof(filter_name);