summaryrefslogtreecommitdiff
path: root/libmkv/EbmlWriter.h
diff options
context:
space:
mode:
authorJohn Koleszar <jkoleszar@google.com>2012-05-21 14:30:56 -0700
committerJohn Koleszar <jkoleszar@google.com>2012-06-11 15:14:58 -0700
commit0164a1cc5b13909407587109effabea92e487986 (patch)
treef490d9a5859ff362be0e9b074d078112ef573a84 /libmkv/EbmlWriter.h
parent30fb976e3e42b6bc8f9360437033d8ae22c5a2f4 (diff)
downloadlibvpx-0164a1cc5b13909407587109effabea92e487986.tar
libvpx-0164a1cc5b13909407587109effabea92e487986.tar.gz
libvpx-0164a1cc5b13909407587109effabea92e487986.tar.bz2
libvpx-0164a1cc5b13909407587109effabea92e487986.zip
Fix pedantic compiler warnings
Allows building the library with the gcc -pedantic option, for improved portabilty. In particular, this commit removes usage of C99/C++ style single-line comments and dynamic struct initializers. This is a continuation of the work done in commit 97b766a46, which removed most of these warnings for decode only builds. Change-Id: Id453d9c1d9f44cc0381b10c3869fabb0184d5966
Diffstat (limited to 'libmkv/EbmlWriter.h')
-rw-r--r--libmkv/EbmlWriter.h34
1 files changed, 19 insertions, 15 deletions
diff --git a/libmkv/EbmlWriter.h b/libmkv/EbmlWriter.h
index 324c9bca0..b94f75733 100644
--- a/libmkv/EbmlWriter.h
+++ b/libmkv/EbmlWriter.h
@@ -1,26 +1,30 @@
+/*
+ * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
+ *
+ * Use of this source code is governed by a BSD-style license
+ * that can be found in the LICENSE file in the root of the source
+ * tree. An additional intellectual property rights grant can be found
+ * in the file PATENTS. All contributing project authors may
+ * be found in the AUTHORS file in the root of the source tree.
+ */
#ifndef EBMLWRITER_HPP
#define EBMLWRITER_HPP
-
-// Copyright (c) 2010 The WebM project authors. All Rights Reserved.
-//
-// Use of this source code is governed by a BSD-style license
-// that can be found in the LICENSE file in the root of the source
-// tree. An additional intellectual property rights grant can be found
-// in the file PATENTS. All contributing project authors may
-// be found in the AUTHORS file in the root of the source tree.
-
-//note: you must define write and serialize functions as well as your own EBML_GLOBAL
-//These functions MUST be implemented
#include <stddef.h>
#include "vpx/vpx_integer.h"
+/* note: you must define write and serialize functions as well as your own
+ * EBML_GLOBAL
+ *
+ * These functions MUST be implemented
+ */
+
typedef struct EbmlGlobal EbmlGlobal;
void Ebml_Serialize(EbmlGlobal *glob, const void *, int, unsigned long);
void Ebml_Write(EbmlGlobal *glob, const void *, unsigned long);
-/////
+/*****/
-void Ebml_WriteLen(EbmlGlobal *glob, long long val);
+void Ebml_WriteLen(EbmlGlobal *glob, int64_t val);
void Ebml_WriteString(EbmlGlobal *glob, const char *str);
void Ebml_WriteUTF8(EbmlGlobal *glob, const wchar_t *wstr);
void Ebml_WriteID(EbmlGlobal *glob, unsigned long class_id);
@@ -28,11 +32,11 @@ void Ebml_SerializeUnsigned64(EbmlGlobal *glob, unsigned long class_id, uint64_t
void Ebml_SerializeUnsigned(EbmlGlobal *glob, unsigned long class_id, unsigned long ui);
void Ebml_SerializeBinary(EbmlGlobal *glob, unsigned long class_id, unsigned long ui);
void Ebml_SerializeFloat(EbmlGlobal *glob, unsigned long class_id, double d);
-//TODO make this more generic to signed
+/* TODO make this more generic to signed */
void Ebml_WriteSigned16(EbmlGlobal *glob, short val);
void Ebml_SerializeString(EbmlGlobal *glob, unsigned long class_id, const char *s);
void Ebml_SerializeUTF8(EbmlGlobal *glob, unsigned long class_id, wchar_t *s);
void Ebml_SerializeData(EbmlGlobal *glob, unsigned long class_id, unsigned char *data, unsigned long data_length);
void Ebml_WriteVoid(EbmlGlobal *glob, unsigned long vSize);
-//TODO need date function
+/* TODO need date function */
#endif