From: Guillaume Martres <[email protected]>
---
libavformat/Makefile | 1 +
libavformat/allformats.c | 1 +
libavformat/hevcdec.c | 30 ++++++++++++++++++++++++++++++
3 files changed, 32 insertions(+)
create mode 100644 libavformat/hevcdec.c
diff --git a/libavformat/Makefile b/libavformat/Makefile
index 82dc1c1..b853cde 100644
--- a/libavformat/Makefile
+++ b/libavformat/Makefile
@@ -108,6 +108,7 @@ OBJS-$(CONFIG_H263_DEMUXER) += h263dec.o
rawdec.o
OBJS-$(CONFIG_H263_MUXER) += rawenc.o
OBJS-$(CONFIG_H264_DEMUXER) += h264dec.o rawdec.o
OBJS-$(CONFIG_H264_MUXER) += rawenc.o
+OBJS-$(CONFIG_HEVC_DEMUXER) += hevcdec.o rawdec.o
OBJS-$(CONFIG_HLS_DEMUXER) += hls.o
OBJS-$(CONFIG_IDCIN_DEMUXER) += idcin.o
OBJS-$(CONFIG_IFF_DEMUXER) += iff.o
diff --git a/libavformat/allformats.c b/libavformat/allformats.c
index 40770e5..5b636f1 100644
--- a/libavformat/allformats.c
+++ b/libavformat/allformats.c
@@ -106,6 +106,7 @@ void av_register_all(void)
REGISTER_MUXDEMUX (H261, h261);
REGISTER_MUXDEMUX (H263, h263);
REGISTER_MUXDEMUX (H264, h264);
+ REGISTER_DEMUXER (HEVC, hevc);
REGISTER_DEMUXER (HLS, hls);
REGISTER_DEMUXER (IDCIN, idcin);
REGISTER_DEMUXER (IFF, iff);
diff --git a/libavformat/hevcdec.c b/libavformat/hevcdec.c
new file mode 100644
index 0000000..958a13b
--- /dev/null
+++ b/libavformat/hevcdec.c
@@ -0,0 +1,30 @@
+/*
+ * RAW HEVC video demuxer
+ * Copyright (c) 2012 Guillaume Martres <[email protected]>
+ *
+ * This file is part of Libav.
+ *
+ * Libav is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * Libav is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with Libav; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "avformat.h"
+#include "rawdec.h"
+
+static int hevc_probe(AVProbeData *p)
+{
+ return AVPROBE_SCORE_MAX/2;
+}
+
+FF_DEF_RAWVIDEO_DEMUXER(hevc, "raw HEVC video format", hevc_probe,
"hevc,h265,265", AV_CODEC_ID_HEVC)
--
1.7.9.5
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel