1/*
2 *  Copyright (c) 2010 The WebM project authors. All Rights Reserved.
3 *
4 *  Use of this source code is governed by a BSD-style license
5 *  that can be found in the LICENSE file in the root of the source
6 *  tree. An additional intellectual property rights grant can be found
7 *  in the file PATENTS.  All contributing project authors may
8 *  be found in the AUTHORS file in the root of the source tree.
9 */
10
11#ifndef VP9_COMMON_VP9_IDCT_H_
12#define VP9_COMMON_VP9_IDCT_H_
13
14#include <assert.h>
15
16#include "./vpx_config.h"
17#include "vp9/common/vp9_common.h"
18#include "vp9/common/vp9_enums.h"
19#include "vpx_dsp/inv_txfm.h"
20#include "vpx_dsp/txfm_common.h"
21#include "vpx_ports/mem.h"
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27typedef void (*transform_1d)(const tran_low_t *, tran_low_t *);
28
29typedef struct {
30  transform_1d cols, rows;  // vertical and horizontal
31} transform_2d;
32
33#if CONFIG_VP9_HIGHBITDEPTH
34typedef void (*highbd_transform_1d)(const tran_low_t *, tran_low_t *, int bd);
35
36typedef struct {
37  highbd_transform_1d cols, rows;  // vertical and horizontal
38} highbd_transform_2d;
39#endif  // CONFIG_VP9_HIGHBITDEPTH
40
41void vp9_iwht4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
42                     int eob);
43void vp9_idct4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
44                     int eob);
45void vp9_idct8x8_add(const tran_low_t *input, uint8_t *dest, int stride,
46                     int eob);
47void vp9_idct16x16_add(const tran_low_t *input, uint8_t *dest, int stride,
48                       int eob);
49void vp9_idct32x32_add(const tran_low_t *input, uint8_t *dest, int stride,
50                       int eob);
51
52void vp9_iht4x4_add(TX_TYPE tx_type, const tran_low_t *input, uint8_t *dest,
53                    int stride, int eob);
54void vp9_iht8x8_add(TX_TYPE tx_type, const tran_low_t *input, uint8_t *dest,
55                    int stride, int eob);
56void vp9_iht16x16_add(TX_TYPE tx_type, const tran_low_t *input, uint8_t *dest,
57                      int stride, int eob);
58
59#if CONFIG_VP9_HIGHBITDEPTH
60void vp9_highbd_iwht4x4_add(const tran_low_t *input, uint16_t *dest, int stride,
61                            int eob, int bd);
62void vp9_highbd_idct4x4_add(const tran_low_t *input, uint16_t *dest, int stride,
63                            int eob, int bd);
64void vp9_highbd_idct8x8_add(const tran_low_t *input, uint16_t *dest, int stride,
65                            int eob, int bd);
66void vp9_highbd_idct16x16_add(const tran_low_t *input, uint16_t *dest,
67                              int stride, int eob, int bd);
68void vp9_highbd_idct32x32_add(const tran_low_t *input, uint16_t *dest,
69                              int stride, int eob, int bd);
70void vp9_highbd_iht4x4_add(TX_TYPE tx_type, const tran_low_t *input,
71                           uint16_t *dest, int stride, int eob, int bd);
72void vp9_highbd_iht8x8_add(TX_TYPE tx_type, const tran_low_t *input,
73                           uint16_t *dest, int stride, int eob, int bd);
74void vp9_highbd_iht16x16_add(TX_TYPE tx_type, const tran_low_t *input,
75                             uint16_t *dest, int stride, int eob, int bd);
76#endif  // CONFIG_VP9_HIGHBITDEPTH
77#ifdef __cplusplus
78}  // extern "C"
79#endif
80
81#endif  // VP9_COMMON_VP9_IDCT_H_
82