~ubuntu-branches/ubuntu/lucid/schroedinger/lucid

« back to all changes in this revision

Viewing changes to schroedinger/schromotion.h

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2010-04-14 10:58:46 UTC
  • mfrom: (1.1.9 upstream)
  • Revision ID: james.westby@ubuntu.com-20100414105846-p35xtwwse4bf2xvw
Tags: 1.0.9.is.1.0.8-0ubuntu1
Upload 1.0.8 for lucid since the new version requires orc which is in 
universe and not ready to be promoted yet (the next version will change
the abi and it's still a new technology) (lp: #562735)

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
 
5
5
#include <schroedinger/schroframe.h>
6
6
#include <schroedinger/schroparams.h>
7
 
#ifdef SCHRO_ENABLE_UNSTABLE_API
8
 
#include <orc/orc.h>
9
 
#endif
10
7
 
11
8
SCHRO_BEGIN_DECLS
12
9
 
15
12
typedef struct _SchroMotionField SchroMotionField;
16
13
typedef struct _SchroMotion SchroMotion;
17
14
typedef struct _SchroMotionScan SchroMotionScan;
18
 
typedef struct _SchroMotionFuncs SchroMotionFuncs;
19
15
 
20
16
#ifdef SCHRO_ENABLE_UNSTABLE_API
21
17
struct _SchroMotionVector {
24
20
  unsigned int split : 2;
25
21
  unsigned int unused : 3;
26
22
  unsigned int scan : 8;
27
 
  uint32_t metric;
28
 
  uint32_t chroma_metric;
 
23
  unsigned int metric : 16;
29
24
  union {
30
25
    struct {
31
26
      int16_t dx[2];
43
38
  SchroMotionVector *motion_vectors;
44
39
};
45
40
 
46
 
struct _SchroMotionFuncs {
47
 
  OrcProgram *block_accumulate;
48
 
  OrcProgram *block_accumulate_scaled;
49
 
  OrcProgram *block_accumulate_dc;
50
 
  OrcProgram *block_accumulate_avg;
51
 
  OrcProgram *block_accumulate_biref;
52
 
};
53
 
 
54
41
struct _SchroMotion {
55
42
  SchroUpsampledFrame *src1;
56
43
  SchroUpsampledFrame *src2;
83
70
  int height;
84
71
  int max_fast_x;
85
72
  int max_fast_y;
86
 
 
87
 
  schro_bool simple_weight;
88
 
  schro_bool oneref_noscale;
89
73
};
90
74
 
91
75
#define SCHRO_MOTION_GET_BLOCK(motion,x,y) \
96
80
void schro_motion_free (SchroMotion *motion);
97
81
 
98
82
int schro_motion_verify (SchroMotion *mf);
99
 
void schro_motion_render_ref (SchroMotion *motion, SchroFrame *dest,
100
 
    SchroFrame *addframe, int add, SchroFrame *output_frame);
101
 
void schro_motion_render (SchroMotion *motion, SchroFrame *dest,
102
 
    SchroFrame *addframe, int add, SchroFrame *output_frame);
 
83
void schro_motion_render_ref (SchroMotion *motion, SchroFrame *dest);
 
84
void schro_motion_render (SchroMotion *motion, SchroFrame *dest);
103
85
void schro_motion_init_obmc_weight (SchroMotion *motion);
104
86
 
105
 
void schro_motion_render_fast (SchroMotion *motion, SchroFrame *dest,
106
 
    SchroFrame *addframe, int add, SchroFrame *output_frame);
 
87
void schro_motion_render_fast (SchroMotion *motion, SchroFrame *dest);
107
88
int schro_motion_render_fast_allowed (SchroMotion *motion);
108
89
 
109
 
void schro_mf_vector_prediction (SchroMotionField* mf,
110
 
    int x, int y, int *pred_x, int *pred_y, int mode);
111
 
 
112
90
void schro_motion_vector_prediction (SchroMotion *motion,
113
91
    int x, int y, int *pred_x, int *pred_y, int mode);
114
92
int schro_motion_split_prediction (SchroMotion *motion, int x, int y);