You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avcodec/idctdsp: Add function to apply permutation to array
It is the part of ff_init_scantable() that is used by all users of said function. Reviewed-by: Peter Ross <pross@xvid.org> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
@@ -27,6 +27,15 @@
|
||||
#include "simple_idct.h"
|
||||
#include "xvididct.h"
|
||||
|
||||
av_cold void ff_permute_scantable(uint8_t dst[64], const uint8_t src[64],
|
||||
const uint8_t permutation[64])
|
||||
{
|
||||
for (int i = 0; i < 64; i++) {
|
||||
int j = src[i];
|
||||
dst[i] = permutation[j];
|
||||
}
|
||||
}
|
||||
|
||||
av_cold void ff_init_scantable(const uint8_t *permutation, ScanTable *st,
|
||||
const uint8_t *src_scantable)
|
||||
{
|
||||
|
@@ -43,6 +43,8 @@ enum idct_permutation_type {
|
||||
FF_IDCT_PERM_SSE2,
|
||||
};
|
||||
|
||||
void ff_permute_scantable(uint8_t dst[64], const uint8_t src[64],
|
||||
const uint8_t permutation[64]);
|
||||
void ff_init_scantable(const uint8_t *permutation, ScanTable *st,
|
||||
const uint8_t *src_scantable);
|
||||
void ff_init_scantable_permutation(uint8_t *idct_permutation,
|
||||
|
Reference in New Issue
Block a user