summaryrefslogtreecommitdiffstats
path: root/libavcodec/idctdsp.h
diff options
context:
space:
mode:
authorDiego Biurrun <diego@biurrun.de>2014-02-18 11:30:55 +0100
committerDiego Biurrun <diego@biurrun.de>2014-07-18 07:51:03 -0700
commitb4987f72197e0c62cf2633bf835a9c32d2a445ae (patch)
tree4e8cce0604eeea25ac63f7fe345b572bac6f6ac8 /libavcodec/idctdsp.h
parentc0de9159a7ba5707aa0a5c2bc73ae78b7b87ec46 (diff)
downloadffmpeg-streaming-b4987f72197e0c62cf2633bf835a9c32d2a445ae.zip
ffmpeg-streaming-b4987f72197e0c62cf2633bf835a9c32d2a445ae.tar.gz
idct: Convert IDCT permutation #defines to an enum
Also rename the enum values to be consistent with other DCT permutations.
Diffstat (limited to 'libavcodec/idctdsp.h')
-rw-r--r--libavcodec/idctdsp.h21
1 files changed, 12 insertions, 9 deletions
diff --git a/libavcodec/idctdsp.h b/libavcodec/idctdsp.h
index e3a2317..b88cc82 100644
--- a/libavcodec/idctdsp.h
+++ b/libavcodec/idctdsp.h
@@ -32,12 +32,21 @@ typedef struct ScanTable {
uint8_t raster_end[64];
} ScanTable;
+enum idct_permutation_type {
+ FF_IDCT_PERM_NONE,
+ FF_IDCT_PERM_LIBMPEG2,
+ FF_IDCT_PERM_SIMPLE,
+ FF_IDCT_PERM_TRANSPOSE,
+ FF_IDCT_PERM_PARTTRANS,
+ FF_IDCT_PERM_SSE2,
+};
+
void ff_init_scantable(uint8_t *permutation, ScanTable *st,
const uint8_t *src_scantable);
void ff_init_scantable_permutation(uint8_t *idct_permutation,
- int idct_permutation_type);
+ enum idct_permutation_type perm_type);
int ff_init_scantable_permutation_x86(uint8_t *idct_permutation,
- int idct_permutation_type);
+ enum idct_permutation_type perm_type);
typedef struct IDCTDSPContext {
/* pixel ops : interface with DCT */
@@ -83,13 +92,7 @@ typedef struct IDCTDSPContext {
* -> simple_idct_mmx -> ...)
*/
uint8_t idct_permutation[64];
- int idct_permutation_type;
-#define FF_NO_IDCT_PERM 1
-#define FF_LIBMPEG2_IDCT_PERM 2
-#define FF_SIMPLE_IDCT_PERM 3
-#define FF_TRANSPOSE_IDCT_PERM 4
-#define FF_PARTTRANS_IDCT_PERM 5
-#define FF_SSE2_IDCT_PERM 6
+ enum idct_permutation_type perm_type;
} IDCTDSPContext;
void ff_idctdsp_init(IDCTDSPContext *c, AVCodecContext *avctx);
OpenPOWER on IntegriCloud