static void deinterlace_frame_di_tomsmocomp( uint8_t *output, int outstride, deinterlace_frame_data_t *data, int bottom_field, int second_field, int width, int height ) { #if defined (ARCH_X86) || defined (ARCH_X86_64) if( xine_mm_accel() & MM_ACCEL_X86_MMXEXT ) { tomsmocomp_filter_sse( output, outstride, data, bottom_field, second_field, width, height ); } else if( xine_mm_accel() & MM_ACCEL_X86_3DNOW ) { tomsmocomp_filter_3dnow( output, outstride, data, bottom_field, second_field, width, height ); } else { tomsmocomp_filter_mmx( output, outstride, data, bottom_field, second_field, width, height ); } #endif }
static void deinterlace_frame_di_tomsmocomp( uint8_t *output, int outstride, deinterlace_frame_data_t *data, int bottom_field, int second_field, int width, int height ) { TDeinterlaceInfo Info; TPicture Picture[ 8 ]; int stride = (width*2); int i; Info.FieldHeight = height / 2; Info.FrameHeight = height; Info.FrameWidth = width; Info.InputPitch = stride*2; Info.LineLength = stride; Info.OverlayPitch = outstride; Info.pMemcpy = fast_memcpy; if( bottom_field ) { Picture[ 0 ].pData = data->f0 + stride; Picture[ 0 ].Flags = PICTURE_INTERLACED_ODD; Picture[ 1 ].pData = data->f0; Picture[ 1 ].Flags = PICTURE_INTERLACED_EVEN; Picture[ 2 ].pData = data->f1 + stride; Picture[ 2 ].Flags = PICTURE_INTERLACED_ODD; Picture[ 3 ].pData = data->f1; Picture[ 3 ].Flags = PICTURE_INTERLACED_EVEN; Picture[ 4 ].pData = data->f2 + stride; Picture[ 4 ].Flags = PICTURE_INTERLACED_ODD; Picture[ 5 ].pData = data->f2; Picture[ 5 ].Flags = PICTURE_INTERLACED_EVEN; } else { Picture[ 0 ].pData = data->f0; Picture[ 0 ].Flags = PICTURE_INTERLACED_EVEN; Picture[ 1 ].pData = data->f1 + stride; Picture[ 1 ].Flags = PICTURE_INTERLACED_ODD; Picture[ 2 ].pData = data->f1; Picture[ 2 ].Flags = PICTURE_INTERLACED_EVEN; Picture[ 3 ].pData = data->f2 + stride; Picture[ 3 ].Flags = PICTURE_INTERLACED_ODD; Picture[ 4 ].pData = data->f2; Picture[ 4 ].Flags = PICTURE_INTERLACED_EVEN; } Info.Overlay = output; for( i = 0; i < MAX_PICTURE_HISTORY; i++ ) { Info.PictureHistory[ i ] = &(Picture[ i ]); } if( mm_accel() & MM_ACCEL_X86_MMXEXT ) { tomsmocomp_filter_sse( &Info ); } else if( mm_accel() & MM_ACCEL_X86_3DNOW ) { tomsmocomp_filter_3dnow( &Info ); } else { tomsmocomp_filter_mmx( &Info ); } }