summaryrefslogtreecommitdiff
path: root/gst-libs
AgeCommit message (Collapse)AuthorFilesLines
2020-05-27libs: subpicture: Make subpicture a standard GstMiniObject.He Junyan3-61/+83
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/331>
2020-05-26libs: decoder: h264: Add ref flags for splited field.He Junyan1-0/+3
When split one frame into fields, the second field should also copy the reference flags. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/333>
2020-05-25libs: decoder: h264: disallow multiple slice groupVíctor Manuel Jáquez Leal1-0/+6
As far as we know there are no VAAPI drivers supporting FMO, which migth be used in baseline streams. This commit is a continuation of https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/328 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/332>
2020-05-21vaapidecoder: h264: remove baseline as constrained propertyVíctor Manuel Jáquez Leal2-28/+5
From now on always the baseline is going to be treated as constrained without need of setting a property. Since the property was added along the development cycle (1.17 / commit 866a9f06) and never released, we assume that it is safe to remove it. Fixes: #252 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/328>
2020-05-21vaapiencoder_h264: set direct_spatial_mv_pred_flag to true by defaultHaihao Xiang1-1/+1
This flag is set to true by default in both MediaSDK and FFmpeg-vaapi, so let's align this plugin with other libraries / softwares. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/329>
2020-05-16libs: use array_unref() rather than array_free()Víctor Manuel Jáquez Leal5-37/+10
It is more convinience and thread-safe. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/325>
2020-05-16libs: video-format: add a helper function of get_formats_by_chroma.He Junyan2-0/+36
The function iterates all supported video formats and returns the formats belong to the specified chroma type. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/315>
2020-05-16libs: texture: remove unused headers includeVíctor Manuel Jáquez Leal2-3/+1
This is continuation of https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/317 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/324>
2020-05-16libs: removed duplicated function declarationsVíctor Manuel Jáquez Leal3-3/+0
Some headers had duplicated inlined function declaration. This was for gtkdoc, but now GStreamer uses hotdoc and the internal library documentation is not generated. So let's remove these extra lines. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/323>
2020-05-16libs: texture: Make texture a standard GstMiniObject.He Junyan7-310/+343
We store GstVaapiTextureGLX and GstVaapiTextureEGL's private data in the qdata of miniobject and avoid extending the base texture class. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/317>
2020-04-26libs: display: drm: use g_strcmp0 to be null safeVíctor Manuel Jáquez Leal1-1/+1
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/321>
2020-04-04libs: bufferproxy: remove GstMemory referenceHe Junyan3-47/+0
Since bufferproxy and surface are not referenced circularly, there's no need to keep, in the buffer proxy, a reference to the GstMemory where it is held. This patch removes that handling.
2020-04-04libs,plugin: break surface-bufferproxy circular referenceHe Junyan4-17/+43
The bufferproxy may reference the surface and the surface may also reference the bufferproxy, producing a circular reference, which might lead to serious resource leak problems. Now make the relationship clearer, the bufferproxy's references is transfered to surface, while bufferproxy just keeps the surface's address without increasing its reference count. The surface can be created through a bufferproxy like in gst_vaapi_surface_new_with_dma_buf_handle(), and the surface might get its bufferproxy via gst_vaapi_surface_get_dma_buf_handle(). In both cases the surface holds a bufferproxy's reference.
2020-04-04libs: bufferproxy: rename parent memeber as surfaceHe Junyan3-14/+12
2020-04-03libs: filter: HDR10 tone mapping supportU. Artie Eoff2-0/+183
Add support for HDR10 tone mapping (since VA-API 1.4.0).
2020-04-02libs: encoder: h265: Support MAIN 4:4:4 10 profile.He Junyan4-2/+31
Using Y410 as the input of the encoder can generate main_444_10 bit streams.
2020-04-02libs: encoder: fix an inexact trace info in chroma type check.He Junyan1-2/+3
2020-03-31libs: encoder: make sure format array is not NULL when returning TRUEHaihao Xiang1-1/+5
This fixed segfault when running the pipeline below with iHD driver (commit efe5e9a) on ICL gst-launch-1.0 videotestsrc ! vaapivp9enc tune=low-power ! vaapivp9dec ! \ fakesink
2020-03-27libs: extend g_autoptr supportVíctor Manuel Jáquez Leal30-16/+45
2020-03-20libs,plugins: decoder: Add -intra profile support for hevc.He Junyan2-0/+64
In hevc, we can consider the -intra profile a subset of the none -intra profile. The -intra profiles just contain I frames and we definitely can use the none -intra profiles's context to decode them. Signed-off-by: Víctor Manuel Jáquez Leal <vjaquez@igalia.com>
2020-03-20libs: encoder: h265: support ICQ/QVBR BRCU. Artie Eoff1-1/+39
Enable support for ICQ and QVBR bitrate control. The code is essentially the same for h264 ICQ/QVBR support which was added in commit 9e0c133a2403.
2020-03-19libs: encoder: set VA HRD param before RC paramU. Artie Eoff1-8/+8
This is a workaround for intel-media-driver bug https://github.com/intel/media-driver/issues/865 The driver will force the RC method to CBR for HEVCe when it parses the HRD param. Thus, any RC method param submitted "prior" to the HRD param will be lost. Therefore, VBR, ICQ and QVBR for HEVCe can't be effectively enabled if the RC method param "precedes" the HRD param. To work around this issue, set the HRD param before the RC method param so the driver will parse the RC method param "after" the HRD param. Afaict, other codecs in the driver (and other drivers) do not appear to be dependent on the order of HRD and RC param submission.
2020-03-17vaapijpegenc: Add a quantization quirk for iHD driverHaihao Xiang3-5/+27
iHD driver shifts the value by 50 when calculating quantization for JPEG encoding, so we should add 50 in this plugin for iHD driver too.
2020-03-17libs: remove GstVaapiPixmapVíctor Manuel Jáquez Leal14-1012/+6
GstVaapiPixmap is an abstract base class which only implementation were GstVaapiPixmapX11. This class were used for a special type of rendering in the tests apps, utterly unrelated in GStreamer. Since gstreamer-vaapi is no longer a general-user wrapper for VA-API we should remove this unused API. This removal drops libxrender dependency.
2020-03-17libs: utils: Add HEVC Main444 sting in string_of_VAProfileHe Junyan1-0/+1
HEVCMain444_10 is already a supported profile and misses the strings.
2020-03-06libs: videopool: fix a condition race for pool allocate.He Junyan1-0/+7
2020-03-04libs: decoder: h265: parser state after update dependent sliceXu Guangxin1-2/+2
If the dependent_slice_segment_flag is true, most slice info derived from last slice. So we need check the slice type after we call populate_dependent_slice_hdr
2020-02-28libs: display: force RGBA image format for i965 driverVíctor Manuel Jáquez Leal2-2/+32
Since commit 32bf6f1e GLTextureUpload is broken because i965 doesn't report properly RGBA support. It could be possible to use RGBx but GLTextureUpload only regotiates RGBA. The simplest fix to this regression is adding synthetically the RGBA format in the internal format map.
2020-02-28libs: display: iterate all quirks tableVíctor Manuel Jáquez Leal1-3/+3
Instead of break at the fist foud quirk in the table, iterate all over so it would be feasible to add several quirks for one driver per element in array.
2020-02-28libs: filter: handle RGB to/from YUV color primary driver quirkU. Artie Eoff1-20/+41
The intel-media-driver (iHD) can't convert output color primaries when doing YUV to/from RGB CSC. Thus, we must keep the output color primaries the same as the input color primaries for this case. fixes #238
2020-02-28libs: display: add YUV to/from RGB color primary quirkU. Artie Eoff2-0/+9
The intel-media-driver (iHD) can't convert output color primaries when doing YUV to/from RGB CSC.
2020-02-23libs: surface: Add hints to allocation flags.Víctor Manuel Jáquez Leal2-1/+27
When creating surfaces it is possible to pass to VA hints of its usage, so the driver may do some optimizations. This commit adds the handling of encoding/decoding hints.
2020-02-23libs: surface: surfacepool: Add allocation flags in constructors.Víctor Manuel Jáquez Leal7-13/+22
2020-02-21libs: h265enc: Set max_transform_hierarchy_depth_{inter, intra} to 2Haihao Xiang1-2/+8
Intel HW has limitation on max_transform_hierarchy_depth_inter and max_transform_hierarchy_depth_intra (see [1]). We can provide a quirk for other HWs if other HWs may support other values [1] https://01.org/sites/default/files/documentation/intel-gfx-prm-osrc-kbl-vol10-hevc.pdf
2020-02-21libs: blend: filter: handle finalize() if display isn't assignedVíctor Manuel Jáquez Leal2-0/+8
I've just discovered iHD driver in Skylake doesn't have VideoProc entry point, hence, in this platform, when vaapioverlay is tried to be registered, critical warnings are raised because blend doesn't have a display assigned. As it is possible to have drivers without EntryPointVideoProc it is required to handle it gracefully. This patch does that: only tries to register vaapioverlay if the testing display has VPP and finalize() vmethods, in filter and blend, bail out if display is NULL.
2020-02-21libs: filter: guard all color properties to VA-API 1.2.0U. Artie Eoff2-3/+12
Older VA-API (0.39.0) doesn't have VAProcColorProperties. Thus, guard all colorimetry -> VA-API support to version 1.2.0. Fixes #234
2020-02-17libs: decoder: h265: set parser info state at decoding codec dataVíctor Manuel Jáquez Leal1-0/+3
Commit 1168d6d5 showed up a regression: decode_sps() stores the unit's parser info in sps array. If that parser info comes from decoding codec data, that parser info will have an undefined state which might break ensure_sps(). This patch sets the parser info state, at decoding codec data, with the internal parser state. This is similar with h264 decoder apprach. Original-patch-by: Xu Guangxin <guangxin.xu@intel.com>
2020-02-16libs: video-format: set general vaapi log categoryVíctor Manuel Jáquez Leal1-0/+3
Instead of logging in an unspecified category, set the default vaapi.
2020-02-15libs: utils: guard EncSliceLP for VA-API < 0.39.1U. Artie Eoff1-0/+2
Relates to #234
2020-02-14libs: h265enc: Set VA_PICTURE_HEVC_INVALID flag for invalid pictureHaihao Xiang1-3/+3
2020-02-11libs: remove crumbs of libva < 0.39Víctor Manuel Jáquez Leal3-49/+0
All these guarded code seem like leftovers of commit 920b1ec7a. This patch completes that missing clean up.
2020-02-11libs: VA explicit color standard not supported until 1.2.0U. Artie Eoff2-0/+7
VAProcColorStandardExplicit and associated VAProcColorProperties (primaries, transfer and matrix) are not supported until VA-API 1.2.0. Use VAProcColorStandardNone instead of VAProcColorStandardExplicit if VA-API < 1.2.0. Fixes #231
2020-02-10libs: utils: WA: use explicit for sRGB colorimetryU. Artie Eoff1-2/+0
Addresses #228 on iHD side. It seems iHD can't handle VAProcColorStandardSRGB in all situations for vpp. But it has no problem when we specify the sRGB parameters via VAProcColorStandardExplicit parameters.
2020-02-08libs: filter: set vpp input/output color rangeU. Artie Eoff1-0/+2
We've always sent VA_SOURCE_RANGE_UNKNOWN to the driver. And, the [iHD] driver essentially computes the same color range as gstreamer when we send VA_SOURCE_RANGE_UNKNOWN for cases were gstreamer computes it automatically. But, if the user wants to make it explicit, we should try to honor it.
2020-02-08libs: utils: map GstVideoColorRange to VAAPI VPPU. Artie Eoff2-0/+25
2020-02-05libs: filter: support vpp input/output color standardU. Artie Eoff2-2/+115
Add API function to allow setting the input and output vpp color standard from GstVideoColorimetry.
2020-02-05libs: utils: map GstVideoColorimetry to VAAPI VPPU. Artie Eoff2-0/+41
Fallback to VAProcColorStandardExplicit if there is no 1:1 mapping.
2020-02-04libs: display: add vpp color standard quirk for i965 driverU. Artie Eoff2-0/+4
The i965 does not properly report supported vpp color standards.
2020-01-29libs: display: log out vendor string when availableVíctor Manuel Jáquez Leal1-0/+1
This is useful while asking for logs to know the used driver.
2020-01-28libs: surface: initialize VASurfaceAttribExternalBuffersVíctor Manuel Jáquez Leal1-3/+2
Initialize VASurfaceAttribExternalBuffers using compiler's syntax rather than using memset().