Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(129)

Side by Side Diff: content/common/gpu/media/vaapi_picture_provider_drm.h

Issue 490233002: VaapiVideoAccelerator: make Vaapi accelerator work with ozone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Enable vaapi_h264_decoder_unittest on Ozone Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 //
5 // This file contains an implementation of picture allocation for the
6 // Ozone window system used by VaapiPictureProvider to produce output
7 // pictures.
8
9 #ifndef CONTENT_COMMON_GPU_MEDIA_VAAPI_PICTURE_PROVIDER_DRM_H_
10 #define CONTENT_COMMON_GPU_MEDIA_VAAPI_PICTURE_PROVIDER_DRM_H_
11
12 #include "base/callback.h"
13 #include "content/common/gpu/media/vaapi_picture_provider.h"
14 #include "third_party/libva/va/va.h"
15 #include "ui/gfx/size.h"
16
17 namespace content {
18
19 class VaapiWrapper;
20
21 // Implementation of the VaapiPictureProvider for the ozone/drm backed
22 // chromium.
23 class DrmVaapiPictureProvider : public VaapiPictureProvider {
24 public:
25 DrmVaapiPictureProvider(
26 scoped_refptr<VaapiWrapper> vaapi_wrapper,
27 const base::Callback<bool(void)> make_context_current);
28 virtual ~DrmVaapiPictureProvider();
29
30 protected:
31 virtual linked_ptr<VaapiPictureProvider::Picture> AllocatePicture(
32 int32 picture_buffer_id,
33 uint32 texture_id,
34 const gfx::Size& size) override;
35
36 private:
37 virtual bool Initialize() override;
38
39 base::Callback<bool(void)> make_context_current_;
40
41 scoped_refptr<VaapiWrapper> vaapi_wrapper_;
42
43 DISALLOW_COPY_AND_ASSIGN(DrmVaapiPictureProvider);
44 };
45
46 } // namespace content
47
48 #endif // CONTENT_COMMON_GPU_MEDIA_VAAPI_PICTURE_PROVIDER_DRM_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698