mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-01 05:39:51 +00:00
vaallocator: only i965 can switch derived/non-derived at mapping
Since newer drivers change the strides and offset, and they have to be defined at allocation time because those parameters are stored in the GstVideoMeta in the buffer pool. Thinks patch is based on commit6b1fba14
and commit809a984b
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5778>
This commit is contained in:
parent
099741e35f
commit
8944d5326e
1 changed files with 0 additions and 13 deletions
|
@ -1372,13 +1372,6 @@ _va_map_unlocked (GstVaMemory * mem, GstMapFlags flags)
|
|||
use_derived = FALSE;
|
||||
} else {
|
||||
switch (gst_va_display_get_implementation (display)) {
|
||||
case GST_VA_IMPLEMENTATION_INTEL_IHD:
|
||||
/* On Gen7+ Intel graphics the memory is mappable but not
|
||||
* cached, so normal memcpy() access is very slow to read, but
|
||||
* it's ok for writing. So let's assume that users won't prefer
|
||||
* direct-mapped memory if they request read access. */
|
||||
use_derived = va_allocator->use_derived && !(flags & GST_MAP_READ);
|
||||
break;
|
||||
case GST_VA_IMPLEMENTATION_INTEL_I965:
|
||||
/* YUV derived images are tiled, so writing them is also
|
||||
* problematic */
|
||||
|
@ -1386,12 +1379,6 @@ _va_map_unlocked (GstVaMemory * mem, GstMapFlags flags)
|
|||
|| ((flags & GST_MAP_WRITE)
|
||||
&& GST_VIDEO_INFO_IS_YUV (&va_allocator->info)));
|
||||
break;
|
||||
case GST_VA_IMPLEMENTATION_MESA_GALLIUM:
|
||||
/* Reading RGB derived images, with non-standard resolutions,
|
||||
* looks like tiled too. TODO(victor): fill a bug in Mesa. */
|
||||
use_derived = va_allocator->use_derived && !((flags & GST_MAP_READ)
|
||||
&& GST_VIDEO_INFO_IS_RGB (&va_allocator->info));
|
||||
break;
|
||||
default:
|
||||
use_derived = va_allocator->use_derived;
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue