summaryrefslogtreecommitdiff
path: root/src/va.h
diff options
context:
space:
mode:
authorAustin Yuan <shengquan.yuan@intel.com>2009-11-09 09:57:32 +0800
committerAustin Yuan <shengquan.yuan@intel.com>2009-11-09 09:57:32 +0800
commit58f8cc670913b3338181136b5f7a865e0895cc04 (patch)
tree8ec9e6a65dfa5a71f8b6c9890b71f676767d11be /src/va.h
parent49f5210a0aa8d60000a91f69d7f8ad4a682cad53 (diff)
merge master->local-branch-testing2ww46.1-beta-rc220091109_5.1.0.0127
Signed-off-by: Austin Yuan <shengquan.yuan@intel.com>
Diffstat (limited to 'src/va.h')
-rwxr-xr-xsrc/va.h343
1 files changed, 180 insertions, 163 deletions
diff --git a/src/va.h b/src/va.h
index 2c2cbe6..d3f901b 100755
--- a/src/va.h
+++ b/src/va.h
@@ -53,6 +53,8 @@
* added VA_STATUS_ERROR_RESOLUTION_NOT_SUPPORTED
* rev 0.30 (03/01/2009 Jonathan Bian) - Added encoding support for H.264 BP and MPEG-4 SP and fixes
* for ISO C conformance.
+ * rev 0.31 (09/02/2009 Gwenole Beauchesne) - VC-1/H264 fields change for VDPAU and XvBA backend
+ * Application needs to relink with the new library.
*
* Acknowledgements:
* Some concepts borrowed from XvMC and XvImage.
@@ -63,6 +65,12 @@
#ifndef _VA_H_
#define _VA_H_
+#ifdef IN_LIBVA
+#include "va_version.h"
+#else
+#include <va/va_version.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -119,6 +127,7 @@ typedef int VAStatus; /* Return status type from functions */
#define VA_STATUS_ERROR_FLAG_NOT_SUPPORTED 0x00000011
#define VA_STATUS_ERROR_INVALID_PARAMETER 0x00000012
#define VA_STATUS_ERROR_RESOLUTION_NOT_SUPPORTED 0x00000013
+#define VA_STATUS_ERROR_UNIMPLEMENTED 0x00000014
#define VA_STATUS_ERROR_UNKNOWN 0xFFFFFFFF
/*
@@ -364,7 +373,8 @@ typedef VAGenericID VAContextID;
typedef VAGenericID VASurfaceID;
-#define VA_INVALID_SURFACE -1
+#define VA_INVALID_ID 0xffffffff
+#define VA_INVALID_SURFACE VA_INVALID_ID
/*
* vaCreateSurfaces - Create an array of surfaces used for decode and display
@@ -384,6 +394,21 @@ VAStatus vaCreateSurfaces (
VASurfaceID *surfaces /* out */
);
+/* Wrap a CI (camera imaging) frame as a VA surface to share captured video between camear
+ * and VA encode. With frame_id, VA driver need to call CI interfaces to get the information
+ * of the frame, and to determine if the frame can be wrapped as a VA surface
+ *
+ * Application should make sure the frame is idle before the frame is passed into VA stack
+ * and also a vaSyncSurface should be called before application tries to access the frame
+ * from CI stack
+ */
+VAStatus vaCreateSurfaceFromCIFrame (
+ VADisplay dpy,
+ unsigned long frame_id,
+ VASurfaceID *surface /* out */
+);
+
+
/*
* vaDestroySurfaces - Destroy resources associated with surfaces.
* Surfaces can only be destroyed after the context associated has been
@@ -465,6 +490,27 @@ typedef enum
} VABufferType;
+/*
+ * There will be cases where the bitstream buffer will not have enough room to hold
+ * the data for the entire slice, and the following flags will be used in the slice
+ * parameter to signal to the server for the possible cases.
+ * If a slice parameter buffer and slice data buffer pair is sent to the server with
+ * the slice data partially in the slice data buffer (BEGIN and MIDDLE cases below),
+ * then a slice parameter and data buffer needs to be sent again to complete this slice.
+ */
+#define VA_SLICE_DATA_FLAG_ALL 0x00 /* whole slice is in the buffer */
+#define VA_SLICE_DATA_FLAG_BEGIN 0x01 /* The beginning of the slice is in the buffer but the end if not */
+#define VA_SLICE_DATA_FLAG_MIDDLE 0x02 /* Neither beginning nor end of the slice is in the buffer */
+#define VA_SLICE_DATA_FLAG_END 0x04 /* end of the slice is in the buffer */
+
+/* Codec-independent Slice Parameter Buffer base */
+typedef struct _VASliceParameterBufferBase
+{
+ unsigned int slice_data_size; /* number of bytes in the slice data buffer for this slice */
+ unsigned int slice_data_offset; /* the offset to the first byte of slice data */
+ unsigned int slice_data_flag; /* see VA_SLICE_DATA_FLAG_XXX definitions */
+} VASliceParameterBufferBase;
+
/****************************
* MPEG-2 data structures
****************************/
@@ -516,19 +562,6 @@ typedef struct _VAIQMatrixBufferMPEG2
unsigned char chroma_non_intra_quantiser_matrix[64];
} VAIQMatrixBufferMPEG2;
-/*
- * There will be cases where the bitstream buffer will not have enough room to hold
- * the data for the entire slice, and the following flags will be used in the slice
- * parameter to signal to the server for the possible cases.
- * If a slice parameter buffer and slice data buffer pair is sent to the server with
- * the slice data partially in the slice data buffer (BEGIN and MIDDLE cases below),
- * then a slice parameter and data buffer needs to be sent again to complete this slice.
- */
-#define VA_SLICE_DATA_FLAG_ALL 0x00 /* whole slice is in the buffer */
-#define VA_SLICE_DATA_FLAG_BEGIN 0x01 /* The beginning of the slice is in the buffer but the end if not */
-#define VA_SLICE_DATA_FLAG_MIDDLE 0x02 /* Neither beginning nor end of the slice is in the buffer */
-#define VA_SLICE_DATA_FLAG_END 0x04 /* end of the slice is in the buffer */
-
/* MPEG-2 Slice Parameter Buffer */
typedef struct _VASliceParameterBufferMPEG2
{
@@ -557,7 +590,7 @@ typedef struct _VAMacroblockParameterBufferMPEG2
unsigned int field_motion_type : 2;
unsigned int dct_type : 1;
} bits;
- unsigned char value;
+ unsigned int value;
} macroblock_modes;
unsigned char motion_vertical_field_select;
/*
@@ -611,18 +644,18 @@ typedef struct _VAPictureParameterBufferMPEG4
VASurfaceID backward_reference_picture;
union {
struct {
- unsigned char short_video_header : 1;
- unsigned char chroma_format : 2;
- unsigned char interlaced : 1;
- unsigned char obmc_disable : 1;
- unsigned char sprite_enable : 2;
- unsigned char sprite_warping_accuracy : 2;
- unsigned char quant_type : 1;
- unsigned char quarter_sample : 1;
- unsigned char data_partitioned : 1;
- unsigned char reversible_vlc : 1;
+ unsigned int short_video_header : 1;
+ unsigned int chroma_format : 2;
+ unsigned int interlaced : 1;
+ unsigned int obmc_disable : 1;
+ unsigned int sprite_enable : 2;
+ unsigned int sprite_warping_accuracy : 2;
+ unsigned int quant_type : 1;
+ unsigned int quarter_sample : 1;
+ unsigned int data_partitioned : 1;
+ unsigned int reversible_vlc : 1;
} bits;
- unsigned short value;
+ unsigned int value;
} vol_fields;
unsigned char no_of_sprite_warping_points;
short sprite_trajectory_du[3];
@@ -630,14 +663,14 @@ typedef struct _VAPictureParameterBufferMPEG4
unsigned char quant_precision;
union {
struct {
- unsigned char vop_coding_type : 2;
- unsigned char backward_reference_vop_coding_type : 2;
- unsigned char vop_rounding_type : 1;
- unsigned char intra_dc_vlc_thr : 3;
- unsigned char top_field_first : 1;
- unsigned char alternate_vertical_scan_flag : 1;
+ unsigned int vop_coding_type : 2;
+ unsigned int backward_reference_vop_coding_type : 2;
+ unsigned int vop_rounding_type : 1;
+ unsigned int intra_dc_vlc_thr : 3;
+ unsigned int top_field_first : 1;
+ unsigned int alternate_vertical_scan_flag : 1;
} bits;
- unsigned short value;
+ unsigned int value;
} vop_fields;
unsigned char vop_fcode_forward;
unsigned char vop_fcode_backward;
@@ -707,28 +740,41 @@ typedef struct _VAPictureParameterBufferVC1
/* sequence layer for AP or meta data for SP and MP */
union {
struct {
- unsigned char interlace : 1; /* SEQUENCE_LAYER::INTERLACE */
- unsigned char syncmarker : 1;/* METADATA::SYNCMARKER */
- unsigned char overlap : 1;/* METADATA::OVERLAP */
+ unsigned int pulldown : 1; /* SEQUENCE_LAYER::PULLDOWN */
+ unsigned int interlace : 1; /* SEQUENCE_LAYER::INTERLACE */
+ unsigned int tfcntrflag : 1; /* SEQUENCE_LAYER::TFCNTRFLAG */
+ unsigned int finterpflag : 1; /* SEQUENCE_LAYER::FINTERPFLAG */
+ unsigned int psf : 1; /* SEQUENCE_LAYER::PSF */
+ unsigned int multires : 1; /* METADATA::MULTIRES */
+ unsigned int overlap : 1; /* METADATA::OVERLAP */
+ unsigned int syncmarker : 1; /* METADATA::SYNCMARKER */
+ unsigned int rangered : 1; /* METADATA::RANGERED */
+ unsigned int max_b_frames : 3; /* METADATA::MAXBFRAMES */
} bits;
- unsigned char value;
+ unsigned int value;
} sequence_fields;
unsigned short coded_width; /* ENTRY_POINT_LAYER::CODED_WIDTH */
unsigned short coded_height; /* ENTRY_POINT_LAYER::CODED_HEIGHT */
- unsigned char closed_entry; /* ENTRY_POINT_LAYER::CLOSED_ENTRY */
- unsigned char broken_link; /* ENTRY_POINT_LAYER::BROKEN_LINK */
- unsigned char loopfilter; /* ENTRY_POINT_LAYER::LOOPFILTER */
+ union {
+ struct {
+ unsigned int broken_link : 1; /* ENTRY_POINT_LAYER::BROKEN_LINK */
+ unsigned int closed_entry : 1; /* ENTRY_POINT_LAYER::CLOSED_ENTRY */
+ unsigned int panscan_flag : 1; /* ENTRY_POINT_LAYER::PANSCAN_FLAG */
+ unsigned int loopfilter : 1; /* ENTRY_POINT_LAYER::LOOPFILTER */
+ } bits;
+ unsigned int value;
+ } entrypoint_fields;
unsigned char conditional_overlap_flag; /* ENTRY_POINT_LAYER::CONDOVER */
unsigned char fast_uvmc_flag; /* ENTRY_POINT_LAYER::FASTUVMC */
union {
struct {
- unsigned char luma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPY_FLAG */
- unsigned char luma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPY */
- unsigned char chroma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPUV_FLAG */
- unsigned char chroma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPUV */
+ unsigned int luma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPY_FLAG */
+ unsigned int luma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPY */
+ unsigned int chroma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPUV_FLAG */
+ unsigned int chroma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPUV */
} bits;
- unsigned char value;
+ unsigned int value;
} range_mapping_fields;
unsigned char b_picture_fraction; /* PICTURE_LAYER::BFRACTION */
@@ -742,88 +788,88 @@ typedef struct _VAPictureParameterBufferVC1
unsigned char luma_shift; /* PICTURE_LAYER::LUMSHIFT */
union {
struct {
- unsigned char picture_type : 2; /* PICTURE_LAYER::PTYPE */
- unsigned char frame_coding_mode : 3; /* PICTURE_LAYER::FCM */
- unsigned char top_field_first : 1; /* PICTURE_LAYER::TFF */
- unsigned char is_first_field : 1; /* set to 1 if it is the first field */
- unsigned char intensity_compensation : 1; /* PICTURE_LAYER::INTCOMP */
+ unsigned int picture_type : 3; /* PICTURE_LAYER::PTYPE */
+ unsigned int frame_coding_mode : 3; /* PICTURE_LAYER::FCM */
+ unsigned int top_field_first : 1; /* PICTURE_LAYER::TFF */
+ unsigned int is_first_field : 1; /* set to 1 if it is the first field */
+ unsigned int intensity_compensation : 1; /* PICTURE_LAYER::INTCOMP */
} bits;
- unsigned char value;
+ unsigned int value;
} picture_fields;
union {
struct {
- unsigned char mv_type_mb : 1; /* PICTURE::MVTYPEMB */
- unsigned char direct_mb : 1; /* PICTURE::DIRECTMB */
- unsigned char skip_mb : 1; /* PICTURE::SKIPMB */
- unsigned char field_tx : 1; /* PICTURE::FIELDTX */
- unsigned char forward_mb : 1; /* PICTURE::FORWARDMB */
- unsigned char ac_pred : 1; /* PICTURE::ACPRED */
- unsigned char overflags : 1; /* PICTURE::OVERFLAGS */
+ unsigned int mv_type_mb : 1; /* PICTURE::MVTYPEMB */
+ unsigned int direct_mb : 1; /* PICTURE::DIRECTMB */
+ unsigned int skip_mb : 1; /* PICTURE::SKIPMB */
+ unsigned int field_tx : 1; /* PICTURE::FIELDTX */
+ unsigned int forward_mb : 1; /* PICTURE::FORWARDMB */
+ unsigned int ac_pred : 1; /* PICTURE::ACPRED */
+ unsigned int overflags : 1; /* PICTURE::OVERFLAGS */
} flags;
- unsigned char value;
+ unsigned int value;
} raw_coding;
union {
struct {
- unsigned char bp_mv_type_mb : 1; /* PICTURE::MVTYPEMB */
- unsigned char bp_direct_mb : 1; /* PICTURE::DIRECTMB */
- unsigned char bp_skip_mb : 1; /* PICTURE::SKIPMB */
- unsigned char bp_field_tx : 1; /* PICTURE::FIELDTX */
- unsigned char bp_forward_mb : 1; /* PICTURE::FORWARDMB */
- unsigned char bp_ac_pred : 1; /* PICTURE::ACPRED */
- unsigned char bp_overflags : 1; /* PICTURE::OVERFLAGS */
+ unsigned int bp_mv_type_mb : 1; /* PICTURE::MVTYPEMB */
+ unsigned int bp_direct_mb : 1; /* PICTURE::DIRECTMB */
+ unsigned int bp_skip_mb : 1; /* PICTURE::SKIPMB */
+ unsigned int bp_field_tx : 1; /* PICTURE::FIELDTX */
+ unsigned int bp_forward_mb : 1; /* PICTURE::FORWARDMB */
+ unsigned int bp_ac_pred : 1; /* PICTURE::ACPRED */
+ unsigned int bp_overflags : 1; /* PICTURE::OVERFLAGS */
} flags;
- unsigned char value;
+ unsigned int value;
} bitplane_present; /* signal what bitplane is being passed via the bitplane buffer */
union {
struct {
- unsigned char reference_distance_flag : 1;/* PICTURE_LAYER::REFDIST_FLAG */
- unsigned char reference_distance : 5;/* PICTURE_LAYER::REFDIST */
- unsigned char num_reference_pictures: 1;/* PICTURE_LAYER::NUMREF */
- unsigned char reference_field_pic_indicator : 1;/* PICTURE_LAYER::REFFIELD */
+ unsigned int reference_distance_flag : 1;/* PICTURE_LAYER::REFDIST_FLAG */
+ unsigned int reference_distance : 5;/* PICTURE_LAYER::REFDIST */
+ unsigned int num_reference_pictures: 1;/* PICTURE_LAYER::NUMREF */
+ unsigned int reference_field_pic_indicator : 1;/* PICTURE_LAYER::REFFIELD */
} bits;
- unsigned short value;
+ unsigned int value;
} reference_fields;
union {
struct {
- unsigned char mv_mode : 3; /* PICTURE_LAYER::MVMODE */
- unsigned char mv_mode2 : 3; /* PICTURE_LAYER::MVMODE2 */
- unsigned char mv_table : 3; /* PICTURE_LAYER::MVTAB/IMVTAB */
- unsigned char two_mv_block_pattern_table: 2; /* PICTURE_LAYER::2MVBPTAB */
- unsigned char four_mv_switch : 1; /* PICTURE_LAYER::4MVSWITCH */
- unsigned char four_mv_block_pattern_table : 2; /* PICTURE_LAYER::4MVBPTAB */
- unsigned char extended_mv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_MV */
- unsigned char extended_mv_range : 2; /* PICTURE_LAYER::MVRANGE */
- unsigned char extended_dmv_flag : 1; /* ENTRY_POCHAR_LAYER::EXTENDED_DMV */
- unsigned char extended_dmv_range : 2; /* PICTURE_LAYER::DMVRANGE */
+ unsigned int mv_mode : 3; /* PICTURE_LAYER::MVMODE */
+ unsigned int mv_mode2 : 3; /* PICTURE_LAYER::MVMODE2 */
+ unsigned int mv_table : 3; /* PICTURE_LAYER::MVTAB/IMVTAB */
+ unsigned int two_mv_block_pattern_table: 2; /* PICTURE_LAYER::2MVBPTAB */
+ unsigned int four_mv_switch : 1; /* PICTURE_LAYER::4MVSWITCH */
+ unsigned int four_mv_block_pattern_table : 2; /* PICTURE_LAYER::4MVBPTAB */
+ unsigned int extended_mv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_MV */
+ unsigned int extended_mv_range : 2; /* PICTURE_LAYER::MVRANGE */
+ unsigned int extended_dmv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_DMV */
+ unsigned int extended_dmv_range : 2; /* PICTURE_LAYER::DMVRANGE */
} bits;
unsigned int value;
} mv_fields;
union {
struct {
- unsigned char dquant : 2; /* ENTRY_POINT_LAYER::DQUANT */
- unsigned char quantizer : 2; /* ENTRY_POINT_LAYER::QUANTIZER */
- unsigned char half_qp : 1; /* PICTURE_LAYER::HALFQP */
- unsigned char pic_quantizer_scale : 5;/* PICTURE_LAYER::PQUANT */
- unsigned char pic_quantizer_type : 1;/* PICTURE_LAYER::PQUANTIZER */
- unsigned char dq_frame : 1; /* VOPDQUANT::DQUANTFRM */
- unsigned char dq_profile : 2; /* VOPDQUANT::DQPROFILE */
- unsigned char dq_sb_edge : 2; /* VOPDQUANT::DQSBEDGE */
- unsigned char dq_db_edge : 2; /* VOPDQUANT::DQDBEDGE */
- unsigned char dq_binary_level : 1; /* VOPDQUANT::DQBILEVEL */
- unsigned char alt_pic_quantizer : 5;/* VOPDQUANT::ALTPQUANT */
+ unsigned int dquant : 2; /* ENTRY_POINT_LAYER::DQUANT */
+ unsigned int quantizer : 2; /* ENTRY_POINT_LAYER::QUANTIZER */
+ unsigned int half_qp : 1; /* PICTURE_LAYER::HALFQP */
+ unsigned int pic_quantizer_scale : 5;/* PICTURE_LAYER::PQUANT */
+ unsigned int pic_quantizer_type : 1;/* PICTURE_LAYER::PQUANTIZER */
+ unsigned int dq_frame : 1; /* VOPDQUANT::DQUANTFRM */
+ unsigned int dq_profile : 2; /* VOPDQUANT::DQPROFILE */
+ unsigned int dq_sb_edge : 2; /* VOPDQUANT::DQSBEDGE */
+ unsigned int dq_db_edge : 2; /* VOPDQUANT::DQDBEDGE */
+ unsigned int dq_binary_level : 1; /* VOPDQUANT::DQBILEVEL */
+ unsigned int alt_pic_quantizer : 5;/* VOPDQUANT::ALTPQUANT */
} bits;
- unsigned long value;
+ unsigned int value;
} pic_quantizer_fields;
union {
struct {
- unsigned char variable_sized_transform_flag : 1;/* ENTRY_POINT_LAYER::VSTRANSFORM */
- unsigned char mb_level_transform_type_flag : 1;/* PICTURE_LAYER::TTMBF */
- unsigned char frame_level_transform_type : 2;/* PICTURE_LAYER::TTFRM */
- unsigned char transform_ac_codingset_idx1 : 2;/* PICTURE_LAYER::TRANSACFRM */
- unsigned char transform_ac_codingset_idx2 : 2;/* PICTURE_LAYER::TRANSACFRM2 */
- unsigned char intra_transform_dc_table : 1;/* PICTURE_LAYER::TRANSDCTAB */
+ unsigned int variable_sized_transform_flag : 1;/* ENTRY_POINT_LAYER::VSTRANSFORM */
+ unsigned int mb_level_transform_type_flag : 1;/* PICTURE_LAYER::TTMBF */
+ unsigned int frame_level_transform_type : 2;/* PICTURE_LAYER::TTFRM */
+ unsigned int transform_ac_codingset_idx1 : 2;/* PICTURE_LAYER::TRANSACFRM */
+ unsigned int transform_ac_codingset_idx2 : 2;/* PICTURE_LAYER::TRANSACFRM2 */
+ unsigned int intra_transform_dc_table : 1;/* PICTURE_LAYER::TRANSDCTAB */
} bits;
- unsigned short value;
+ unsigned int value;
} transform_fields;
} VAPictureParameterBufferVC1;
@@ -867,6 +913,7 @@ This is simplely a buffer containing raw bit-stream bytes
typedef struct _VAPictureH264
{
VASurfaceID picture_id;
+ unsigned int frame_idx;
unsigned int flags;
unsigned int TopFieldOrderCnt;
unsigned int BottomFieldOrderCnt;
@@ -894,30 +941,41 @@ typedef struct _VAPictureParameterBufferH264
unsigned char num_ref_frames;
union {
struct {
- unsigned char chroma_format_idc : 2;
- unsigned char residual_colour_transform_flag : 1;
- unsigned char frame_mbs_only_flag : 1;
- unsigned char mb_adaptive_frame_field_flag : 1;
- unsigned char direct_8x8_inference_flag : 1;
- unsigned char MinLumaBiPredSize8x8 : 1; /* see A.3.3.2 */
+ unsigned int chroma_format_idc : 2;
+ unsigned int residual_colour_transform_flag : 1;
+ unsigned int gaps_in_frame_num_value_allowed_flag : 1;
+ unsigned int frame_mbs_only_flag : 1;
+ unsigned int mb_adaptive_frame_field_flag : 1;
+ unsigned int direct_8x8_inference_flag : 1;
+ unsigned int MinLumaBiPredSize8x8 : 1; /* see A.3.3.2 */
+ unsigned int log2_max_frame_num_minus4 : 4;
+ unsigned int pic_order_cnt_type : 2;
+ unsigned int log2_max_pic_order_cnt_lsb_minus4 : 4;
+ unsigned int delta_pic_order_always_zero_flag : 1;
} bits;
- unsigned char value;
+ unsigned int value;
} seq_fields;
unsigned char num_slice_groups_minus1;
unsigned char slice_group_map_type;
+ unsigned short slice_group_change_rate_minus1;
signed char pic_init_qp_minus26;
+ signed char pic_init_qs_minus26;
signed char chroma_qp_index_offset;
signed char second_chroma_qp_index_offset;
union {
struct {
- unsigned char entropy_coding_mode_flag : 1;
- unsigned char weighted_pred_flag : 1;
- unsigned char weighted_bipred_idc : 2;
- unsigned char transform_8x8_mode_flag : 1;
- unsigned char field_pic_flag : 1;
- unsigned char constrained_intra_pred_flag : 1;
+ unsigned int entropy_coding_mode_flag : 1;
+ unsigned int weighted_pred_flag : 1;
+ unsigned int weighted_bipred_idc : 2;
+ unsigned int transform_8x8_mode_flag : 1;
+ unsigned int field_pic_flag : 1;
+ unsigned int constrained_intra_pred_flag : 1;
+ unsigned int pic_order_present_flag : 1;
+ unsigned int deblocking_filter_control_present_flag : 1;
+ unsigned int redundant_pic_cnt_present_flag : 1;
+ unsigned int reference_pic_flag : 1; /* nal_ref_idc != 0 */
} bits;
- unsigned char value;
+ unsigned int value;
} pic_fields;
unsigned short frame_num;
} VAPictureParameterBufferH264;
@@ -991,10 +1049,10 @@ typedef struct _VAEncSliceParameterBuffer
unsigned int slice_height; /* slice height measured in MB */
union {
struct {
- unsigned char is_intra : 1;
- unsigned char disable_deblocking_filter_idc : 2;
+ unsigned int is_intra : 1;
+ unsigned int disable_deblocking_filter_idc : 2;
} bits;
- unsigned char value;
+ unsigned int value;
} slice_flags;
} VAEncSliceParameterBuffer;
@@ -1203,18 +1261,17 @@ Synchronization
*/
VAStatus vaSyncSurface (
VADisplay dpy,
- VAContextID context,
VASurfaceID render_target
);
typedef enum
{
- VASurfaceRendering = 0, /* Rendering in progress */
- VASurfaceDisplaying = 1, /* Displaying in progress (not safe to render into it) */
+ VASurfaceRendering = 1, /* Rendering in progress */
+ VASurfaceDisplaying = 2, /* Displaying in progress (not safe to render into it) */
/* this status is useful if surface is used as the source */
/* of an overlay */
- VASurfaceReady = 2, /* not being rendered or displayed */
- VASurfaceSkipped = 4 /* Indicate a skipped frame during encode */
+ VASurfaceReady = 4, /* not being rendered or displayed */
+ VASurfaceSkipped = 8 /* Indicate a skipped frame during encode */
} VASurfaceStatus;
/*
@@ -1379,8 +1436,6 @@ VAStatus vaGetImage (
* Image must be in a format supported by the implementation
* Returns a VA_STATUS_ERROR_SURFACE_BUSY if the surface
* shouldn't be rendered into when this is called
- * The source and destionation width and height are the same and
- * no scaling is performed with this operation.
*/
VAStatus vaPutImage (
VADisplay dpy,
@@ -1388,22 +1443,6 @@ VAStatus vaPutImage (
VAImageID image,
int src_x,
int src_y,
- unsigned int width,
- unsigned int height,
- int dest_x,
- int dest_y
-);
-
-/*
- * Similar to vaPutImage but with additional destination width
- * and height arguments to enable scaling
- */
-VAStatus vaPutImage2 (
- VADisplay dpy,
- VASurfaceID surface,
- VAImageID image,
- int src_x,
- int src_y,
unsigned int src_width,
unsigned int src_height,
int dest_x,
@@ -1552,28 +1591,6 @@ VAStatus vaAssociateSubpicture (
int num_surfaces,
short src_x, /* upper left offset in subpicture */
short src_y,
- short dest_x, /* upper left offset in surface */
- short dest_y,
- unsigned short width,
- unsigned short height,
- /*
- * whether to enable chroma-keying or global-alpha
- * see VA_SUBPICTURE_XXX values
- */
- unsigned int flags
-);
-
-/*
- * Similar to vaAssociateSubpicture but with additional destination width
- * and height to enable scaling
- */
-VAStatus vaAssociateSubpicture2 (
- VADisplay dpy,
- VASubpictureID subpicture,
- VASurfaceID *target_surfaces,
- int num_surfaces,
- short src_x, /* upper left offset in subpicture */
- short src_y,
unsigned short src_width,
unsigned short src_height,
short dest_x, /* upper left offset in surface */