summaryrefslogtreecommitdiffstats
path: root/libmpeg2/idct_mmx.c
diff options
context:
space:
mode:
authorhenry <henry@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-08-02 11:26:43 +0000
committerhenry <henry@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-08-02 11:26:43 +0000
commit943139cc78038c3aea0837229298cb2c08e3f8a2 (patch)
tree56b2a2dac2c09fe1016e3e146ec19cb2aae0777a /libmpeg2/idct_mmx.c
parent4779094c4be9af5ec0c5145d8a460b75e4a510c8 (diff)
downloadmpv-943139cc78038c3aea0837229298cb2c08e3f8a2.tar.bz2
mpv-943139cc78038c3aea0837229298cb2c08e3f8a2.tar.xz
Importing libmpeg2 from mpeg2dec-0.4.0b
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@12933 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpeg2/idct_mmx.c')
-rw-r--r--libmpeg2/idct_mmx.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libmpeg2/idct_mmx.c b/libmpeg2/idct_mmx.c
index e2afe6bb45..51d01dc926 100644
--- a/libmpeg2/idct_mmx.c
+++ b/libmpeg2/idct_mmx.c
@@ -28,11 +28,11 @@
#include <inttypes.h>
#include "mpeg2.h"
-#include "mpeg2_internal.h"
#include "attributes.h"
+#include "mpeg2_internal.h"
#include "mmx.h"
-#define ROW_SHIFT 11
+#define ROW_SHIFT 15
#define COL_SHIFT 6
#define round(bias) ((int)(((bias)+0.5) * (1<<ROW_SHIFT)))
@@ -701,7 +701,7 @@ do { \
static inline void block_add_DC (int16_t * const block, uint8_t * dest,
const int stride, const int cpu)
{
- movd_v2r ((block[0] + 4) >> 3, mm0);
+ movd_v2r ((block[0] + 64) >> 7, mm0);
pxor_r2r (mm1, mm1);
movq_m2r (*dest, mm2);
dup4 (mm0);
@@ -763,7 +763,7 @@ void mpeg2_idct_copy_mmxext (int16_t * const block, uint8_t * const dest,
void mpeg2_idct_add_mmxext (const int last, int16_t * const block,
uint8_t * const dest, const int stride)
{
- if (last != 129 || (block[0] & 7) == 4) {
+ if (last != 129 || (block[0] & (7 << 4)) == (4 << 4)) {
mmxext_idct (block);
block_add (block, dest, stride);
block_zero (block);
@@ -786,7 +786,7 @@ void mpeg2_idct_copy_mmx (int16_t * const block, uint8_t * const dest,
void mpeg2_idct_add_mmx (const int last, int16_t * const block,
uint8_t * const dest, const int stride)
{
- if (last != 129 || (block[0] & 7) == 4) {
+ if (last != 129 || (block[0] & (7 << 4)) == (4 << 4)) {
mmx_idct (block);
block_add (block, dest, stride);
block_zero (block);