diff options
author | Anton Khirnov <anton@khirnov.net> | 2015-07-13 08:56:53 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2015-07-13 08:58:21 +0200 |
commit | a062a55d37720abc8c704aa0e8682efd3cdc9c9b (patch) | |
tree | df5cb0e9dc816a05b25b4a8730fa0732d5752524 /libavcodec/hevc_data.c | |
parent | b9f76d19d81fbc7f088536f966c2d3dc23c34ddc (diff) | |
download | ffmpeg-a062a55d37720abc8c704aa0e8682efd3cdc9c9b.tar.gz |
hevc_parser: fix standalone build with the hevc decoder disabled
The parser depends on hevc_ps, which in turn needs some data tables.
Found-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/hevc_data.c')
-rw-r--r-- | libavcodec/hevc_data.c | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/libavcodec/hevc_data.c b/libavcodec/hevc_data.c new file mode 100644 index 0000000000..f4b6096aec --- /dev/null +++ b/libavcodec/hevc_data.c @@ -0,0 +1,75 @@ +/* + * HEVC shared tables + * + * 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 <stdint.h> + +#include "hevc.h" + +const uint8_t ff_hevc_diag_scan4x4_x[16] = { + 0, 0, 1, 0, + 1, 2, 0, 1, + 2, 3, 1, 2, + 3, 2, 3, 3, +}; + +const uint8_t ff_hevc_diag_scan4x4_y[16] = { + 0, 1, 0, 2, + 1, 0, 3, 2, + 1, 0, 3, 2, + 1, 3, 2, 3, +}; + +const uint8_t ff_hevc_diag_scan8x8_x[64] = { + 0, 0, 1, 0, + 1, 2, 0, 1, + 2, 3, 0, 1, + 2, 3, 4, 0, + 1, 2, 3, 4, + 5, 0, 1, 2, + 3, 4, 5, 6, + 0, 1, 2, 3, + 4, 5, 6, 7, + 1, 2, 3, 4, + 5, 6, 7, 2, + 3, 4, 5, 6, + 7, 3, 4, 5, + 6, 7, 4, 5, + 6, 7, 5, 6, + 7, 6, 7, 7, +}; + +const uint8_t ff_hevc_diag_scan8x8_y[64] = { + 0, 1, 0, 2, + 1, 0, 3, 2, + 1, 0, 4, 3, + 2, 1, 0, 5, + 4, 3, 2, 1, + 0, 6, 5, 4, + 3, 2, 1, 0, + 7, 6, 5, 4, + 3, 2, 1, 0, + 7, 6, 5, 4, + 3, 2, 1, 7, + 6, 5, 4, 3, + 2, 7, 6, 5, + 4, 3, 7, 6, + 5, 4, 7, 6, + 5, 7, 6, 7, +}; |