VA-API  2.8.0
va_enc_jpeg.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2007-2013 Intel Corporation. All Rights Reserved.
3  *
4  * Permission is hereby granted, free of charge, to any person obtaining a
5  * copy of this software and associated documentation files (the
6  * "Software"), to deal in the Software without restriction, including
7  * without limitation the rights to use, copy, modify, merge, publish,
8  * distribute, sub license, and/or sell copies of the Software, and to
9  * permit persons to whom the Software is furnished to do so, subject to
10  * the following conditions:
11  *
12  * The above copyright notice and this permission notice (including the
13  * next paragraph) shall be included in all copies or substantial portions
14  * of the Software.
15  *
16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
17  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
19  * IN NO EVENT SHALL INTEL AND/OR ITS SUPPLIERS BE LIABLE FOR
20  * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21  * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22  * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23  */
24 
32 #ifndef VA_ENC_JPEG_H
33 #define VA_ENC_JPEG_H
34 
35 #ifdef __cplusplus
36 extern "C" {
37 #endif
38 
51 typedef struct _VAEncPictureParameterBufferJPEG
52 {
54  VASurfaceID reconstructed_picture;
56  uint16_t picture_width;
58  uint16_t picture_height;
61 
66  union {
67  struct {
72  uint32_t profile : 2;
77  uint32_t progressive : 1;
82  uint32_t huffman : 1;
87  uint32_t interleaved : 1;
92  uint32_t differential : 1;
93  } bits;
94  uint32_t value;
95  } pic_flags;
96 
100  uint8_t num_scan;
102  uint16_t num_components;
104  uint8_t component_id[4];
106  uint8_t quantiser_table_selector[4];
108  uint8_t quality;
109 
111  uint32_t va_reserved[VA_PADDING_LOW];
113 
114 
121 typedef struct _VAEncSliceParameterBufferJPEG {
125  uint16_t num_components;
126  struct {
133  } components[4];
134 
136  uint32_t va_reserved[VA_PADDING_LOW];
138 
143 typedef struct _VAQMatrixBufferJPEG
144 {
150  uint8_t lum_quantiser_matrix[64];
152  uint8_t chroma_quantiser_matrix[64];
153 
155  uint32_t va_reserved[VA_PADDING_LOW];
157 
160 #ifdef __cplusplus
161 }
162 #endif
163 
164 #endif /* VA_ENC_JPEG_H */
uint8_t quality
number from 1 to 100 that specifies quality of image.
Definition: va_enc_jpeg.h:108
uint16_t picture_width
picture width.
Definition: va_enc_jpeg.h:56
uint16_t picture_height
picture height.
Definition: va_enc_jpeg.h:58
uint16_t num_components
number of image components in frame.
Definition: va_enc_jpeg.h:102
uint8_t component_selector
Scan component selector (Csj).
Definition: va_enc_jpeg.h:128
uint32_t profile
profile: 0 - Baseline, 1 - Extended, 2 - Lossless, 3 - Hierarchical
Definition: va_enc_jpeg.h:72
uint32_t interleaved
interleaved: 0 - non interleaved, 1 - interleaved
Definition: va_enc_jpeg.h:87
uint16_t restart_interval
Restart interval definition (Ri).
Definition: va_enc_jpeg.h:123
int32_t load_chroma_quantiser_matrix
load chroma quantization table.
Definition: va_enc_jpeg.h:148
uint32_t progressive
progressive: 0 - sequential, 1 - extended, 2 - progressive
Definition: va_enc_jpeg.h:77
uint32_t huffman
huffman: 0 - arithmetic, 1 - huffman
Definition: va_enc_jpeg.h:82
VAGenericID VABufferID
Definition: va.h:1647
Slice parameter for JPEG encoding.
Definition: va_enc_jpeg.h:121
Quantization table for JPEG encoding.
Definition: va_enc_jpeg.h:143
int32_t load_lum_quantiser_matrix
load luma quantization table.
Definition: va_enc_jpeg.h:146
JPEG Encoding Picture Parameter Buffer Structure.
Definition: va_enc_jpeg.h:51
VABufferID coded_buf
holds coded data.
Definition: va_enc_jpeg.h:60
uint8_t sample_bit_depth
number of bits per sample.
Definition: va_enc_jpeg.h:98
uint16_t num_components
number of image components in a scan.
Definition: va_enc_jpeg.h:125
uint8_t num_scan
total number of scans in image.
Definition: va_enc_jpeg.h:100
uint8_t dc_table_selector
DC entropy coding table selector (Tdj).
Definition: va_enc_jpeg.h:130
#define VA_PADDING_LOW
Definition: va.h:260
uint32_t differential
differential: 0 - non differential, 1 - differential
Definition: va_enc_jpeg.h:92
uint8_t ac_table_selector
AC entropy coding table selector (Taj).
Definition: va_enc_jpeg.h:132
VASurfaceID reconstructed_picture
holds reconstructed picture.
Definition: va_enc_jpeg.h:54