~ubuntu-branches/ubuntu/hoary/kdemultimedia/hoary

« back to all changes in this revision

Viewing changes to mpeglib/lib/mpegplay/copyFunctions.h

  • Committer: Bazaar Package Importer
  • Author(s): Martin Schulze
  • Date: 2003-01-22 15:00:51 UTC
  • Revision ID: james.westby@ubuntu.com-20030122150051-uihwkdoxf15mi1tn
Tags: upstream-2.2.2
ImportĀ upstreamĀ versionĀ 2.2.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
  stores heavily used copy functions (makes mmx support easier)
 
3
  Copyright (C) 2000  Martin Vogt
 
4
 
 
5
  This program is free software; you can redistribute it and/or modify
 
6
  it under the terms of the GNU Library General Public License as published by
 
7
  the Free Software Foundation.
 
8
 
 
9
  For more information look at the file COPYRIGHT in this package
 
10
 
 
11
 */
 
12
 
 
13
 
 
14
#ifndef __COPYFUNCTIONS_H
 
15
#define __COPYFUNCTIONS_H
 
16
 
 
17
#define MAX_NEG_CROP 32768
 
18
#define NUM_CROP_ENTRIES (2048+2*MAX_NEG_CROP)
 
19
 
 
20
#include <iostream.h>
 
21
#include "../util/mmx.h"
 
22
 
 
23
extern "C" {
 
24
#include <string.h>
 
25
}
 
26
 
 
27
#include "copyFunctions_mmx.h"
 
28
 
 
29
 
 
30
class CopyFunctions {
 
31
 
 
32
  unsigned char *cm;
 
33
  int lmmx;
 
34
  unsigned char* cropTbl;
 
35
  CopyFunctions_ASM* copyFunctions_asm;
 
36
 
 
37
 public:
 
38
  CopyFunctions();
 
39
  ~CopyFunctions();
 
40
 
 
41
  /**
 
42
     We make sure, that during the whole construcion block
 
43
     we never (!!!) do float operations, thus we move
 
44
     the time consumin emms call really at the end of
 
45
     the whole reconstrucion/motion compensation
 
46
  */
 
47
 
 
48
  void startNOFloatSection();
 
49
  void endNOFloatSection();
 
50
 
 
51
  void copy8_byte(unsigned char* source1,
 
52
                  unsigned char* dest,int inc);
 
53
 
 
54
  void copy8_word(unsigned short* source1,
 
55
                  unsigned short* dest,int inc);
 
56
 
 
57
 
 
58
  void copy8_div2_nocrop(unsigned char* source1,
 
59
                         unsigned char* source2,
 
60
                         unsigned char* dest,int inc);
 
61
 
 
62
  void copy8_div2_destlinear_nocrop(unsigned char* source1,
 
63
                                    unsigned char* source2,
 
64
                                    unsigned char* dest,int inc);
 
65
  
 
66
  void copy16_div2_destlinear_nocrop(unsigned char* source1,
 
67
                                     unsigned char* source2,
 
68
                                     unsigned char* dest,int inc);
 
69
  
 
70
 
 
71
  void copy8_div4_nocrop(unsigned char* source1,
 
72
                         unsigned char* source2,
 
73
                         unsigned char* source3,
 
74
                         unsigned char* source4,
 
75
                         unsigned char* dest,int inc);
 
76
 
 
77
  void copy8_src1linear_crop(short* source1,unsigned char* dest,int inc);
 
78
 
 
79
  void copy8_src2linear_crop(unsigned char* source1,
 
80
                             short int* source2,
 
81
                             unsigned char* dest,int inc);
 
82
  void copy8_div2_src3linear_crop(unsigned char* source1,
 
83
                                  unsigned char* source2,
 
84
                                  short int* source3,
 
85
                                  unsigned char* dest,int inc);
 
86
 
 
87
  void copy8_div4_src5linear_crop(unsigned char* source1,
 
88
                                  unsigned char* source2,
 
89
                                  unsigned char* source3,
 
90
                                  unsigned char* source4,
 
91
                                  short int* source5,
 
92
                                  unsigned char* dest,int inc);
 
93
 
 
94
};
 
95
#endif