include config.mak
- SRC_DIR = $(SRC_PATH_BARE)
+ vpath %.c $(SRC_PATH)
+ vpath %.h $(SRC_PATH)
+ vpath %.S $(SRC_PATH)
+ vpath %.asm $(SRC_PATH)
+ vpath %.v $(SRC_PATH)
+ vpath %.texi $(SRC_PATH)
+
+ ifndef V
+ Q = @
+ ECHO = printf "$(1)\t%s\n" $(2)
-BRIEF = CC AS YASM AR LD HOSTCC
++BRIEF = CC AS YASM AR LD HOSTCC STRIP CP
+ SILENT = DEPCC YASMDEP RM RANLIB
+ MSG = $@
+ M = @$(call ECHO,$(TAG),$@);
+ $(foreach VAR,$(BRIEF), \
+ $(eval override $(VAR) = @$$(call ECHO,$(VAR),$$(MSG)); $($(VAR))))
+ $(foreach VAR,$(SILENT),$(eval override $(VAR) = @$($(VAR))))
+ $(eval INSTALL = @$(call ECHO,INSTALL,$$(^:$(SRC_PATH)/%=%)); $(INSTALL))
+ endif
+
+ IFLAGS := -I. -I$(SRC_PATH)
+ CPPFLAGS := $(IFLAGS) $(CPPFLAGS)
+ CFLAGS += $(ECFLAGS)
+ YASMFLAGS += $(IFLAGS) -Pconfig.asm
+ HOSTCFLAGS += $(IFLAGS)
+
+ %.o: %.c
+ $(CCDEP)
+ $(CC) $(CPPFLAGS) $(CFLAGS) $(CC_DEPFLAGS) -c $(CC_O) $<
+
+ %.o: %.S
+ $(ASDEP)
+ $(AS) $(CPPFLAGS) $(ASFLAGS) $(AS_DEPFLAGS) -c -o $@ $<
+
+ %.ho: %.h
+ $(CC) $(CPPFLAGS) $(CFLAGS) -Wno-unused -c -o $@ -x c $<
- vpath %.c $(SRC_DIR)
- vpath %.h $(SRC_DIR)
- vpath %.S $(SRC_DIR)
- vpath %.asm $(SRC_DIR)
- vpath %.v $(SRC_DIR)
- vpath %.texi $(SRC_PATH_BARE)
+ %.ver: %.v
+ $(Q)sed 's/$$MAJOR/$($(basename $(@F))_VERSION_MAJOR)/' $^ > $@
+
+ %.c %.h: TAG = GEN
+
++# Do not delete intermediate files from chains of implicit rules
++$(OBJS):
+
PROGS-$(CONFIG_FFMPEG) += ffmpeg
PROGS-$(CONFIG_FFPLAY) += ffplay
PROGS-$(CONFIG_FFPROBE) += ffprobe
all: $(FF_DEP_LIBS) $(PROGS)
+$(PROGS): %$(EXESUF): %_g$(EXESUF)
+ $(CP) $< $@
+ $(STRIP) $@
+
config.h: .config
- .config: $(wildcard $(FFLIBS:%=$(SRC_DIR)/lib%/all*.c))
+ .config: $(wildcard $(FFLIBS:%=$(SRC_PATH)/lib%/all*.c))
@-tput bold 2>/dev/null
@-printf '\nWARNING: $(?F) newer than config.h, rerun configure\n\n'
@-tput sgr0 2>/dev/null
API changes, most recent first:
+2011-06-19 - xxxxxxx - lavfi 2.23.0 - avfilter.h
+ Add layout negotiation fields and helper functions.
+
+ In particular, add in_chlayouts and out_chlayouts to AVFilterLink,
+ and the functions:
+ avfilter_set_common_sample_formats()
+ avfilter_set_common_channel_layouts()
+ avfilter_all_channel_layouts()
+
+2011-06-19 - xxxxxxx - lavfi 2.22.0 - AVFilterFormats
+ Change type of AVFilterFormats.formats from int * to int64_t *,
+ and update formats handling API accordingly.
+
+ avfilter_make_format_list() still takes a int32_t array and converts
+ it to int64_t. A new function, avfilter_make_format64_list(), that
+ takes int64_t arrays has been added.
+
+2011-06-19 - xxxxxxx - lavfi 2.21.0 - vsink_buffer.h
+ Add video sink buffer and vsink_buffer.h public header.
+
+2011-06-12 - xxxxxxx - lavfi 2.18.0 - avcodec.h
+ Add avfilter_get_video_buffer_ref_from_frame() function in
+ libavfilter/avcodec.h.
+
+2011-06-12 - xxxxxxx - lavfi 2.17.0 - avfiltergraph.h
+ Add avfilter_inout_alloc() and avfilter_inout_free() functions.
+
+2011-06-12 - xxxxxxx - lavfi 2.16.0 - avfilter_graph_parse()
+ Change avfilter_graph_parse() signature.
+
+ 2011-06-xx - xxxxxxx - lavu 51.8.0 - attributes.h
+ Add av_printf_format().
+
2011-06-xx - xxxxxxx - lavf 53.2.0 - avformat.h
Add avformat_open_input and avformat_write_header().
Deprecate av_open_input_stream, av_open_input_file,
#define FF_VDPAU_STATE_USED_FOR_REFERENCE 2
/**
- * \brief This structure is used as a callback between the FFmpeg
- * @brief This structure is used as a callback between the Libav
++ * @brief This structure is used as a callback between the FFmpeg
* decoder (vd_) and presentation (vo_) module.
* This is used for defining a video frame containing surface,
* picture parameter, bitstream information etc which are passed
*/
#include <alsa/asoundlib.h>
-#include "libavformat/avformat.h"
+#include "avdevice.h"
+ #include "libavutil/avassert.h"
#include "alsa-audio.h"
fbdev->time_frame = av_gettime();
/* wait based on the frame rate */
- curtime = av_gettime();
- delay = fbdev->time_frame - curtime;
- av_dlog(avctx,
- "time_frame:%"PRId64" curtime:%"PRId64" delay:%"PRId64"\n",
- fbdev->time_frame, curtime, delay);
- if (delay > 0) {
+ while (1) {
+ curtime = av_gettime();
+ delay = fbdev->time_frame - curtime;
+ av_dlog(avctx,
+ "time_frame:%"PRId64" curtime:%"PRId64" delay:%"PRId64"\n",
+ fbdev->time_frame, curtime, delay);
+ if (delay <= 0) {
- fbdev->time_frame += INT64_C(1000000) / av_q2d(fbdev->fps);
++ fbdev->time_frame += INT64_C(1000000) / av_q2d(fbdev->framerate_q);
+ break;
+ }
if (avctx->flags & AVFMT_FLAG_NONBLOCK)
return AVERROR(EAGAIN);
ts.tv_sec = delay / 1000000;
static int v4l2_set_parameters(AVFormatContext *s1, AVFormatParameters *ap)
{
struct video_data *s = s1->priv_data;
- struct v4l2_input input;
- struct v4l2_standard standard;
- struct v4l2_streamparm streamparm = { 0 };
+ struct v4l2_input input = {0};
+ struct v4l2_standard standard = {0};
+ struct v4l2_streamparm streamparm = {0};
struct v4l2_fract *tpf = &streamparm.parm.capture.timeperframe;
int i, ret;
- AVRational fps;
+ AVRational framerate_q;
streamparm.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
*/
int64_t avio_size(AVIOContext *s);
+/**
+ * feof() equivalent for AVIOContext.
+ * @return non zero if and only if end of file
+ */
+int url_feof(AVIOContext *s);
+
/** @warning currently size is limited */
- #ifdef __GNUC__
- int avio_printf(AVIOContext *s, const char *fmt, ...) __attribute__ ((__format__ (__printf__, 2, 3)));
- #else
- int avio_printf(AVIOContext *s, const char *fmt, ...);
- #endif
+ int avio_printf(AVIOContext *s, const char *fmt, ...) av_printf_format(2, 3);
void avio_flush(AVIOContext *s);
p->pids[p->nb_pids++] = pid;
}
+static void set_pcr_pid(AVFormatContext *s, unsigned int programid, unsigned int pid)
+{
+ int i;
+ for(i=0; i<s->nb_programs; i++) {
+ if(s->programs[i]->id == programid) {
+ s->programs[i]->pcr_pid = pid;
+ break;
+ }
+ }
+}
+
/**
- * \brief discard_pid() decides if the pid is to be discarded according
+ * @brief discard_pid() decides if the pid is to be discarded according
* to caller's programs selection
- * \param ts : - TS context
- * \param pid : - pid
- * \return 1 if the pid is only comprised in programs that have .discard=AVDISCARD_ALL
+ * @param ts : - TS context
+ * @param pid : - pid
+ * @return 1 if the pid is only comprised in programs that have .discard=AVDISCARD_ALL
* 0 otherwise
*/
static int discard_pid(MpegTSContext *ts, unsigned int pid)
#define AV_VERSION(a, b, c) AV_VERSION_DOT(a, b, c)
#define LIBAVUTIL_VERSION_MAJOR 51
- #define LIBAVUTIL_VERSION_MINOR 9
- #define LIBAVUTIL_VERSION_MICRO 1
-#define LIBAVUTIL_VERSION_MINOR 8
++#define LIBAVUTIL_VERSION_MINOR 10
+ #define LIBAVUTIL_VERSION_MICRO 0
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
LIBAVUTIL_VERSION_MINOR, \