diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-03-12 09:13:00 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-03-16 09:58:26 +0000 |
commit | 03561cae90f1d99b5c54b1ef3be69f10e882b25e (patch) | |
tree | cc5f0958e823c044e7ae51cc0117fe51432abe5e /chromium/media/gpu/vaapi/vaapi_picture_tfp.cc | |
parent | fa98118a45f7e169f8846086dc2c22c49a8ba310 (diff) | |
download | qtwebengine-chromium-03561cae90f1d99b5c54b1ef3be69f10e882b25e.tar.gz |
BASELINE: Update Chromium to 88.0.4324.208
Change-Id: I3ae87d23e4eff4b4a469685658740a213600c667
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/media/gpu/vaapi/vaapi_picture_tfp.cc')
-rw-r--r-- | chromium/media/gpu/vaapi/vaapi_picture_tfp.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/chromium/media/gpu/vaapi/vaapi_picture_tfp.cc b/chromium/media/gpu/vaapi/vaapi_picture_tfp.cc index a571b4b2b41..7b604f19f33 100644 --- a/chromium/media/gpu/vaapi/vaapi_picture_tfp.cc +++ b/chromium/media/gpu/vaapi/vaapi_picture_tfp.cc @@ -8,7 +8,6 @@ #include "media/gpu/vaapi/vaapi_wrapper.h" #include "ui/base/ui_base_features.h" #include "ui/gfx/x/connection.h" -#include "ui/gfx/x/x11_types.h" #include "ui/gl/gl_bindings.h" #include "ui/gl/gl_image_glx.h" #include "ui/gl/scoped_binders.h" @@ -35,7 +34,7 @@ VaapiTFPPicture::VaapiTFPPicture( client_texture_id, texture_target), connection_(x11::Connection::Get()), - x_pixmap_(0) { + x_pixmap_(x11::Pixmap::None) { DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); DCHECK(!features::IsUsingOzonePlatform()); DCHECK(texture_id); @@ -49,13 +48,13 @@ VaapiTFPPicture::~VaapiTFPPicture() { DCHECK_EQ(glGetError(), static_cast<GLenum>(GL_NO_ERROR)); } - if (x_pixmap_) - connection_->FreePixmap({static_cast<x11::Pixmap>(x_pixmap_)}); + if (x_pixmap_ != x11::Pixmap::None) + connection_->FreePixmap({x_pixmap_}); } Status VaapiTFPPicture::Initialize() { DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - DCHECK(x_pixmap_); + DCHECK_NE(x_pixmap_, x11::Pixmap::None); if (make_context_current_cb_ && !make_context_current_cb_.Run()) return StatusCode::kVaapiBadContext; @@ -111,7 +110,7 @@ Status VaapiTFPPicture::Allocate(gfx::BufferFormat format) { DLOG(ERROR) << "Failed creating an X Pixmap for TFP"; return StatusCode::kVaapiNoPixmap; } else { - x_pixmap_ = base::strict_cast<::Pixmap>(pixmap); + x_pixmap_ = pixmap; } return Initialize(); |