@@ -45,10 +45,10 @@ struct encode_state;
45
45
46
46
/* The space required for slice header SLICE_STATE + header.
47
47
* Is it enough? */
48
- #define SLICE_HEADER 80
48
+ #define SLICE_HEADER 80
49
49
50
50
/* the space required for slice tail. */
51
- #define SLICE_TAIL 16
51
+ #define SLICE_TAIL 16
52
52
53
53
54
54
#define MFC_BATCHBUFFER_AVC_INTRA 0
@@ -81,25 +81,24 @@ struct encode_state;
81
81
#define BRC_PI_0_5 1.5707963267948966192313216916398
82
82
83
83
typedef enum {
84
- VME_V_PRED = 0 ,
85
- VME_H_PRED = 1 ,
86
- VME_DC_PRED = 2 ,
87
- VME_PL_PRED = 3 ,
84
+ VME_V_PRED = 0 ,
85
+ VME_H_PRED = 1 ,
86
+ VME_DC_PRED = 2 ,
87
+ VME_PL_PRED = 3 ,
88
88
89
- VME_MB_INTRA_MODE_COUNT
89
+ VME_MB_INTRA_MODE_COUNT
90
90
} VME_MB_INTRA_PRED_MODE ;
91
91
92
92
typedef enum {
93
- PAK_DC_PRED = 0 ,
94
- PAK_V_PRED = 1 ,
95
- PAK_H_PRED = 2 ,
96
- PAK_TM_PRED = 3 ,
93
+ PAK_DC_PRED = 0 ,
94
+ PAK_V_PRED = 1 ,
95
+ PAK_H_PRED = 2 ,
96
+ PAK_TM_PRED = 3 ,
97
97
98
- PAK_MB_INTRA_MODE_COUNT
98
+ PAK_MB_INTRA_MODE_COUNT
99
99
} VP8_PAK_MB_INTRA_PRED_MODE ;
100
100
101
- typedef enum
102
- {
101
+ typedef enum {
103
102
VME_B_V_PRED = 0 ,
104
103
VME_B_H_PRED = 1 ,
105
104
VME_B_DC_PRED = 2 ,
@@ -113,8 +112,7 @@ typedef enum
113
112
VME_B_INTRA_MODE_COUNT
114
113
} VME_BLOCK_INTRA_PRED_MODE ;
115
114
116
- typedef enum
117
- {
115
+ typedef enum {
118
116
PAK_B_DC_PRED = 0 ,
119
117
PAK_B_TM_PRED = 1 ,
120
118
PAK_B_VE_PRED = 2 ,
@@ -129,35 +127,30 @@ typedef enum
129
127
PAK_B_INTRA_MODE_COUNT
130
128
} VP8_PAK_BLOCK_INTRA_PRED_MODE ;
131
129
132
- typedef struct
133
- {
134
- int vme_intra_mb_mode ;
135
- int vp8_pak_intra_mb_mode ;
130
+ typedef struct {
131
+ int vme_intra_mb_mode ;
132
+ int vp8_pak_intra_mb_mode ;
136
133
} vp8_intra_mb_mode_map_t ;
137
134
138
- typedef struct
139
- {
140
- int vme_intra_block_mode ;
141
- int vp8_pak_intra_block_mode ;
135
+ typedef struct {
136
+ int vme_intra_block_mode ;
137
+ int vp8_pak_intra_block_mode ;
142
138
} vp8_intra_block_mode_map_t ;
143
139
144
- typedef enum _gen6_brc_status
145
- {
140
+ typedef enum _gen6_brc_status {
146
141
BRC_NO_HRD_VIOLATION = 0 ,
147
142
BRC_UNDERFLOW = 1 ,
148
143
BRC_OVERFLOW = 2 ,
149
144
BRC_UNDERFLOW_WITH_MAX_QP = 3 ,
150
145
BRC_OVERFLOW_WITH_MIN_QP = 4 ,
151
146
} gen6_brc_status ;
152
147
153
- struct gen6_mfc_avc_surface_aux
154
- {
148
+ struct gen6_mfc_avc_surface_aux {
155
149
dri_bo * dmv_top ;
156
150
dri_bo * dmv_bottom ;
157
151
};
158
152
159
- struct gen6_mfc_context
160
- {
153
+ struct gen6_mfc_context {
161
154
struct {
162
155
unsigned int width ;
163
156
unsigned int height ;
@@ -167,49 +160,49 @@ struct gen6_mfc_context
167
160
168
161
//MFX_PIPE_BUF_ADDR_STATE
169
162
struct {
170
- dri_bo * bo ;
171
- } post_deblocking_output ; //OUTPUT: reconstructed picture
172
-
173
- struct {
174
- dri_bo * bo ;
175
- } pre_deblocking_output ; //OUTPUT: reconstructed picture with deblocked
163
+ dri_bo * bo ;
164
+ } post_deblocking_output ; //OUTPUT: reconstructed picture
165
+
166
+ struct {
167
+ dri_bo * bo ;
168
+ } pre_deblocking_output ; //OUTPUT: reconstructed picture with deblocked
176
169
177
170
struct {
178
171
dri_bo * bo ;
179
172
} uncompressed_picture_source ; //INPUT: original compressed image
180
173
181
174
struct {
182
- dri_bo * bo ;
175
+ dri_bo * bo ;
183
176
} intra_row_store_scratch_buffer ; //INTERNAL:
184
177
185
178
struct {
186
179
dri_bo * bo ;
187
180
} macroblock_status_buffer ; //INTERNAL:
188
181
189
182
struct {
190
- dri_bo * bo ;
183
+ dri_bo * bo ;
191
184
} deblocking_filter_row_store_scratch_buffer ; //INTERNAL:
192
185
193
- struct {
194
- dri_bo * bo ;
186
+ struct {
187
+ dri_bo * bo ;
195
188
} reference_surfaces [MAX_MFC_REFERENCE_SURFACES ]; //INTERNAL: refrence surfaces
196
189
197
190
//MFX_IND_OBJ_BASE_ADDR_STATE
198
- struct {
191
+ struct {
199
192
dri_bo * bo ;
200
193
} mfc_indirect_mv_object ; //INPUT: the blocks' mv info
201
194
202
195
struct {
203
196
dri_bo * bo ;
204
197
int offset ;
205
198
int end_offset ;
206
- } mfc_indirect_pak_bse_object ; //OUTPUT: the compressed bitstream
199
+ } mfc_indirect_pak_bse_object ; //OUTPUT: the compressed bitstream
207
200
208
201
//MFX_BSP_BUF_BASE_ADDR_STATE
209
202
struct {
210
203
dri_bo * bo ;
211
204
} bsd_mpc_row_store_scratch_buffer ; //INTERNAL:
212
-
205
+
213
206
//MFX_AVC_DIRECTMODE_STATE
214
207
struct {
215
208
dri_bo * bo ;
@@ -223,7 +216,7 @@ struct gen6_mfc_context
223
216
unsigned char GrowInit ;
224
217
unsigned char GrowResistance ;
225
218
unsigned char ShrinkInit ;
226
- unsigned char ShrinkResistance ;
219
+ unsigned char ShrinkResistance ;
227
220
} bit_rate_control_context [3 ]; //INTERNAL: for I, P, B frames
228
221
229
222
struct {
@@ -257,8 +250,8 @@ struct gen6_mfc_context
257
250
int i_initial_cpb_removal_delay_length ;
258
251
int i_cpb_removal_delay_length ;
259
252
int i_dpb_output_delay_length ;
260
- }vui_hrd ;
261
-
253
+ } vui_hrd ;
254
+
262
255
struct {
263
256
unsigned char * vp8_frame_header ;
264
257
unsigned int frame_header_bit_count ;
@@ -280,15 +273,15 @@ struct gen6_mfc_context
280
273
unsigned char prob_intra ;
281
274
unsigned char prob_last ;
282
275
unsigned char prob_gf ;
283
-
276
+
284
277
dri_bo * frame_header_bo ;
285
278
dri_bo * intermediate_bo ;
286
279
dri_bo * final_frame_bo ;
287
280
dri_bo * stream_out_bo ;
288
281
dri_bo * coeff_probs_stream_in_bo ;
289
282
dri_bo * token_statistics_bo ;
290
283
dri_bo * mpc_row_store_bo ;
291
- }vp8_state ;
284
+ } vp8_state ;
292
285
293
286
//"buffered_QMatrix" will be used to buffer the QMatrix if the app sends one.
294
287
// Or else, we will load a default QMatrix from the driver for JPEG encode.
@@ -368,7 +361,7 @@ extern void intel_mfc_avc_pipeline_header_programing(VADriverContextP ctx,
368
361
struct intel_encoder_context * encoder_context ,
369
362
struct intel_batchbuffer * slice_batch );
370
363
371
- extern VAStatus intel_mfc_avc_prepare (VADriverContextP ctx ,
364
+ extern VAStatus intel_mfc_avc_prepare (VADriverContextP ctx ,
372
365
struct encode_state * encode_state ,
373
366
struct intel_encoder_context * encoder_context );
374
367
@@ -384,12 +377,12 @@ Bool gen8_mfc_context_init(VADriverContextP ctx, struct intel_encoder_context *e
384
377
385
378
extern void
386
379
intel_avc_slice_insert_packed_data (VADriverContextP ctx ,
387
- struct encode_state * encode_state ,
388
- struct intel_encoder_context * encoder_context ,
389
- int slice_index ,
390
- struct intel_batchbuffer * slice_batch );
380
+ struct encode_state * encode_state ,
381
+ struct intel_encoder_context * encoder_context ,
382
+ int slice_index ,
383
+ struct intel_batchbuffer * slice_batch );
391
384
392
385
extern
393
386
Bool gen9_mfc_context_init (VADriverContextP ctx , struct intel_encoder_context * encoder_context );
394
387
395
- #endif /* _GEN6_MFC_BCS_H_ */
388
+ #endif /* _GEN6_MFC_BCS_H_ */
0 commit comments