vp8dx.h 2.6 KB
Newer Older
John Koleszar's avatar
John Koleszar committed
1
/*
2
 *  Copyright (c) 2010 The WebM project authors. All Rights Reserved.
John Koleszar's avatar
John Koleszar committed
3
 *
4
 *  Use of this source code is governed by a BSD-style license
5
6
 *  that can be found in the LICENSE file in the root of the source
 *  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.
John Koleszar's avatar
John Koleszar committed
9
10
11
12
13
14
15
16
17
18
 */


#include "vp8.h"

/*!\defgroup vp8_decoder WebM VP8 Decoder
 * \ingroup vp8
 *
 * @{
 */
James Zern's avatar
James Zern committed
19
/*!\file
John Koleszar's avatar
John Koleszar committed
20
21
22
 * \brief Provides definitions for using the VP8 algorithm within the vpx Decoder
 *        interface.
 */
John Koleszar's avatar
John Koleszar committed
23
24
#ifndef VP8DX_H
#define VP8DX_H
Johann's avatar
Johann committed
25
#include "vpx_codec_impl_top.h"
John Koleszar's avatar
John Koleszar committed
26

27
/*!\name Algorithm interface for VP8
John Koleszar's avatar
John Koleszar committed
28
29
30
 *
 * This interface provides the capability to decode raw VP8 streams, as would
 * be found in AVI files and other non-Flash uses.
31
 * @{
John Koleszar's avatar
John Koleszar committed
32
 */
33
extern vpx_codec_iface_t  vpx_codec_vp8_dx_algo;
John Koleszar's avatar
John Koleszar committed
34
extern vpx_codec_iface_t *vpx_codec_vp8_dx(void);
35
36
37
38

/* TODO(jkoleszar): These move to VP9 in a later patch set. */
extern vpx_codec_iface_t  vpx_codec_vp9_dx_algo;
extern vpx_codec_iface_t *vpx_codec_vp9_dx(void);
39
/*!@} - end algorithm interface member group*/
John Koleszar's avatar
John Koleszar committed
40
41
42
43
44

/* Include controls common to both the encoder and decoder */
#include "vp8.h"


45
46
/*!\brief VP8 decoder control functions
 *
47
48
49
50
 * This set of macros define the control functions available for the VP8
 * decoder interface.
 *
 * \sa #vpx_codec_control
51
 */
John Koleszar's avatar
John Koleszar committed
52
53
54
55
56
57
58
59
60
enum vp8_dec_control_id {
  /** control function to get info on which reference frames were updated
   *  by the last decode
   */
  VP8D_GET_LAST_REF_UPDATES = VP8_DECODER_CTRL_ID_START,

  /** check if the indicated frame is corrupted */
  VP8D_GET_FRAME_CORRUPTED,

John Koleszar's avatar
John Koleszar committed
61
62
63
64
65
  /** control function to get info on which reference frames were used
   *  by the last decode
   */
  VP8D_GET_LAST_REF_USED,

66
67
68
69
70
71
  /** decryption key to protect encoded data buffer before decoding,
   *  pointer to 32 byte array which is copied, so the array passed
   *  does not need to be preserved
   */
  VP8_SET_DECRYPT_KEY,

72
73
74
  /** For testing. */
  VP9_INVERT_TILE_DECODE_ORDER,

John Koleszar's avatar
John Koleszar committed
75
76
  VP8_DECODER_CTRL_ID_MAX
};
77
78


79
/*!\brief VP8 decoder control function parameter type
80
 *
81
 * Defines the data types that VP8D control functions take. Note that
82
83
84
85
86
87
 * additional common controls are defined in vp8.h
 *
 */


VPX_CTRL_USE_TYPE(VP8D_GET_LAST_REF_UPDATES,   int *)
88
VPX_CTRL_USE_TYPE(VP8D_GET_FRAME_CORRUPTED,    int *)
John Koleszar's avatar
John Koleszar committed
89
VPX_CTRL_USE_TYPE(VP8D_GET_LAST_REF_USED,      int *)
90
VPX_CTRL_USE_TYPE(VP8_SET_DECRYPT_KEY,         const unsigned char *)
91
VPX_CTRL_USE_TYPE(VP9_INVERT_TILE_DECODE_ORDER, int)
92

John Koleszar's avatar
John Koleszar committed
93
94
95
/*! @} - end defgroup vp8_decoder */


Johann's avatar
Johann committed
96
#include "vpx_codec_impl_bottom.h"
John Koleszar's avatar
John Koleszar committed
97
#endif