From cb04a141e3d67f6d249be89e95664a787e41a94b Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 24 Jul 2002 20:41:08 +0000 Subject: [PATCH] - added GstEventMask to specify event masks (next set of commits) Original commit message from CVS: - added GstEventMask to specify event masks (next set of commits) - use flags for seek methods (for use in masks) - removed #if 0 from gstmemchunk.h --- gst/gstevent.h | 18 ++++++++++++++---- gst/gstmemchunk.h | 6 +----- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/gst/gstevent.h b/gst/gstevent.h index 636c4c3..d3ff018 100644 --- a/gst/gstevent.h +++ b/gst/gstevent.h @@ -64,11 +64,21 @@ extern GType _gst_event_type; #define GST_SEEK_METHOD_MASK 0x000f0000 #define GST_SEEK_FLAGS_MASK 0xfff00000 -/* seek events */ typedef enum { - GST_SEEK_METHOD_CUR = (1 << GST_SEEK_METHOD_SHIFT), - GST_SEEK_METHOD_SET = (2 << GST_SEEK_METHOD_SHIFT), - GST_SEEK_METHOD_END = (3 << GST_SEEK_METHOD_SHIFT), + GST_EVENT_FLAG_NONE = 0 +} GstEventFlag; + +typedef struct +{ + GstEventType type; + GstEventFlag flags; +} GstEventMask; + +/* seek events, extends GstEventFlag */ +typedef enum { + GST_SEEK_METHOD_CUR = (1 << (GST_SEEK_METHOD_SHIFT + 0)), + GST_SEEK_METHOD_SET = (1 << (GST_SEEK_METHOD_SHIFT + 1)), + GST_SEEK_METHOD_END = (1 << (GST_SEEK_METHOD_SHIFT + 2)), GST_SEEK_FLAG_FLUSH = (1 << (GST_SEEK_FLAGS_SHIFT + 0)), GST_SEEK_FLAG_ACCURATE = (1 << (GST_SEEK_FLAGS_SHIFT + 1)), diff --git a/gst/gstmemchunk.h b/gst/gstmemchunk.h index e668e55..f31cc75 100644 --- a/gst/gstmemchunk.h +++ b/gst/gstmemchunk.h @@ -36,11 +36,7 @@ struct _GstMemChunkElement struct _GstMemChunk { -#if 0 - volatile GstMemChunkElement *free; /* the first free element */ - volatile gulong cnt; /* used to avoid ABA problem */ -#endif - GstAtomicSwap swap; + GstAtomicSwap swap; gchar *name; gulong area_size; -- 2.7.4