This a set of small code style fixes detected as-is by gst-indent.
Signed-off-by: Víctor Manuel Jáquez Leal <victorx.jaquez@intel.com>
GstVaapiCodecObject *obj;
GstVaapiCodecObjectConstructorArgs args;
- obj =
- (GstVaapiCodecObject *)
+ obj = (GstVaapiCodecObject *)
gst_vaapi_mini_object_new0 (GST_VAAPI_MINI_OBJECT_CLASS (object_class));
if (!obj)
return NULL;
gst_vaapi_coded_buffer_pool_class (void)
{
static const GstVaapiVideoPoolClass GstVaapiCodedBufferPoolClass = {
- { sizeof (GstVaapiCodedBufferPool),
- (GDestroyNotify)coded_buffer_pool_finalize },
-
+ {sizeof (GstVaapiCodedBufferPool),
+ (GDestroyNotify) coded_buffer_pool_finalize}
+ ,
.alloc_object = coded_buffer_pool_alloc_object
};
return GST_VAAPI_MINI_OBJECT_CLASS (&GstVaapiCodedBufferPoolClass);
{
static const GstVaapiMiniObjectClass GstVaapiCodedBufferProxyClass = {
sizeof (GstVaapiCodedBufferProxy),
- (GDestroyNotify)coded_buffer_proxy_finalize
+ (GDestroyNotify) coded_buffer_proxy_finalize
};
return &GstVaapiCodedBufferProxyClass;
}
#define DEBUG 1
#include "gstvaapidebug.h"
-static void
-drop_frame (GstVaapiDecoder * decoder, GstVideoCodecFrame * frame);
+static void drop_frame (GstVaapiDecoder * decoder, GstVideoCodecFrame * frame);
static void
parser_state_finalize (GstVaapiParserState * ps)
if (GST_VIDEO_INFO_VIEWS (info) != views ||
GST_VIDEO_INFO_MULTIVIEW_MODE (info) != mv_mode ||
GST_VIDEO_INFO_MULTIVIEW_FLAGS (info) != mv_flags) {
- const gchar *mv_mode_str = gst_video_multiview_mode_to_caps_string (mv_mode);
+ const gchar *mv_mode_str =
+ gst_video_multiview_mode_to_caps_string (mv_mode);
GST_DEBUG ("Multiview mode changed to %s flags 0x%x views %d",
mv_mode_str, mv_flags, views);
priv->profile = profile;
}
- chroma_type = gst_vaapi_utils_h265_get_chroma_type (sps->chroma_format_idc, sps->bit_depth_luma_minus8 + 8);
+ chroma_type =
+ gst_vaapi_utils_h265_get_chroma_type (sps->chroma_format_idc,
+ sps->bit_depth_luma_minus8 + 8);
if (!chroma_type) {
GST_ERROR ("unsupported chroma_format_idc %u", sps->chroma_format_idc);
return GST_VAAPI_DECODER_STATUS_ERROR_UNSUPPORTED_CHROMA_FORMAT;
COPY_BFM (slice_parsing_fields, pps, cabac_init_present_flag);
COPY_BFM (slice_parsing_fields, pps, output_flag_present_flag);
COPY_BFM (slice_parsing_fields, pps, dependent_slice_segments_enabled_flag);
- pic_param->slice_parsing_fields.
- bits.pps_slice_chroma_qp_offsets_present_flag =
+ pic_param->slice_parsing_fields.bits.
+ pps_slice_chroma_qp_offsets_present_flag =
pps->slice_chroma_qp_offsets_present_flag;
COPY_BFM (slice_parsing_fields, sps, sample_adaptive_offset_enabled_flag);
COPY_BFM (slice_parsing_fields, pps, deblocking_filter_override_enabled_flag);
slice_hdr->temporal_mvp_enabled_flag;
slice_param->LongSliceFlags.fields.slice_deblocking_filter_disabled_flag =
slice_hdr->deblocking_filter_disabled_flag;
- slice_param->LongSliceFlags.
- fields.slice_loop_filter_across_slices_enabled_flag =
+ slice_param->LongSliceFlags.fields.
+ slice_loop_filter_across_slices_enabled_flag =
slice_hdr->loop_filter_across_slices_enabled_flag;
if (!slice_hdr->temporal_mvp_enabled_flag)
object = gst_vaapi_codec_object_new (gst_vaapi_codec_object_get_class
(&picture->parent_instance), GST_VAAPI_CODEC_BASE (decoder), NULL,
- picture->param_size, picture, 0,
- GST_VAAPI_CREATE_PICTURE_FLAG_CLONE);
+ picture->param_size, picture, 0, GST_VAAPI_CREATE_PICTURE_FLAG_CLONE);
if (!object)
return NULL;
return GST_VAAPI_PICTURE_CAST (object);
picture->structure = GST_VAAPI_PICTURE_STRUCTURE_FRAME;
picture->type = frame_hdr->key_frame ? GST_VAAPI_PICTURE_TYPE_I :
GST_VAAPI_PICTURE_TYPE_P;
- picture->pts = GST_VAAPI_DECODER_CODEC_FRAME(decoder)->pts;
+ picture->pts = GST_VAAPI_DECODER_CODEC_FRAME (decoder)->pts;
if (!frame_hdr->show_frame)
GST_VAAPI_PICTURE_FLAG_SET (picture, GST_VAAPI_PICTURE_FLAG_SKIPPED);
if (!ensure_subpicture_formats (display))
return NULL;
- return get_formats (GST_VAAPI_DISPLAY_GET_PRIVATE (display)->
- subpicture_formats);
+ return
+ get_formats (GST_VAAPI_DISPLAY_GET_PRIVATE (display)->subpicture_formats);
}
/**
klass = GST_VAAPI_DISPLAY_GET_CLASS (display);
return (klass->display_type == GST_VAAPI_DISPLAY_TYPE_GLX ||
- klass->display_type == GST_VAAPI_DISPLAY_TYPE_EGL);
+ klass->display_type == GST_VAAPI_DISPLAY_TYPE_EGL);
}
if (cdata->codec == GST_VAAPI_CODEC_JPEG) {
#if !VA_CHECK_VERSION(0,37,1)
encoder->packed_headers = VA_ENC_PACKED_HEADER_RAW_DATA;
- GST_DEBUG ("Hard coding the packed header flag value to VA_ENC_PACKED_HEADER_RAW_DATA,"
- "This is a work around for the driver bug");
+ GST_DEBUG ("Hard coding the packed header flag value to "
+ "VA_ENC_PACKED_HEADER_RAW_DATA. This is a work around for the driver "
+ "bug");
#endif
}
{
GstVaapiContextInfo *const cip = &encoder->context_info;
const GstVideoFormat fmt =
- GST_VIDEO_INFO_FORMAT (GST_VAAPI_ENCODER_VIDEO_INFO (encoder));
+ GST_VIDEO_INFO_FORMAT (GST_VAAPI_ENCODER_VIDEO_INFO (encoder));
guint format = 0;
if (fmt == GST_VIDEO_FORMAT_ENCODED)
GstVaapiContextInfo *const cip = &encoder->context_info;
GstVaapiConfigInfoEncoder *const config = &cip->config.encoder;
const GstVideoFormat format =
- GST_VIDEO_INFO_FORMAT (GST_VAAPI_ENCODER_VIDEO_INFO (encoder));
+ GST_VIDEO_INFO_FORMAT (GST_VAAPI_ENCODER_VIDEO_INFO (encoder));
const GstVaapiEncoderClassData *const cdata =
GST_VAAPI_ENCODER_GET_CLASS (encoder)->class_data;
GQueue reorder_frame_list;
guint reorder_state;
guint frame_index;
- guint frame_count; /* monotonically increasing with in every idr period */
+ guint frame_count; /* monotonically increasing with in every idr period */
guint cur_frame_num;
guint cur_present_index;
} GstVaapiH264ViewReorderPool;
static gboolean
bs_write_subset_sps (GstBitWriter * bs,
const VAEncSequenceParameterBufferH264 * seq_param, GstVaapiProfile profile,
- guint num_views, guint16 *view_ids, const VAEncMiscParameterHRD * hrd_params)
+ guint num_views, guint16 * view_ids,
+ const VAEncMiscParameterHRD * hrd_params)
{
guint32 i, j, k;
/* MVC */
gboolean is_mvc;
- guint32 view_idx; /* View Order Index (VOIdx) */
+ guint32 view_idx; /* View Order Index (VOIdx) */
guint32 num_views;
guint16 view_ids[MAX_NUM_VIEWS];
GstVaapiH264ViewRefPool ref_pools[MAX_NUM_VIEWS];
initial_cpb_removal_delay = encoder->cpb_length * 45;
/* initial_cpb_remvoal_dealy */
- WRITE_UINT32 (bs, initial_cpb_removal_delay, initial_cpb_removal_delay_length);
+ WRITE_UINT32 (bs, initial_cpb_removal_delay,
+ initial_cpb_removal_delay_length);
/* initial_cpb_removal_delay_offset */
WRITE_UINT32 (bs, initial_cpb_removal_delay_offset,
- initial_cpb_removal_delay_length);
+ initial_cpb_removal_delay_length);
/* VclHrdBpPresentFlag == FALSE */
return TRUE;
WRITE_UINT32 (&bs, 0x00000001, 32); /* start code */
bs_write_nal_header (&bs, GST_H264_NAL_REF_IDC_HIGH, GST_H264_NAL_SUBSET_SPS);
- bs_write_subset_sps (&bs, seq_param, encoder->profile, encoder->num_views, encoder->view_ids,
- &hrd_params);
+ bs_write_subset_sps (&bs, seq_param, encoder->profile, encoder->num_views,
+ encoder->view_ids, &hrd_params);
g_assert (GST_BIT_WRITER_BIT_SIZE (&bs) % 8 == 0);
data_bit_size = GST_BIT_WRITER_BIT_SIZE (&bs);
static gboolean
add_packed_sei_header (GstVaapiEncoderH264 * encoder,
- GstVaapiEncPicture * picture,
- GstVaapiH264SeiPayloadType payloadtype)
+ GstVaapiEncPicture * picture, GstVaapiH264SeiPayloadType payloadtype)
{
GstVaapiEncPackedHeader *packed_sei;
GstBitWriter bs, bs_buf_period, bs_pic_timing;
bs_write_sei_buf_period (&bs_buf_period, encoder, picture);
/* Write byte alignment bits */
if (GST_BIT_WRITER_BIT_SIZE (&bs_buf_period) % 8 != 0)
- bs_write_trailing_bits(&bs_buf_period);
- buf_period_payload_size =
- (GST_BIT_WRITER_BIT_SIZE (&bs_buf_period)) / 8;
+ bs_write_trailing_bits (&bs_buf_period);
+ buf_period_payload_size = (GST_BIT_WRITER_BIT_SIZE (&bs_buf_period)) / 8;
buf_period_payload = GST_BIT_WRITER_DATA (&bs_buf_period);
}
bs_write_sei_pic_timing (&bs_pic_timing, encoder, picture);
/* Write byte alignment bits */
if (GST_BIT_WRITER_BIT_SIZE (&bs_pic_timing) % 8 != 0)
- bs_write_trailing_bits(&bs_pic_timing);
- pic_timing_payload_size =
- (GST_BIT_WRITER_BIT_SIZE (&bs_pic_timing)) / 8;
+ bs_write_trailing_bits (&bs_pic_timing);
+ pic_timing_payload_size = (GST_BIT_WRITER_BIT_SIZE (&bs_pic_timing)) / 8;
pic_timing_payload = GST_BIT_WRITER_DATA (&bs_pic_timing);
}
/* pack nal_unit_header_mvc_extension() for the non base view */
if (encoder->is_mvc && encoder->view_idx) {
bs_write_nal_header (&bs, nal_ref_idc, GST_H264_NAL_SLICE_EXT);
- bs_write_nal_header_mvc_extension (&bs, picture, encoder->view_ids[encoder->view_idx]);
+ bs_write_nal_header_mvc_extension (&bs, picture,
+ encoder->view_ids[encoder->view_idx]);
} else
bs_write_nal_header (&bs, nal_ref_idc, nal_unit_type);
/* add subset sps for non-base view and sps for base view */
if (encoder->is_mvc && encoder->view_idx) {
- if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) & VA_ENC_PACKED_HEADER_SEQUENCE)
+ if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_SEQUENCE)
&& !add_packed_sequence_header_mvc (encoder, picture, sequence))
goto error_create_packed_seq_hdr;
} else {
- if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) & VA_ENC_PACKED_HEADER_SEQUENCE)
+ if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_SEQUENCE)
&& !add_packed_sequence_header (encoder, picture, sequence))
goto error_create_packed_seq_hdr;
}
if ((GST_VAAPI_ENC_PICTURE_IS_IDR (picture)) &&
(GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
VA_ENC_PACKED_HEADER_MISC) &&
- !add_packed_sei_header (encoder, picture,
+ !add_packed_sei_header (encoder, picture,
GST_VAAPI_H264_SEI_BUF_PERIOD | GST_VAAPI_H264_SEI_PIC_TIMING))
goto error_create_packed_sei_hdr;
else if (!GST_VAAPI_ENC_PICTURE_IS_IDR (picture) &&
- (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
- VA_ENC_PACKED_HEADER_MISC) &&
- !add_packed_sei_header (encoder, picture,
- GST_VAAPI_H264_SEI_PIC_TIMING))
+ (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_MISC) &&
+ !add_packed_sei_header (encoder, picture,
+ GST_VAAPI_H264_SEI_PIC_TIMING))
goto error_create_packed_sei_hdr;
}
return FALSE;
if (picture->type == GST_VAAPI_PICTURE_TYPE_I &&
- (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) & VA_ENC_PACKED_HEADER_PICTURE)
+ (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_PICTURE)
&& !add_packed_picture_header (encoder, picture)) {
GST_ERROR ("set picture packed header failed");
return FALSE;
}
/* Take number of MVC views from input caps if provided */
- if (GST_VIDEO_INFO_MULTIVIEW_MODE (vip) == GST_VIDEO_MULTIVIEW_MODE_FRAME_BY_FRAME ||
- GST_VIDEO_INFO_MULTIVIEW_MODE (vip) == GST_VIDEO_MULTIVIEW_MODE_MULTIVIEW_FRAME_BY_FRAME)
+ if (GST_VIDEO_INFO_MULTIVIEW_MODE (vip) ==
+ GST_VIDEO_MULTIVIEW_MODE_FRAME_BY_FRAME
+ || GST_VIDEO_INFO_MULTIVIEW_MODE (vip) ==
+ GST_VIDEO_MULTIVIEW_MODE_MULTIVIEW_FRAME_BY_FRAME)
encoder->num_views = GST_VIDEO_INFO_VIEWS (vip);
encoder->is_mvc = encoder->num_views > 1;
case GST_VAAPI_ENCODER_H264_PROP_NUM_VIEWS:
encoder->num_views = g_value_get_uint (value);
break;
- case GST_VAAPI_ENCODER_H264_PROP_VIEW_IDS:
- {
- guint i;
- GValueArray *view_ids = g_value_get_boxed (value);
-
- if (view_ids == NULL) {
- for (i = 0; i < encoder->num_views; i++)
- encoder->view_ids[i] = i;
- }
- else {
- g_assert (view_ids->n_values <= encoder->num_views);
-
- for (i = 0; i < encoder->num_views; i++) {
- GValue *val = g_value_array_get_nth (view_ids, i);
- encoder->view_ids[i] = g_value_get_uint (val);
- }
+ case GST_VAAPI_ENCODER_H264_PROP_VIEW_IDS:{
+ guint i;
+ GValueArray *view_ids = g_value_get_boxed (value);
+
+ if (view_ids == NULL) {
+ for (i = 0; i < encoder->num_views; i++)
+ encoder->view_ids[i] = i;
+ } else {
+ g_assert (view_ids->n_values <= encoder->num_views);
+
+ for (i = 0; i < encoder->num_views; i++) {
+ GValue *val = g_value_array_get_nth (view_ids, i);
+ encoder->view_ids[i] = g_value_get_uint (val);
}
+ }
break;
}
default:
(slice_param->slice_fields.bits.slice_sao_luma_flag
|| slice_param->slice_fields.bits.slice_sao_chroma_flag
|| !slice_deblocking_filter_disabled_flag))
- WRITE_UINT32 (bs,
- slice_param->slice_fields.
- bits.slice_loop_filter_across_slices_enabled_flag, 1);
+ WRITE_UINT32 (bs, slice_param->slice_fields.bits.
+ slice_loop_filter_across_slices_enabled_flag, 1);
}
slice_param->slice_fields.value = 0;
- slice_param->slice_fields.
- bits.slice_loop_filter_across_slices_enabled_flag = TRUE;
+ slice_param->slice_fields.bits.
+ slice_loop_filter_across_slices_enabled_flag = TRUE;
/* set calculation for next slice */
last_ctu_index += cur_slice_ctus;
goto error_create_seq_param;
/* add packed vps and sps headers */
- if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) & VA_ENC_PACKED_HEADER_SEQUENCE)
+ if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_SEQUENCE)
&& !(add_packed_vps_header (encoder, picture, sequence)
&& add_packed_sequence_header (encoder, picture, sequence))) {
goto error_create_packed_seq_hdr;
return FALSE;
if (picture->type == GST_VAAPI_PICTURE_TYPE_I &&
- (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) & VA_ENC_PACKED_HEADER_PICTURE)
+ (GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
+ VA_ENC_PACKED_HEADER_PICTURE)
&& !add_packed_picture_header (encoder, picture)) {
GST_ERROR ("set picture packed header failed");
return FALSE;
/* Only YUV 4:2:0 formats are supported for now. */
base_encoder->codedbuf_size += GST_ROUND_UP_32 (vip->width) *
- GST_ROUND_UP_32 (vip->height) * 3 / 2;
+ GST_ROUND_UP_32 (vip->height) * 3 / 2;
return GST_VAAPI_ENCODER_STATUS_SUCCESS;
}
/* ------------------------------------------------------------------------- */
#if USE_JPEG_ENCODER
-GST_VAAPI_CODEC_DEFINE_TYPE (GstVaapiEncHuffmanTable, gst_vaapi_enc_huffman_table);
+GST_VAAPI_CODEC_DEFINE_TYPE (GstVaapiEncHuffmanTable,
+ gst_vaapi_enc_huffman_table);
void
gst_vaapi_enc_huffman_table_destroy (GstVaapiEncHuffmanTable * huf_table)
if (op_data->va_type != va_type)
continue;
- if (op_data->va_cap_size == 0) { /* no caps, like skintone */
+ if (op_data->va_cap_size == 0) { /* no caps, like skintone */
g_ptr_array_add (ops, op_data_ref (op_data));
continue;
}
#if USE_VA_VPP
gboolean
op_set_skintone_unlocked (GstVaapiFilter * filter,
- GstVaapiFilterOpData * op_data, gboolean value)
+ GstVaapiFilterOpData * op_data, gboolean value)
{
VAProcFilterParameterBuffer *buf;
static inline gboolean
op_set_skintone (GstVaapiFilter * filter, GstVaapiFilterOpData * op_data,
- gboolean enhance)
+ gboolean enhance)
{
gboolean success = FALSE;
* otherwise.
**/
gboolean
-gst_vaapi_filter_set_skintone (GstVaapiFilter * filter,
- gboolean enhance)
+gst_vaapi_filter_set_skintone (GstVaapiFilter * filter, gboolean enhance)
{
g_return_val_if_fail (filter != NULL, FALSE);
{
static const GstVaapiVideoPoolClass GstVaapiImagePoolClass = {
{sizeof (GstVaapiImagePool),
- (GDestroyNotify) gst_vaapi_video_pool_finalize},
+ (GDestroyNotify) gst_vaapi_video_pool_finalize}
+ ,
.alloc_object = gst_vaapi_image_pool_alloc_object
};
return GST_VAAPI_MINI_OBJECT_CLASS (&GstVaapiImagePoolClass);
extbuf.pixel_format = va_format->fourcc;
extbuf.width = GST_VIDEO_INFO_WIDTH (vip);
extbuf.height = GST_VIDEO_INFO_HEIGHT (vip);
- extbuf_needed = !!(flags & GST_VAAPI_SURFACE_ALLOC_FLAG_LINEAR_STORAGE);
+ extbuf_needed = ! !(flags & GST_VAAPI_SURFACE_ALLOC_FLAG_LINEAR_STORAGE);
extbuf.num_planes = GST_VIDEO_INFO_N_PLANES (vip);
if (flags & GST_VAAPI_SURFACE_ALLOC_FLAG_FIXED_STRIDES) {
{
static const GstVaapiVideoPoolClass GstVaapiSurfacePoolClass = {
{sizeof (GstVaapiSurfacePool),
- (GDestroyNotify) gst_vaapi_video_pool_finalize},
+ (GDestroyNotify) gst_vaapi_video_pool_finalize}
+ ,
.alloc_object = gst_vaapi_surface_pool_alloc_object
};
return GST_VAAPI_MINI_OBJECT_CLASS (&GstVaapiSurfacePoolClass);
/* ------------------------------------------------------------------------- */
// EGL Context
-static void
-egl_context_state_get_current (EglContextState * cs);
+static void egl_context_state_get_current (EglContextState * cs);
static gboolean
egl_context_state_set_current (EglContextState * new_cs,
egl_matrix_set_identity (gfloat m[16])
{
#define MAT(m,r,c) (m)[(c) * 4 + (r)]
- MAT(m,0,0) = 1.0; MAT(m,0,1) = 0.0; MAT(m,0,2) = 0.0; MAT(m,0,3) = 0.0;
- MAT(m,1,0) = 0.0; MAT(m,1,1) = 1.0; MAT(m,1,2) = 0.0; MAT(m,1,3) = 0.0;
- MAT(m,2,0) = 0.0; MAT(m,2,1) = 0.0; MAT(m,2,2) = 1.0; MAT(m,2,3) = 0.0;
- MAT(m,3,0) = 0.0; MAT(m,3,1) = 0.0; MAT(m,3,2) = 0.0; MAT(m,3,3) = 1.0;
+ MAT (m, 0, 0) = 1.0;
+ MAT (m, 0, 1) = 0.0;
+ MAT (m, 0, 2) = 0.0;
+ MAT (m, 0, 3) = 0.0;
+ MAT (m, 1, 0) = 0.0;
+ MAT (m, 1, 1) = 1.0;
+ MAT (m, 1, 2) = 0.0;
+ MAT (m, 1, 3) = 0.0;
+ MAT (m, 2, 0) = 0.0;
+ MAT (m, 2, 1) = 0.0;
+ MAT (m, 2, 2) = 1.0;
+ MAT (m, 2, 3) = 0.0;
+ MAT (m, 3, 0) = 0.0;
+ MAT (m, 3, 1) = 0.0;
+ MAT (m, 3, 2) = 0.0;
+ MAT (m, 3, 3) = 1.0;
#undef MAT
}
/** Lookup for substring NAME in string EXT using SEP as separators */
static gboolean
-find_string (const gchar *name, const gchar *ext, const gchar *sep)
+find_string (const gchar * name, const gchar * ext, const gchar * sep)
{
const gchar *end;
int name_len, n;
typedef GLFuncPtr (*GLXGetProcAddressProc) (const gchar *);
static GLFuncPtr
-get_proc_address_default (const gchar *name)
+get_proc_address_default (const gchar * name)
{
return NULL;
}
}
static inline GLFuncPtr
-get_proc_address (const gchar *name)
+get_proc_address (const gchar * name)
{
static GLXGetProcAddressProc get_proc_func = NULL;
if (!get_proc_func)
/** Returns GstVaapiChromaType from H.265 chroma_format_idc value */
GstVaapiChromaType
-gst_vaapi_utils_h265_get_chroma_type (guint chroma_format_idc, guint luma_bit_depth)
+gst_vaapi_utils_h265_get_chroma_type (guint chroma_format_idc,
+ guint luma_bit_depth)
{
GstVaapiChromaType chroma_type = (GstVaapiChromaType) 0;
const gchar *
gst_vaapi_utils_h265_get_tier_string (GstVaapiTierH265 tier)
{
- const struct map *const m =
- map_lookup_value (gst_vaapi_h265_tier_map, tier);
+ const struct map *const m = map_lookup_value (gst_vaapi_h265_tier_map, tier);
return m ? m->name : NULL;
}
}
// X window management
-static const int x11_event_mask =
- (KeyPressMask |
- KeyReleaseMask |
- ButtonPressMask |
- ButtonReleaseMask |
- PointerMotionMask |
- EnterWindowMask |
- ExposureMask |
- StructureNotifyMask);
+static const int x11_event_mask = (KeyPressMask | KeyReleaseMask
+ | ButtonPressMask | ButtonReleaseMask | PointerMotionMask
+ | EnterWindowMask | ExposureMask | StructureNotifyMask);
/**
* x11_create_window:
dpy_class = GST_VAAPI_DISPLAY_GET_CLASS (display);
if (G_UNLIKELY (!dpy_class->create_window))
return NULL;
- return dpy_class->create_window (display, GST_VAAPI_ID_INVALID, width, height);
+ return dpy_class->create_window (display, GST_VAAPI_ID_INVALID, width,
+ height);
}
/**
texcoords[3][1] = y0;
// Target coords in EGL surface
- x0 = 2.0f * ((GLfloat) rect->x / tex_width) - 1.0f;
+ x0 = 2.0f * ((GLfloat) rect->x / tex_width) - 1.0f;
y1 = -2.0f * ((GLfloat) rect->y / tex_height) + 1.0f;
- x1 = 2.0f * ((GLfloat) (rect->x + rect->width) / tex_width) - 1.0f;
+ x1 = 2.0f * ((GLfloat) (rect->x + rect->width) / tex_width) - 1.0f;
y0 = -2.0f * ((GLfloat) (rect->y + rect->height) / tex_height) + 1.0f;
positions[0][0] = x0;
positions[0][1] = y0;