diff options
22 files changed, 124 insertions, 396 deletions
diff --git a/lib/mesa/src/gallium/state_trackers/clover/meson.build b/lib/mesa/src/gallium/state_trackers/clover/meson.build index 7606a6bea..a6729af2f 100644 --- a/lib/mesa/src/gallium/state_trackers/clover/meson.build +++ b/lib/mesa/src/gallium/state_trackers/clover/meson.build @@ -19,31 +19,19 @@ # SOFTWARE. clover_cpp_args = [] -clover_opencl_cpp_args = [ - '-DCL_TARGET_OPENCL_VERSION=220', - '-DCL_USE_DEPRECATED_OPENCL_1_0_APIS', - '-DCL_USE_DEPRECATED_OPENCL_1_1_APIS', - '-DCL_USE_DEPRECATED_OPENCL_1_2_APIS', - '-DCL_USE_DEPRECATED_OPENCL_2_0_APIS', - '-DCL_USE_DEPRECATED_OPENCL_2_1_APIS' -] -clover_spirv_cpp_args = [] clover_incs = [inc_include, inc_src, inc_gallium, inc_gallium_aux] -# the CL header files declare attributes on the CL types. Compilers warn if -# we use them as template arguments. Disable the warning as there isn't -# anything we can do about it -if cpp.has_argument('-Wno-ignored-attributes') - clover_cpp_args += '-Wno-ignored-attributes' -endif - if with_opencl_icd clover_cpp_args += '-DHAVE_CLOVER_ICD' endif -if with_opencl_spirv - clover_spirv_cpp_args += '-DHAVE_CLOVER_SPIRV' -endif +libcltgsi = static_library( + 'cltgsi', + files('tgsi/compiler.cpp', 'tgsi/invocation.hpp'), + include_directories : clover_incs, + cpp_args : [cpp_vis_args], + override_options : clover_cpp_std, +) libclllvm = static_library( 'clllvm', @@ -60,36 +48,15 @@ libclllvm = static_library( ), include_directories : clover_incs, cpp_args : [ - clover_cpp_args, - clover_opencl_cpp_args, - clover_spirv_cpp_args, cpp_vis_args, '-DLIBCLC_INCLUDEDIR="@0@/"'.format(dep_clc.get_pkgconfig_variable('includedir')), '-DLIBCLC_LIBEXECDIR="@0@/"'.format(dep_clc.get_pkgconfig_variable('libexecdir')), '-DCLANG_RESOURCE_DIR="@0@"'.format(join_paths( dep_llvm.get_configtool_variable('libdir'), 'clang', - dep_llvm.version(), 'include', + dep_llvm.get_configtool_variable('version'), 'include', )), ], - dependencies : [dep_llvm, dep_elf, dep_llvmspirvlib], - override_options : clover_cpp_std, -) - -libclspirv = static_library( - 'clspirv', - files('spirv/invocation.cpp', 'spirv/invocation.hpp'), - include_directories : clover_incs, - cpp_args : [clover_opencl_cpp_args, clover_spirv_cpp_args, cpp_vis_args], - dependencies : [dep_spirv_tools], - override_options : clover_cpp_std, -) - -libclnir = static_library( - 'clnir', - files('nir/invocation.cpp', 'nir/invocation.hpp'), - include_directories : [clover_incs, inc_mesa], - dependencies : idep_nir, - cpp_args : [clover_opencl_cpp_args, clover_spirv_cpp_args, cpp_vis_args], + dependencies : [dep_llvm, dep_elf], override_options : clover_cpp_std, ) @@ -108,7 +75,6 @@ clover_files = files( 'api/sampler.cpp', 'api/transfer.cpp', 'api/util.hpp', - 'core/compiler.hpp', 'core/context.cpp', 'core/context.hpp', 'core/device.cpp', @@ -153,12 +119,7 @@ libclover = static_library( 'clover', [clover_files, sha1_h], include_directories : clover_incs, - cpp_args : [ - clover_opencl_cpp_args, - clover_spirv_cpp_args, - clover_cpp_args, - cpp_vis_args - ], - link_with : [libclllvm, libclspirv, libclnir], + cpp_args : [clover_cpp_args, cpp_vis_args], + link_with : [libcltgsi, libclllvm], override_options : clover_cpp_std, ) diff --git a/lib/mesa/src/gallium/state_trackers/glx/xlib/meson.build b/lib/mesa/src/gallium/state_trackers/glx/xlib/meson.build index 34b93c94c..f4ee75426 100644 --- a/lib/mesa/src/gallium/state_trackers/glx/xlib/meson.build +++ b/lib/mesa/src/gallium/state_trackers/glx/xlib/meson.build @@ -23,5 +23,5 @@ libxlib = static_library( files('glx_api.c', 'glx_getproc.c', 'glx_usefont.c', 'xm_api.c', 'xm_st.c'), c_args : c_vis_args, include_directories : [inc_common, inc_mapi, inc_mesa], - dependencies : [dep_x11, dep_xext, dep_xcb, dep_glproto], + dependencies : [dep_x11, dep_xext, dep_xcb], ) diff --git a/lib/mesa/src/gallium/state_trackers/nine/meson.build b/lib/mesa/src/gallium/state_trackers/nine/meson.build index 7c9e035ca..491b7937a 100644 --- a/lib/mesa/src/gallium/state_trackers/nine/meson.build +++ b/lib/mesa/src/gallium/state_trackers/nine/meson.build @@ -66,10 +66,5 @@ libnine_st = static_library( include_directories : [ inc_d3d9, inc_gallium, inc_include, inc_src, inc_gallium_aux, ], - dependencies : [ - dep_thread, idep_nir, idep_nir_headers - ], - link_with : [ - libmesa_gallium - ] + dependencies : dep_thread, ) diff --git a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec.c b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec.c index 2eedf937c..65e612a57 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec.c +++ b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec.c @@ -180,7 +180,7 @@ static OMX_ERRORTYPE vid_dec_Constructor(OMX_COMPONENTTYPE *comp, OMX_STRING nam return OMX_ErrorInsufficientResources; screen = priv->screen->pscreen; - priv->pipe = pipe_create_multimedia_context(screen); + priv->pipe = screen->context_create(screen, NULL, 0); if (!priv->pipe) return OMX_ErrorInsufficientResources; diff --git a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h264.c b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h264.c index 1a198a97e..e8f7aa5cf 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h264.c +++ b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h264.c @@ -49,7 +49,7 @@ void vid_dec_h264_Init(vid_dec_PrivateType *priv) priv->EndFrame = vid_dec_h264_EndFrame; priv->Flush = vid_dec_h264_Flush; - list_inithead(&priv->codec_data.h264.dpb_list); + LIST_INITHEAD(&priv->codec_data.h264.dpb_list); priv->picture.h264.field_order_cnt[0] = priv->picture.h264.field_order_cnt[1] = INT_MAX; priv->first_buf_in_frame = true; } diff --git a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h265.c b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h265.c index c50be7804..3242dbe11 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h265.c +++ b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_dec_h265.c @@ -668,7 +668,7 @@ static struct pipe_video_buffer *vid_dec_h265_Flush(vid_dec_PrivateType *priv, *timestamp = result->timestamp; --priv->codec_data.h265.dpb_num; - list_del(&result->list); + LIST_DEL(&result->list); FREE(result); return buf; @@ -736,7 +736,7 @@ static void vid_dec_h265_EndFrame(vid_dec_PrivateType *priv) entry->timestamp = priv->timestamp; entry->poc = get_poc(priv); - list_addtail(&entry->list, &priv->codec_data.h265.dpb_list); + LIST_ADDTAIL(&entry->list, &priv->codec_data.h265.dpb_list); ++priv->codec_data.h265.dpb_num; priv->target = NULL; @@ -1002,7 +1002,7 @@ void vid_dec_h265_Init(vid_dec_PrivateType *priv) { priv->picture.base.profile = PIPE_VIDEO_PROFILE_HEVC_MAIN; - list_inithead(&priv->codec_data.h265.dpb_list); + LIST_INITHEAD(&priv->codec_data.h265.dpb_list); priv->codec_data.h265.ref_pic_set_list = (struct ref_pic_set *) CALLOC(MAX_NUM_REF_PICS, sizeof(struct ref_pic_set)); diff --git a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_enc.c b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_enc.c index 8153103e9..1126c4f58 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_enc.c +++ b/lib/mesa/src/gallium/state_trackers/omx/bellagio/vid_enc.c @@ -157,12 +157,10 @@ static OMX_ERRORTYPE vid_enc_Constructor(OMX_COMPONENTTYPE *comp, OMX_STRING nam PIPE_VIDEO_ENTRYPOINT_ENCODE, PIPE_VIDEO_CAP_SUPPORTED)) return OMX_ErrorBadParameter; - priv->s_pipe = pipe_create_multimedia_context(screen); + priv->s_pipe = screen->context_create(screen, NULL, 0); if (!priv->s_pipe) return OMX_ErrorInsufficientResources; - enc_InitCompute_common(priv); - if (!vl_compositor_init(&priv->compositor, priv->s_pipe)) { priv->s_pipe->destroy(priv->s_pipe); priv->s_pipe = NULL; @@ -176,7 +174,7 @@ static OMX_ERRORTYPE vid_enc_Constructor(OMX_COMPONENTTYPE *comp, OMX_STRING nam return OMX_ErrorInsufficientResources; } - priv->t_pipe = pipe_create_multimedia_context(screen); + priv->t_pipe = screen->context_create(screen, NULL, 0); if (!priv->t_pipe) return OMX_ErrorInsufficientResources; @@ -235,10 +233,10 @@ static OMX_ERRORTYPE vid_enc_Constructor(OMX_COMPONENTTYPE *comp, OMX_STRING nam priv->scale.xWidth = OMX_VID_ENC_SCALING_WIDTH_DEFAULT; priv->scale.xHeight = OMX_VID_ENC_SCALING_WIDTH_DEFAULT; - list_inithead(&priv->free_tasks); - list_inithead(&priv->used_tasks); - list_inithead(&priv->b_frames); - list_inithead(&priv->stacked_tasks); + LIST_INITHEAD(&priv->free_tasks); + LIST_INITHEAD(&priv->used_tasks); + LIST_INITHEAD(&priv->b_frames); + LIST_INITHEAD(&priv->stacked_tasks); return OMX_ErrorNone; } @@ -269,7 +267,6 @@ static OMX_ERRORTYPE vid_enc_Destructor(OMX_COMPONENTTYPE *comp) if (priv->s_pipe) { vl_compositor_cleanup_state(&priv->cstate); vl_compositor_cleanup(&priv->compositor); - enc_ReleaseCompute_common(priv); priv->s_pipe->destroy(priv->s_pipe); } @@ -658,7 +655,7 @@ static OMX_ERRORTYPE vid_enc_AllocateInBuffer(omx_base_PortType *port, OMX_INOUT return OMX_ErrorInsufficientResources; } - list_inithead(&inp->tasks); + LIST_INITHEAD(&inp->tasks); FREE((*buf)->pBuffer); r = enc_AllocateBackTexture(port, &inp->resource, &inp->transfer, &(*buf)->pBuffer); @@ -687,7 +684,7 @@ static OMX_ERRORTYPE vid_enc_UseInBuffer(omx_base_PortType *port, OMX_BUFFERHEAD return OMX_ErrorInsufficientResources; } - list_inithead(&inp->tasks); + LIST_INITHEAD(&inp->tasks); return OMX_ErrorNone; } @@ -820,16 +817,16 @@ static void enc_ClearBframes(omx_base_PortType *port, struct input_buf_private * vid_enc_PrivateType *priv = comp->pComponentPrivate; struct encode_task *task; - if (list_is_empty(&priv->b_frames)) + if (LIST_IS_EMPTY(&priv->b_frames)) return; task = LIST_ENTRY(struct encode_task, priv->b_frames.prev, list); - list_del(&task->list); + LIST_DEL(&task->list); /* promote last from to P frame */ priv->ref_idx_l0 = priv->ref_idx_l1; enc_HandleTask(port, task, PIPE_H264_ENC_PICTURE_TYPE_P); - list_addtail(&task->list, &inp->tasks); + LIST_ADDTAIL(&task->list, &inp->tasks); priv->ref_idx_l1 = priv->frame_num++; /* handle B frames */ @@ -900,20 +897,20 @@ static OMX_ERRORTYPE vid_enc_EncodeFrame(omx_base_PortType *port, OMX_BUFFERHEAD if (picture_type == PIPE_H264_ENC_PICTURE_TYPE_B) { /* put frame at the tail of the queue */ - list_addtail(&task->list, &priv->b_frames); + LIST_ADDTAIL(&task->list, &priv->b_frames); } else { /* handle I or P frame */ priv->ref_idx_l0 = priv->ref_idx_l1; enc_HandleTask(port, task, picture_type); - list_addtail(&task->list, &priv->stacked_tasks); + LIST_ADDTAIL(&task->list, &priv->stacked_tasks); LIST_FOR_EACH_ENTRY(task, &priv->stacked_tasks, list) { ++stacked_num; } if (stacked_num == priv->stacked_frames_num) { struct encode_task *t; t = LIST_ENTRY(struct encode_task, priv->stacked_tasks.next, list); - list_del(&t->list); - list_addtail(&t->list, &inp->tasks); + LIST_DEL(&t->list); + LIST_ADDTAIL(&t->list, &inp->tasks); } priv->ref_idx_l1 = priv->frame_num++; @@ -928,7 +925,7 @@ static OMX_ERRORTYPE vid_enc_EncodeFrame(omx_base_PortType *port, OMX_BUFFERHEAD enc_MoveTasks(&priv->b_frames, &inp->tasks); } - if (list_is_empty(&inp->tasks)) + if (LIST_IS_EMPTY(&inp->tasks)) return port->ReturnBufferFunction(port, buf); else return base_port_SendBufferFunction(port, buf); diff --git a/lib/mesa/src/gallium/state_trackers/omx/meson.build b/lib/mesa/src/gallium/state_trackers/omx/meson.build index 987d3e23c..382bf2ed2 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/meson.build +++ b/lib/mesa/src/gallium/state_trackers/omx/meson.build @@ -1,4 +1,4 @@ -# Copyright © 2017, 2019 Intel Corporation +# Copyright © 2017 Intel Corporation # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -19,9 +19,7 @@ # SOFTWARE. inc_st_omx = [inc_common] -dep_st_omx = [ - dep_omx, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, dep_libdrm, -] +dep_st_omx = [dep_omx, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3] files_omx = files( 'vid_dec_common.c', @@ -59,13 +57,13 @@ elif with_gallium_omx == 'tizonia' inc_egl, inc_egl_dri2, ] - dep_st_omx = [dep_st_omx, dep_omx_other] + dep_st_omx = [dep_st_omx, dep_omx_other, dep_libdrm] endif libomx_st = static_library( 'omx_st', files_omx, - c_args : [c_vis_args, '-fcommon'], + c_args : [c_vis_args], include_directories : inc_st_omx, dependencies : dep_st_omx, ) diff --git a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264dprc.c b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264dprc.c index cac62a82e..09248e64a 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264dprc.c +++ b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264dprc.c @@ -407,7 +407,7 @@ static OMX_ERRORTYPE h264d_prc_allocate_resources(void *ap_obj, OMX_U32 a_pid) return OMX_ErrorInsufficientResources; screen = priv->screen->pscreen; - priv->pipe = pipe_create_multimedia_context(screen); + priv->pipe = screen->context_create(screen, priv->screen, 0); if (!priv->pipe) return OMX_ErrorInsufficientResources; @@ -432,7 +432,7 @@ static OMX_ERRORTYPE h264d_prc_allocate_resources(void *ap_obj, OMX_U32 a_pid) return OMX_ErrorInsufficientResources; } - list_inithead(&priv->codec_data.h264.dpb_list); + LIST_INITHEAD(&priv->codec_data.h264.dpb_list); priv->video_buffer_map = util_hash_table_create(handle_hash, handle_compare); diff --git a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264einport.c b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264einport.c index 609a1782b..3f34e05e0 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264einport.c +++ b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264einport.c @@ -112,7 +112,7 @@ static OMX_ERRORTYPE h264e_inport_AllocateBuffer(const void * ap_obj, OMX_HANDLE return OMX_ErrorInsufficientResources; } - list_inithead(&inp->tasks); + LIST_INITHEAD(&inp->tasks); r = enc_AllocateBackTexture(ap_hdl, idx, &inp->resource, &inp->transfer, &(*buf)->pBuffer); @@ -143,7 +143,7 @@ static OMX_ERRORTYPE h264e_inport_UseBuffer(const void * ap_obj, OMX_HANDLETYPE return OMX_ErrorInsufficientResources; } - list_inithead(&inp->tasks); + LIST_INITHEAD(&inp->tasks); return OMX_ErrorNone; } diff --git a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264eprc.c b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264eprc.c index b52e489f2..586763456 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264eprc.c +++ b/lib/mesa/src/gallium/state_trackers/omx/tizonia/h264eprc.c @@ -268,16 +268,16 @@ static void enc_ClearBframes(vid_enc_PrivateType * priv, struct input_buf_privat { struct encode_task *task; - if (list_is_empty(&priv->b_frames)) + if (LIST_IS_EMPTY(&priv->b_frames)) return; task = LIST_ENTRY(struct encode_task, priv->b_frames.prev, list); - list_del(&task->list); + LIST_DEL(&task->list); /* promote last from to P frame */ priv->ref_idx_l0 = priv->ref_idx_l1; enc_HandleTask(priv, task, PIPE_H264_ENC_PICTURE_TYPE_P); - list_addtail(&task->list, &inp->tasks); + LIST_ADDTAIL(&task->list, &inp->tasks); priv->ref_idx_l1 = priv->frame_num++; /* handle B frames */ @@ -354,20 +354,20 @@ static OMX_ERRORTYPE encode_frame(vid_enc_PrivateType * priv, OMX_BUFFERHEADERTY if (picture_type == PIPE_H264_ENC_PICTURE_TYPE_B) { /* put frame at the tail of the queue */ - list_addtail(&task->list, &priv->b_frames); + LIST_ADDTAIL(&task->list, &priv->b_frames); } else { /* handle I or P frame */ priv->ref_idx_l0 = priv->ref_idx_l1; enc_HandleTask(priv, task, picture_type); - list_addtail(&task->list, &priv->stacked_tasks); + LIST_ADDTAIL(&task->list, &priv->stacked_tasks); LIST_FOR_EACH_ENTRY(task, &priv->stacked_tasks, list) { ++stacked_num; } if (stacked_num == priv->stacked_frames_num) { struct encode_task *t; t = LIST_ENTRY(struct encode_task, priv->stacked_tasks.next, list); - list_del(&t->list); - list_addtail(&t->list, &inp->tasks); + LIST_DEL(&t->list); + LIST_ADDTAIL(&t->list, &inp->tasks); } priv->ref_idx_l1 = priv->frame_num++; @@ -382,7 +382,7 @@ static OMX_ERRORTYPE encode_frame(vid_enc_PrivateType * priv, OMX_BUFFERHEADERTY enc_MoveTasks(&priv->b_frames, &inp->tasks); } - if (list_is_empty(&inp->tasks)) { + if (LIST_IS_EMPTY(&inp->tasks)) { return h264e_buffer_emptied(priv, in_buf); } else { return h264e_manage_buffers(priv); @@ -403,12 +403,10 @@ static OMX_ERRORTYPE h264e_prc_create_encoder(void *ap_obj) PIPE_VIDEO_ENTRYPOINT_ENCODE, PIPE_VIDEO_CAP_SUPPORTED)) return OMX_ErrorBadParameter; - priv->s_pipe = pipe_create_multimedia_context(screen); + priv->s_pipe = screen->context_create(screen, NULL, 0); if (!priv->s_pipe) return OMX_ErrorInsufficientResources; - enc_InitCompute_common(priv); - if (!vl_compositor_init(&priv->compositor, priv->s_pipe)) { priv->s_pipe->destroy(priv->s_pipe); priv->s_pipe = NULL; @@ -422,14 +420,14 @@ static OMX_ERRORTYPE h264e_prc_create_encoder(void *ap_obj) return OMX_ErrorInsufficientResources; } - priv->t_pipe = pipe_create_multimedia_context(screen); + priv->t_pipe = screen->context_create(screen, NULL, 0); if (!priv->t_pipe) return OMX_ErrorInsufficientResources; - list_inithead(&priv->free_tasks); - list_inithead(&priv->used_tasks); - list_inithead(&priv->b_frames); - list_inithead(&priv->stacked_tasks); + LIST_INITHEAD(&priv->free_tasks); + LIST_INITHEAD(&priv->used_tasks); + LIST_INITHEAD(&priv->b_frames); + LIST_INITHEAD(&priv->stacked_tasks); return OMX_ErrorNone; } @@ -453,7 +451,6 @@ static void h264e_prc_destroy_encoder(void *ap_obj) if (priv->s_pipe) { vl_compositor_cleanup_state(&priv->cstate); vl_compositor_cleanup(&priv->compositor); - enc_ReleaseCompute_common(priv); priv->s_pipe->destroy(priv->s_pipe); } diff --git a/lib/mesa/src/gallium/state_trackers/omx/vid_dec_h264_common.c b/lib/mesa/src/gallium/state_trackers/omx/vid_dec_h264_common.c index 388852ba5..1965e6877 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/vid_dec_h264_common.c +++ b/lib/mesa/src/gallium/state_trackers/omx/vid_dec_h264_common.c @@ -98,7 +98,7 @@ struct pipe_video_buffer *vid_dec_h264_Flush(vid_dec_PrivateType *priv, *timestamp = result->timestamp; --priv->codec_data.h264.dpb_num; - list_del(&result->list); + LIST_DEL(&result->list); FREE(result); return buf; @@ -136,7 +136,7 @@ void vid_dec_h264_EndFrame(vid_dec_PrivateType *priv) entry->buffer = priv->target; entry->timestamp = priv->timestamp; entry->poc = MIN2(priv->picture.h264.field_order_cnt[0], priv->picture.h264.field_order_cnt[1]); - list_addtail(&entry->list, &priv->codec_data.h264.dpb_list); + LIST_ADDTAIL(&entry->list, &priv->codec_data.h264.dpb_list); ++priv->codec_data.h264.dpb_num; priv->target = NULL; priv->picture.h264.field_order_cnt[0] = priv->picture.h264.field_order_cnt[1] = INT_MAX; diff --git a/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.c b/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.c index c15c35169..2aa739da2 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.c +++ b/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.c @@ -28,7 +28,6 @@ #include "vid_enc_common.h" #include "vl/vl_video_buffer.h" -#include "tgsi/tgsi_text.h" void enc_ReleaseTasks(struct list_head *head) { @@ -50,7 +49,7 @@ void enc_MoveTasks(struct list_head *from, struct list_head *to) from->next->prev = to->prev; from->prev->next = to; to->prev = from->prev; - list_inithead(from); + LIST_INITHEAD(from); } static void enc_GetPictureParamPreset(struct pipe_h264_enc_picture_desc *picture) @@ -130,7 +129,7 @@ void vid_enc_BufferEncoded_common(vid_enc_PrivateType * priv, OMX_BUFFERHEADERTY unsigned size; #if ENABLE_ST_OMX_BELLAGIO - if (!inp || list_is_empty(&inp->tasks)) { + if (!inp || LIST_IS_EMPTY(&inp->tasks)) { input->nFilledLen = 0; /* mark buffer as empty */ enc_MoveTasks(&priv->used_tasks, &inp->tasks); return; @@ -138,8 +137,8 @@ void vid_enc_BufferEncoded_common(vid_enc_PrivateType * priv, OMX_BUFFERHEADERTY #endif task = LIST_ENTRY(struct encode_task, inp->tasks.next, list); - list_del(&task->list); - list_addtail(&task->list, &priv->used_tasks); + LIST_DEL(&task->list); + LIST_ADDTAIL(&task->list, &priv->used_tasks); if (!task->bitstream) return; @@ -182,9 +181,9 @@ struct encode_task *enc_NeedTask_common(vid_enc_PrivateType * priv, OMX_VIDEO_PO struct pipe_video_buffer templat = {}; struct encode_task *task; - if (!list_is_empty(&priv->free_tasks)) { + if (!LIST_IS_EMPTY(&priv->free_tasks)) { task = LIST_ENTRY(struct encode_task, priv->free_tasks.next, list); - list_del(&task->list); + LIST_DEL(&task->list); return task; } @@ -307,97 +306,10 @@ void enc_ControlPicture_common(vid_enc_PrivateType * priv, struct pipe_h264_enc_ enc_GetPictureParamPreset(picture); } -static void *create_compute_state(struct pipe_context *pipe, - const char *source) -{ - struct tgsi_token tokens[1024]; - struct pipe_compute_state state = {0}; - - if (!tgsi_text_translate(source, tokens, ARRAY_SIZE(tokens))) { - assert(false); - return NULL; - } - - state.ir_type = PIPE_SHADER_IR_TGSI; - state.prog = tokens; - - return pipe->create_compute_state(pipe, &state); -} - -void enc_InitCompute_common(vid_enc_PrivateType *priv) -{ - struct pipe_context *pipe = priv->s_pipe; - struct pipe_screen *screen = pipe->screen; - - /* We need the partial last block support. */ - if (!screen->get_param(screen, PIPE_CAP_COMPUTE_GRID_INFO_LAST_BLOCK)) - return; - - static const char *copy_y = - "COMP\n" - "PROPERTY CS_FIXED_BLOCK_WIDTH 64\n" - "PROPERTY CS_FIXED_BLOCK_HEIGHT 1\n" - "PROPERTY CS_FIXED_BLOCK_DEPTH 1\n" - "DCL SV[0], THREAD_ID\n" - "DCL SV[1], BLOCK_ID\n" - "DCL IMAGE[0], 2D, PIPE_FORMAT_R8_UINT\n" - "DCL IMAGE[1], 2D, PIPE_FORMAT_R8_UINT, WR\n" - "DCL TEMP[0..1]\n" - "IMM[0] UINT32 {64, 0, 0, 0}\n" - - "UMAD TEMP[0].x, SV[1], IMM[0], SV[0]\n" - "MOV TEMP[0].y, SV[1]\n" - "LOAD TEMP[1].x, IMAGE[0], TEMP[0], 2D, PIPE_FORMAT_R8_UINT\n" - "STORE IMAGE[1].x, TEMP[0], TEMP[1], 2D, PIPE_FORMAT_R8_UINT\n" - "END\n"; - - static const char *copy_uv = - "COMP\n" - "PROPERTY CS_FIXED_BLOCK_WIDTH 64\n" - "PROPERTY CS_FIXED_BLOCK_HEIGHT 1\n" - "PROPERTY CS_FIXED_BLOCK_DEPTH 1\n" - "DCL SV[0], THREAD_ID\n" - "DCL SV[1], BLOCK_ID\n" - "DCL IMAGE[0], 2D, PIPE_FORMAT_R8_UINT\n" - "DCL IMAGE[2], 2D, PIPE_FORMAT_R8G8_UINT, WR\n" - "DCL CONST[0][0]\n" /* .x = offset of the UV portion in the y direction */ - "DCL TEMP[0..4]\n" - "IMM[0] UINT32 {64, 0, 2, 1}\n" - /* Destination R8G8 coordinates */ - "UMAD TEMP[0].x, SV[1], IMM[0], SV[0]\n" - "MOV TEMP[0].y, SV[1]\n" - /* Source R8 coordinates of U */ - "UMUL TEMP[1].x, TEMP[0], IMM[0].zzzz\n" - "UADD TEMP[1].y, TEMP[0], CONST[0].xxxx\n" - /* Source R8 coordinates of V */ - "UADD TEMP[2].x, TEMP[1], IMM[0].wwww\n" - "MOV TEMP[2].y, TEMP[1]\n" - - "LOAD TEMP[3].x, IMAGE[0], TEMP[1], 2D, PIPE_FORMAT_R8_UINT\n" - "LOAD TEMP[4].x, IMAGE[0], TEMP[2], 2D, PIPE_FORMAT_R8_UINT\n" - "MOV TEMP[3].y, TEMP[4].xxxx\n" - "STORE IMAGE[2], TEMP[0], TEMP[3], 2D, PIPE_FORMAT_R8G8_UINT\n" - "END\n"; - - priv->copy_y_shader = create_compute_state(pipe, copy_y); - priv->copy_uv_shader = create_compute_state(pipe, copy_uv); -} - -void enc_ReleaseCompute_common(vid_enc_PrivateType *priv) -{ - struct pipe_context *pipe = priv->s_pipe; - - if (priv->copy_y_shader) - pipe->delete_compute_state(pipe, priv->copy_y_shader); - if (priv->copy_uv_shader) - pipe->delete_compute_state(pipe, priv->copy_uv_shader); -} - OMX_ERRORTYPE enc_LoadImage_common(vid_enc_PrivateType * priv, OMX_VIDEO_PORTDEFINITIONTYPE *def, OMX_BUFFERHEADERTYPE *buf, struct pipe_video_buffer *vbuf) { - struct pipe_context *pipe = priv->s_pipe; struct pipe_box box = {}; struct input_buf_private *inp = buf->pInputPortPrivate; @@ -413,142 +325,62 @@ OMX_ERRORTYPE enc_LoadImage_common(vid_enc_PrivateType * priv, OMX_VIDEO_PORTDEF box.width = def->nFrameWidth; box.height = def->nFrameHeight; box.depth = 1; - pipe->texture_subdata(pipe, views[0]->texture, 0, - PIPE_TRANSFER_WRITE, &box, - ptr, def->nStride, 0); + priv->s_pipe->texture_subdata(priv->s_pipe, views[0]->texture, 0, + PIPE_TRANSFER_WRITE, &box, + ptr, def->nStride, 0); ptr = ((uint8_t*)buf->pBuffer) + (def->nStride * box.height); box.width = def->nFrameWidth / 2; box.height = def->nFrameHeight / 2; box.depth = 1; - pipe->texture_subdata(pipe, views[1]->texture, 0, - PIPE_TRANSFER_WRITE, &box, - ptr, def->nStride, 0); + priv->s_pipe->texture_subdata(priv->s_pipe, views[1]->texture, 0, + PIPE_TRANSFER_WRITE, &box, + ptr, def->nStride, 0); } else { + struct pipe_blit_info blit; struct vl_video_buffer *dst_buf = (struct vl_video_buffer *)vbuf; - pipe_transfer_unmap(pipe, inp->transfer); - - /* inp->resource uses PIPE_FORMAT_I8 and the layout looks like this: - * - * def->nFrameWidth = 4, def->nFrameHeight = 4: - * |----| - * |YYYY| - * |YYYY| - * |YYYY| - * |YYYY| - * |UVUV| - * |UVUV| - * |----| - * - * The copy has 2 steps: - * - Copy Y to dst_buf->resources[0] as R8. - * - Copy UV to dst_buf->resources[1] as R8G8. - */ - if (priv->copy_y_shader && priv->copy_uv_shader) { - /* Compute path */ - /* Set shader images for both copies. */ - struct pipe_image_view image[3] = {0}; - image[0].resource = inp->resource; - image[0].shader_access = image[0].access = PIPE_IMAGE_ACCESS_READ; - image[0].format = PIPE_FORMAT_R8_UINT; - - image[1].resource = dst_buf->resources[0]; - image[1].shader_access = image[1].access = PIPE_IMAGE_ACCESS_WRITE; - image[1].format = PIPE_FORMAT_R8_UINT; - - image[2].resource = dst_buf->resources[1]; - image[2].shader_access = image[1].access = PIPE_IMAGE_ACCESS_WRITE; - image[2].format = PIPE_FORMAT_R8G8_UINT; - - pipe->set_shader_images(pipe, PIPE_SHADER_COMPUTE, 0, 3, image); - - /* Set the constant buffer. */ - uint32_t constants[4] = {def->nFrameHeight}; - struct pipe_constant_buffer cb = {}; - - cb.buffer_size = sizeof(constants); - cb.user_buffer = constants; - pipe->set_constant_buffer(pipe, PIPE_SHADER_COMPUTE, 0, &cb); - - /* Use the optimal block size for the linear image layout. */ - struct pipe_grid_info info = {}; - info.block[0] = 64; - info.block[1] = 1; - info.block[2] = 1; - info.grid[2] = 1; - - /* Copy Y */ - pipe->bind_compute_state(pipe, priv->copy_y_shader); - - info.grid[0] = DIV_ROUND_UP(def->nFrameWidth, 64); - info.grid[1] = def->nFrameHeight; - info.last_block[0] = def->nFrameWidth % 64; - pipe->launch_grid(pipe, &info); - - /* Copy UV */ - pipe->bind_compute_state(pipe, priv->copy_uv_shader); - - info.grid[0] = DIV_ROUND_UP(def->nFrameWidth / 2, 64); - info.grid[1] = def->nFrameHeight / 2; - info.last_block[0] = (def->nFrameWidth / 2) % 64; - pipe->launch_grid(pipe, &info); - - /* Make the result visible to all clients. */ - pipe->memory_barrier(pipe, PIPE_BARRIER_ALL); - - /* Unbind. */ - pipe->set_shader_images(pipe, PIPE_SHADER_COMPUTE, 0, 3, NULL); - pipe->set_constant_buffer(pipe, PIPE_SHADER_COMPUTE, 0, NULL); - pipe->bind_compute_state(pipe, NULL); - } else { - /* Graphics path */ - struct pipe_blit_info blit; - - box.width = def->nFrameWidth; - box.height = def->nFrameHeight; - box.depth = 1; - - /* Copy Y */ - pipe->resource_copy_region(pipe, - dst_buf->resources[0], - 0, 0, 0, 0, inp->resource, 0, &box); - - /* Copy U */ - memset(&blit, 0, sizeof(blit)); - blit.src.resource = inp->resource; - blit.src.format = inp->resource->format; - - blit.src.box.x = -1; - blit.src.box.y = def->nFrameHeight; - blit.src.box.width = def->nFrameWidth; - blit.src.box.height = def->nFrameHeight / 2 ; - blit.src.box.depth = 1; - - blit.dst.resource = dst_buf->resources[1]; - blit.dst.format = blit.dst.resource->format; - - blit.dst.box.width = def->nFrameWidth / 2; - blit.dst.box.height = def->nFrameHeight / 2; - blit.dst.box.depth = 1; - blit.filter = PIPE_TEX_FILTER_NEAREST; - - blit.mask = PIPE_MASK_R; - pipe->blit(pipe, &blit); - - /* Copy V */ - blit.src.box.x = 0; - blit.mask = PIPE_MASK_G; - pipe->blit(pipe, &blit); - } + pipe_transfer_unmap(priv->s_pipe, inp->transfer); + + box.width = def->nFrameWidth; + box.height = def->nFrameHeight; + box.depth = 1; + + priv->s_pipe->resource_copy_region(priv->s_pipe, + dst_buf->resources[0], + 0, 0, 0, 0, inp->resource, 0, &box); + + memset(&blit, 0, sizeof(blit)); + blit.src.resource = inp->resource; + blit.src.format = inp->resource->format; + + blit.src.box.x = -1; + blit.src.box.y = def->nFrameHeight; + blit.src.box.width = def->nFrameWidth; + blit.src.box.height = def->nFrameHeight / 2 ; + blit.src.box.depth = 1; + + blit.dst.resource = dst_buf->resources[1]; + blit.dst.format = blit.dst.resource->format; + + blit.dst.box.width = def->nFrameWidth / 2; + blit.dst.box.height = def->nFrameHeight / 2; + blit.dst.box.depth = 1; + blit.filter = PIPE_TEX_FILTER_NEAREST; + + blit.mask = PIPE_MASK_R; + priv->s_pipe->blit(priv->s_pipe, &blit); - pipe->flush(pipe, NULL, 0); + blit.src.box.x = 0; + blit.mask = PIPE_MASK_G; + priv->s_pipe->blit(priv->s_pipe, &blit); + priv->s_pipe->flush(priv->s_pipe, NULL, 0); box.width = inp->resource->width0; box.height = inp->resource->height0; box.depth = inp->resource->depth0; - buf->pBuffer = pipe->transfer_map(pipe, inp->resource, 0, - PIPE_TRANSFER_WRITE, &box, - &inp->transfer); + buf->pBuffer = priv->s_pipe->transfer_map(priv->s_pipe, inp->resource, 0, + PIPE_TRANSFER_WRITE, &box, + &inp->transfer); } return OMX_ErrorNone; diff --git a/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.h b/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.h index 8c8830dfc..bdf519db2 100644 --- a/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.h +++ b/lib/mesa/src/gallium/state_trackers/omx/vid_enc_common.h @@ -100,9 +100,7 @@ DERIVEDCLASS(vid_enc_PrivateType, omx_base_filter_PrivateType) struct pipe_video_buffer *scale_buffer[OMX_VID_ENC_NUM_SCALING_BUFFERS]; \ OMX_CONFIG_SCALEFACTORTYPE scale; \ OMX_U32 current_scale_buffer; \ - OMX_U32 stacked_frames_num; \ - void *copy_y_shader; \ - void *copy_uv_shader; + OMX_U32 stacked_frames_num; ENDCLASS(vid_enc_PrivateType) #else @@ -153,8 +151,6 @@ struct h264e_prc bool eos_; bool in_port_disabled_; bool out_port_disabled_; - void *copy_y_shader; - void *copy_uv_shader; }; #endif @@ -171,8 +167,6 @@ void enc_ScaleInput_common(vid_enc_PrivateType * priv, struct pipe_video_buffer **vbuf, unsigned *size); void enc_ControlPicture_common(vid_enc_PrivateType * priv, struct pipe_h264_enc_picture_desc *picture); -void enc_InitCompute_common(vid_enc_PrivateType *priv); -void enc_ReleaseCompute_common(vid_enc_PrivateType *priv); OMX_ERRORTYPE enc_LoadImage_common(vid_enc_PrivateType * priv, OMX_VIDEO_PORTDEFINITIONTYPE *def, OMX_BUFFERHEADERTYPE *buf, struct pipe_video_buffer *vbuf); diff --git a/lib/mesa/src/gallium/state_trackers/osmesa/meson.build b/lib/mesa/src/gallium/state_trackers/osmesa/meson.build index e5848fd99..912a6226f 100644 --- a/lib/mesa/src/gallium/state_trackers/osmesa/meson.build +++ b/lib/mesa/src/gallium/state_trackers/osmesa/meson.build @@ -1,4 +1,4 @@ -# Copyright © 2017-2018 Intel Corporation +# Copyright © 2017 Intel Corporation # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -18,18 +18,10 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. -osmesa_st_c_args = [] -if with_platform_windows - osmesa_st_c_args += ['-DBUILD_GL32', '-DWIN32_LEAN_AND_MEAN'] - if not with_shared_glapi - osmesa_st_c_args += ['-D_GLAPI_NO_EXPORTS'] - endif -endif - libosmesa_st = static_library( 'osmesa_st', 'osmesa.c', - c_args : osmesa_st_c_args, + c_args : ['-DGALLIUM_SOFTPIPE'], include_directories : [ inc_include, inc_src, inc_gallium, inc_gallium_aux, inc_mapi, inc_mesa, ], diff --git a/lib/mesa/src/gallium/state_trackers/va/meson.build b/lib/mesa/src/gallium/state_trackers/va/meson.build index 84f788fdb..eb1491ce4 100644 --- a/lib/mesa/src/gallium/state_trackers/va/meson.build +++ b/lib/mesa/src/gallium/state_trackers/va/meson.build @@ -1,4 +1,4 @@ -# Copyright © 2017-2019 Intel Corporation +# Copyright © 2017-2018 Intel Corporation # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -35,8 +35,5 @@ libva_st = static_library( ), ], include_directories : [inc_common], - dependencies : [ - dep_va_headers, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, - dep_libdrm, - ], + dependencies : [dep_va_headers, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3], ) diff --git a/lib/mesa/src/gallium/state_trackers/va/picture_h264_enc.c b/lib/mesa/src/gallium/state_trackers/va/picture_h264_enc.c index f46b34255..abfd39633 100644 --- a/lib/mesa/src/gallium/state_trackers/va/picture_h264_enc.c +++ b/lib/mesa/src/gallium/state_trackers/va/picture_h264_enc.c @@ -127,14 +127,6 @@ vlVaHandleVAEncSequenceParameterBufferTypeH264(vlVaDriver *drv, vlVaContext *con context->desc.h264enc.rate_ctrl.frame_rate_num = h264->time_scale / 2; context->desc.h264enc.rate_ctrl.frame_rate_den = h264->num_units_in_tick; context->desc.h264enc.pic_order_cnt_type = h264->seq_fields.bits.pic_order_cnt_type; - - if (h264->frame_cropping_flag) { - context->desc.h264enc.pic_ctrl.enc_frame_cropping_flag = h264->frame_cropping_flag; - context->desc.h264enc.pic_ctrl.enc_frame_crop_left_offset = h264->frame_crop_left_offset; - context->desc.h264enc.pic_ctrl.enc_frame_crop_right_offset = h264->frame_crop_right_offset; - context->desc.h264enc.pic_ctrl.enc_frame_crop_top_offset = h264->frame_crop_top_offset; - context->desc.h264enc.pic_ctrl.enc_frame_crop_bottom_offset = h264->frame_crop_bottom_offset; - } return VA_STATUS_SUCCESS; } diff --git a/lib/mesa/src/gallium/state_trackers/va/picture_vp9.c b/lib/mesa/src/gallium/state_trackers/va/picture_vp9.c index b5aca9a51..c1ca54cd0 100644 --- a/lib/mesa/src/gallium/state_trackers/va/picture_vp9.c +++ b/lib/mesa/src/gallium/state_trackers/va/picture_vp9.c @@ -28,8 +28,6 @@ #include "vl/vl_vlc.h" #include "va_private.h" -#define NUM_VP9_REFS 8 - void vlVaHandlePictureParameterBufferVP9(vlVaDriver *drv, vlVaContext *context, vlVaBuffer *buf) { VADecPictureParameterBufferVP9 *vp9 = buf->data; @@ -81,11 +79,8 @@ void vlVaHandlePictureParameterBufferVP9(vlVaDriver *drv, vlVaContext *context, context->desc.vp9.picture_parameter.bit_depth = vp9->bit_depth; - for (i = 0 ; i < NUM_VP9_REFS ; i++) + for (i = 0 ; i < 8 ; i++) vlVaGetReferenceFrame(drv, vp9->reference_frames[i], &context->desc.vp9.ref[i]); - - if (!context->decoder && !context->templat.max_references) - context->templat.max_references = NUM_VP9_REFS; } void vlVaHandleSliceParameterBufferVP9(vlVaContext *context, vlVaBuffer *buf) diff --git a/lib/mesa/src/gallium/state_trackers/vdpau/meson.build b/lib/mesa/src/gallium/state_trackers/vdpau/meson.build index 28c4e9cab..9678b79ef 100644 --- a/lib/mesa/src/gallium/state_trackers/vdpau/meson.build +++ b/lib/mesa/src/gallium/state_trackers/vdpau/meson.build @@ -1,4 +1,4 @@ -# Copyright © 2017, 2019 Intel Corproration +# Copyright © 2017 Intel Corproration # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -18,22 +18,15 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. -VDPAU_MAJOR = 1 -VDPAU_MINOR = 0 - libvdpau_st = static_library( 'vdpau_st', files( 'bitmap.c', 'decode.c', 'device.c', 'ftab.c', 'htab.c', 'mixer.c', 'output.c', 'preemption.c', 'presentation.c', 'query.c', 'surface.c', ), - c_args : [ - c_vis_args, - '-DVER_MAJOR=@0@'.format(VDPAU_MAJOR), - '-DVER_MINOR=@0@'.format(VDPAU_MINOR), - ], + c_args : [c_vis_args, '-DVER_MAJOR=1', '-DVER_MINOR=0'], include_directories : [ inc_include, inc_src, inc_util, inc_gallium, inc_gallium_aux, ], - dependencies : [dep_vdpau, dep_xcb, dep_x11_xcb, dep_xcb_dri2, dep_libdrm], + dependencies : [dep_vdpau, dep_xcb, dep_x11_xcb, dep_xcb_dri2], ) diff --git a/lib/mesa/src/gallium/state_trackers/xa/meson.build b/lib/mesa/src/gallium/state_trackers/xa/meson.build index 44d975862..aff39634b 100644 --- a/lib/mesa/src/gallium/state_trackers/xa/meson.build +++ b/lib/mesa/src/gallium/state_trackers/xa/meson.build @@ -18,7 +18,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. -xa_version = ['2', '5', '0'] +xa_version = ['2', '4', '0'] xa_conf = configuration_data() xa_conf.set('XA_MAJOR', xa_version[0]) diff --git a/lib/mesa/src/gallium/state_trackers/xa/xa_tracker.h.in b/lib/mesa/src/gallium/state_trackers/xa/xa_tracker.h.in index 3d1367071..fc721eed3 100644 --- a/lib/mesa/src/gallium/state_trackers/xa/xa_tracker.h.in +++ b/lib/mesa/src/gallium/state_trackers/xa/xa_tracker.h.in @@ -126,11 +126,6 @@ enum xa_formats { xa_format_x8r8g8b8 = xa_format(32, xa_type_argb, 0, 8, 8, 8), xa_format_r5g6b5 = xa_format(16, xa_type_argb, 0, 5, 6, 5), xa_format_x1r5g5b5 = xa_format(16, xa_type_argb, 0, 5, 5, 5), - xa_format_a4r4g4b4 = xa_format(16, xa_type_argb, 4, 4, 4, 4), - xa_format_a2b10g10r10 = xa_format(32, xa_type_abgr, 2, 10, 10, 10), - xa_format_x2b10g10r10 = xa_format(32, xa_type_abgr, 0, 10, 10, 10), - xa_format_b8g8r8a8 = xa_format(32, xa_type_bgra, 8, 8, 8, 8), - xa_format_b8g8r8x8 = xa_format(32, xa_type_bgra, 0, 8, 8, 8), xa_format_z16 = xa_format_c(16, xa_type_z, 16, 0), xa_format_z32 = xa_format_c(32, xa_type_z, 32, 0), diff --git a/lib/mesa/src/gallium/state_trackers/xvmc/meson.build b/lib/mesa/src/gallium/state_trackers/xvmc/meson.build index ab658fcad..d120d533e 100644 --- a/lib/mesa/src/gallium/state_trackers/xvmc/meson.build +++ b/lib/mesa/src/gallium/state_trackers/xvmc/meson.build @@ -1,4 +1,4 @@ -# Copyright © 2017, 2019 Intel Corporation +# Copyright © 2017 Intel Corporation # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -23,29 +23,20 @@ libxvmc_st = static_library( files('attributes.c', 'block.c', 'context.c', 'surface.c', 'subpicture.c'), c_args : [c_vis_args], include_directories : [inc_common], - dependencies : [ - dep_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, dep_xv, - dep_libdrm, - ], + dependencies : [dep_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3], ) -# These tests will not work without a working xvmc configuration. +# These tests will not work without a working xvmc configuration. if with_tools.contains('xvmc') - # pkg-config was added in 1.0.12, so allow fallback - dep_xvmcw = dependency('xvmc-wrapper', required : false) - if not dep_xvmcw.found() - dep_xvmcw = cc.find_library('XvMCW') - endif + dep_xvmcw = cc.find_library('XvMCW') dep_real_xvmc = dependency('xvmc') - foreach x : ['context', 'surface', 'subpicture', 'blocks', 'rendering'] _name = 'xvmc_@0@'.format(x) executable( _name, files('tests/test_@0@.c'.format(x), 'tests/testlib.c'), dependencies : [ - dep_real_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, - dep_xvmcw, dep_xv, + dep_real_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, dep_xvmcw, ], install: true, ) @@ -55,8 +46,7 @@ if with_tools.contains('xvmc') 'xvmc_bench', files('tests/xvmc_bench.c', 'tests/testlib.c'), dependencies : [ - dep_real_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, - dep_xvmcw, dep_xv, + dep_real_xvmc, dep_x11_xcb, dep_xcb, dep_xcb_dri2, dep_xcb_dri3, dep_xvmcw, ], install: true, ) |