5 #include "condition.inc"
6 #include "loadbalance.h"
7 #include "maskautos.inc"
8 #include "maskauto.inc"
14 #define NUM_SPANS 4 /* starting number of spans to be allocated for */
26 class MaskPackage
: public LoadPackage
35 class MaskUnit
: public LoadClient
38 MaskUnit(MaskEngine
*engine
);
41 void process_package(LoadPackage
*package
);
43 void draw_line_clamped(int x1
, int y1
, int x2
, int y2
, int w
, int h
, int hoffset
);
44 void do_feather(VFrame
*output
,
49 int do_feather_2(VFrame
*output
,
55 void blur_strip(float *val_p
,
64 float bd_p
[5], bd_m
[5];
71 class MaskEngine
: public LoadServer
78 void do_mask(VFrame
*output
,
79 int64_t start_position
,
81 double project_frame_rate
,
82 MaskAutos
*keyframe_set
,
85 int points_equivalent(ArrayList
<MaskPoint
*> *new_points
,
86 ArrayList
<MaskPoint
*> *points
);
88 void delete_packages();
90 LoadClient
* new_client();
91 LoadPackage
* new_package();
96 // Temporary for feathering
98 ArrayList
<ArrayList
<MaskPoint
*>*> point_sets
;
100 float feather
; // gui feather
101 float realfeather
; // real feather
104 pthread_mutex_t stage1_finished_mutex
;
105 pthread_cond_t stage1_finished_cond
;
106 int stage1_finished_count
;
107 Mutex protect_data
; // protects the following members
108 int first_nonempty_rowspan
;
109 int last_nonempty_rowspan
;