[vlc-commits] Move GUID_ helpers to vlc_codecs.h
Jean-Baptiste Kempf
git at videolan.org
Fri Apr 10 15:41:32 CEST 2015
vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Apr 10 15:39:36 2015 +0200| [fa8af20d0e9059c0d499da82e6e2a7f8322602c4] | committer: Jean-Baptiste Kempf
Move GUID_ helpers to vlc_codecs.h
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fa8af20d0e9059c0d499da82e6e2a7f8322602c4
---
include/vlc_codecs.h | 9 +++++++++
modules/access/mms/asf.c | 2 +-
modules/access/mms/asf.h | 2 +-
modules/codec/avcodec/dxva2.c | 2 +-
modules/demux/asf/libasf_guid.h | 8 --------
5 files changed, 12 insertions(+), 11 deletions(-)
diff --git a/include/vlc_codecs.h b/include/vlc_codecs.h
index 29d131f..2c0a726 100644
--- a/include/vlc_codecs.h
+++ b/include/vlc_codecs.h
@@ -471,6 +471,15 @@ static inline int guidcmp( const GUID *s1, const GUID *s2 )
s1->Data3 == s2->Data3 && !memcmp( s1->Data4, s2->Data4, 8 ) );
}
+#define GUID_FMT "0x%x-0x%x-0x%x-0x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x"
+#define GUID_PRINT( guid ) \
+ (unsigned)(guid).Data1, \
+ (guid).Data2, \
+ (guid).Data3, \
+ (guid).Data4[0],(guid).Data4[1],(guid).Data4[2],(guid).Data4[3], \
+ (guid).Data4[4],(guid).Data4[5],(guid).Data4[6],(guid).Data4[7]
+
+
static inline void sf_tag_to_fourcc( GUID *guid_tag,
vlc_fourcc_t *fcc, const char **ppsz_name )
{
diff --git a/modules/access/mms/asf.c b/modules/access/mms/asf.c
index d353bfd..ce6e20c 100644
--- a/modules/access/mms/asf.c
+++ b/modules/access/mms/asf.c
@@ -27,10 +27,10 @@
#include <vlc_common.h>
#include <vlc_rand.h>
-#include <vlc_codecs.h>
#include "asf.h"
#include "buffer.h"
+#include "../../demux/asf/libasf_guid.h"
void GenerateGuid ( guid_t *p_guid )
{
diff --git a/modules/access/mms/asf.h b/modules/access/mms/asf.h
index f15b90d..5d690c3 100644
--- a/modules/access/mms/asf.h
+++ b/modules/access/mms/asf.h
@@ -31,7 +31,7 @@
#ifndef _ASF_H_
#define _ASF_H_ 1
-#include "../../demux/asf/libasf_guid.h"
+#include <vlc_codecs.h>
#define ASF_CODEC_TYPE_VIDEO 0x0001
#define ASF_CODEC_TYPE_AUDIO 0x0002
diff --git a/modules/codec/avcodec/dxva2.c b/modules/codec/avcodec/dxva2.c
index 9c2828a..632e011 100644
--- a/modules/codec/avcodec/dxva2.c
+++ b/modules/codec/avcodec/dxva2.c
@@ -41,6 +41,7 @@
#include <vlc_fourcc.h>
#include <vlc_cpu.h>
#include <vlc_plugin.h>
+#include <vlc_codecs.h>
#include <libavcodec/avcodec.h>
# define DXVA2API_USE_BITFIELDS
@@ -50,7 +51,6 @@
#include "avcodec.h"
#include "va.h"
#include "../../video_chroma/copy.h"
-#include "../../demux/asf/libasf_guid.h"
static int Open(vlc_va_t *, AVCodecContext *, const es_format_t *);
static void Close(vlc_va_t *, AVCodecContext *);
diff --git a/modules/demux/asf/libasf_guid.h b/modules/demux/asf/libasf_guid.h
index a3e2be4..9d1f2bd 100644
--- a/modules/demux/asf/libasf_guid.h
+++ b/modules/demux/asf/libasf_guid.h
@@ -28,14 +28,6 @@
/*****************************************************************************
* Structure needed for decoder
*****************************************************************************/
-#define GUID_FMT "0x%x-0x%x-0x%x-0x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x"
-#define GUID_PRINT( guid ) \
- (unsigned)(guid).Data1, \
- (guid).Data2, \
- (guid).Data3, \
- (guid).Data4[0],(guid).Data4[1],(guid).Data4[2],(guid).Data4[3], \
- (guid).Data4[4],(guid).Data4[5],(guid).Data4[6],(guid).Data4[7]
-
enum
{
ASF_OBJECT_NULL = 0,
More information about the vlc-commits
mailing list