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

Side by Side Diff: ppapi/shared_impl/tracker_base.h

Issue 7545014: Implement PPAPI VideoDecode out-of-process support (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: responding to brettw Created 9 years, 4 months 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/proxy/resource_creation_proxy.cc ('k') | ppapi/shared_impl/video_decoder_impl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PPAPI_SHARED_IMPL_TRACKER_BASE_H_ 5 #ifndef PPAPI_SHARED_IMPL_TRACKER_BASE_H_
6 #define PPAPI_SHARED_IMPL_TRACKER_BASE_H_ 6 #define PPAPI_SHARED_IMPL_TRACKER_BASE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "ppapi/c/pp_instance.h" 10 #include "ppapi/c/pp_instance.h"
11 #include "ppapi/c/pp_resource.h" 11 #include "ppapi/c/pp_resource.h"
12 #include "ppapi/proxy/interface_id.h" 12 #include "ppapi/proxy/interface_id.h"
13 13
14 namespace ppapi { 14 namespace ppapi {
15 15
16 class FunctionGroupBase; 16 class FunctionGroupBase;
17 class ResourceObjectBase; 17 class ResourceObjectBase;
18 class Var; 18 class Var;
19 19
20 // Tracks resource and function APIs, providing a mapping between ID and 20 // Tracks resource and function APIs, providing a mapping between ID and
21 // object. 21 // object.
22 // TODO(brettw) Eventually this should be one object with global tracking and 22 // TODO(brettw) Eventually this should be one object with global tracking and
23 // called "Tracker", and this would be used in both the plugin side of the 23 // called "Tracker", and this would be used in both the plugin side of the
24 // proxy as well as the implementation in the renderer. Currently, all this 24 // proxy as well as the implementation in the renderer. Currently, all this
25 // does is forward to the process-type-specific tracker to get the information. 25 // does is forward to the process-type-specific tracker to get the information.
26 // TODO(fischman/vrk): When brettw fixes the TODO above, fix the ugliness in
27 // VideoDecoderImpl accordingly.
26 class TrackerBase { 28 class TrackerBase {
27 public: 29 public:
28 // Must be called before any other function that uses the TrackerBase. 30 // Must be called before any other function that uses the TrackerBase.
29 // This sets the getter that returns the global implmenetation of 31 // This sets the getter that returns the global implmenetation of
30 // TrackerBase. It will be different for in the renderer and in the plugin 32 // TrackerBase. It will be different for in the renderer and in the plugin
31 // process. 33 // process.
32 static void Init(TrackerBase*(*getter)()); 34 static void Init(TrackerBase*(*getter)());
33 35
34 // Retrieves the global tracker. This will be NULL if you haven't called 36 // Retrieves the global tracker. This will be NULL if you haven't called
35 // Init() first (it should be unnecessary to NULL-check this). 37 // Init() first (it should be unnecessary to NULL-check this).
(...skipping 20 matching lines...) Expand all
56 // Retrieves a var from the tracker, returning an empty scoped ptr on failure. 58 // Retrieves a var from the tracker, returning an empty scoped ptr on failure.
57 virtual scoped_refptr<Var> GetVar(int32 var_id) const = 0; 59 virtual scoped_refptr<Var> GetVar(int32 var_id) const = 0;
58 60
59 virtual bool AddRefVar(int32 var_id) = 0; 61 virtual bool AddRefVar(int32 var_id) = 0;
60 virtual bool UnrefVar(int32 var_id) = 0; 62 virtual bool UnrefVar(int32 var_id) = 0;
61 }; 63 };
62 64
63 } // namespace ppapi 65 } // namespace ppapi
64 66
65 #endif // PPAPI_SHARED_IMPL_TRACKER_BASE_H_ 67 #endif // PPAPI_SHARED_IMPL_TRACKER_BASE_H_
OLDNEW
« no previous file with comments | « ppapi/proxy/resource_creation_proxy.cc ('k') | ppapi/shared_impl/video_decoder_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698