Commit 77bce7d1 authored by Min Chen's avatar Min Chen

update


git-svn-id: svn://svn.videolan.org/x264/trunk@9 df754926-b1dd-0310-bc7b-ec298dee348c
parent c7631faf
......@@ -302,7 +302,7 @@ SOURCE=..\..\core\i386\cpu.asm
!IF "$(CFG)" == "libx264 - Win32 Release"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Release
InputPath=..\..\core\i386\cpu.asm
InputName=cpu
......@@ -314,7 +314,7 @@ InputName=cpu
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Debug
InputPath=..\..\core\i386\cpu.asm
InputName=cpu
......@@ -337,7 +337,7 @@ SOURCE=..\..\core\i386\dct.asm
!IF "$(CFG)" == "libx264 - Win32 Release"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Release
InputPath=..\..\core\i386\dct.asm
InputName=dct
......@@ -349,7 +349,7 @@ InputName=dct
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Debug
InputPath=..\..\core\i386\dct.asm
InputName=dct
......@@ -368,11 +368,55 @@ SOURCE=..\..\core\i386\dct.h
# End Source File
# Begin Source File
SOURCE="..\..\core\i386\mc-c.c"
!IF "$(CFG)" == "libx264 - Win32 Release"
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
# PROP Exclude_From_Build 1
!ENDIF
# End Source File
# Begin Source File
SOURCE=..\..\core\i386\mc.asm
!IF "$(CFG)" == "libx264 - Win32 Release"
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Release
InputPath=..\..\core\i386\mc.asm
InputName=mc
"$(IntDir)\$(InputName).obj" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
nasm -f win32 -DPREFIX -o $(IntDir)\$(InputName).obj $(InputPath)
# End Custom Build
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Debug
InputPath=..\..\core\i386\mc.asm
InputName=mc
"$(IntDir)\$(InputName).obj" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
nasm -f win32 -DPREFIX -o $(IntDir)\$(InputName).obj $(InputPath)
# End Custom Build
!ENDIF
# End Source File
# Begin Source File
SOURCE=..\..\core\i386\pixel.asm
!IF "$(CFG)" == "libx264 - Win32 Release"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Release
InputPath=..\..\core\i386\pixel.asm
InputName=pixel
......@@ -384,7 +428,7 @@ InputName=pixel
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
# Begin Custom Build
# Begin Custom Build - Assembly $(InputPath)
IntDir=.\Debug
InputPath=..\..\core\i386\pixel.asm
InputName=pixel
......@@ -450,13 +494,6 @@ SOURCE=..\..\core\cpu.c
# Begin Source File
SOURCE=..\..\core\csp.c
!IF "$(CFG)" == "libx264 - Win32 Release"
!ELSEIF "$(CFG)" == "libx264 - Win32 Debug"
!ENDIF
# End Source File
# Begin Source File
......
......@@ -2,7 +2,7 @@
* mc.c: h264 encoder library (Motion Compensation)
*****************************************************************************
* Copyright (C) 2003 Laurent Aimar
* $Id: mc-c.c,v 1.3 2004/06/10 18:13:38 fenrir Exp $
* $Id: mc-c.c,v 1.4 2004/06/17 09:01:19 chenm001 Exp $
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
*
......@@ -180,6 +180,7 @@ static inline int x264_tapfilter1( uint8_t *pix )
return pix[-2] - 5*pix[-1] + 20*(pix[0] + pix[1]) - 5*pix[ 2] + pix[ 3];
}
#if 0
static inline void pixel_avg_w4( uint8_t *dst, int i_dst_stride,
uint8_t *src1, int i_src1_stride,
uint8_t *src2, int i_src2_stride,
......@@ -197,6 +198,13 @@ static inline void pixel_avg_w4( uint8_t *dst, int i_dst_stride,
src2 += i_src2_stride;
}
}
#else
extern void pixel_avg_w4( uint8_t *dst, int i_dst_stride,
uint8_t *src1, int i_src1_stride,
uint8_t *src2, int i_src2_stride,
int i_height );
#endif
static inline void pixel_avg_w8( uint8_t *dst, int i_dst_stride,
uint8_t *src1, int i_src1_stride,
uint8_t *src2, int i_src2_stride,
......
......@@ -2,7 +2,7 @@
;* mc.asm: h264 encoder library
;*****************************************************************************
;* Copyright (C) 2003 x264 project
;* $Id: mc.asm,v 1.1 2004/06/03 19:27:07 fenrir Exp $
;* $Id: mc.asm,v 1.2 2004/06/17 09:01:19 chenm001 Exp $
;*
;* Authors: Min Chen <chenm001.163.com> (converted to nasm)
;* Laurent Aimar <fenrir@via.ecp.fr> (init algorithm)
......@@ -67,6 +67,50 @@ ALIGN 16
SECTION .text
cglobal pixel_avg_w4
ALIGN 16
;-----------------------------------------------------------------------------
; void pixel_avg_w4( uint8_t *dst, int i_dst_stride,
; uint8_t *src1, int i_src1_stride,
; uint8_t *src2, int i_src2_stride,
; int i_height );
;-----------------------------------------------------------------------------
pixel_avg_w4:
push ebp
push ebx
push esi
push edi
mov edi, [esp+20] ; dst
mov ebx, [esp+28] ; src1
mov ecx, [esp+36] ; src2
mov esi, [esp+24] ; i_dst_stride
mov eax, [esp+32] ; i_src1_stride
mov edx, [esp+40] ; i_src2_stride
mov ebp, [esp+44] ; i_height
ALIGN 4
.height_loop
movd mm0, [ebx]
pavgb mm0, [ecx]
movd mm1, [ebx+eax]
pavgb mm1, [ecx+edx]
movd [edi], mm0
movd [edi+esi], mm1
dec ebp
dec ebp
lea ebx, [ebx+eax*2]
lea ecx, [ecx+edx*2]
lea edi, [edi+esi*2]
jne .height_loop
pop edi
pop esi
pop ebx
pop ebp
ret
cglobal mc_copy_w4
ALIGN 16
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment