OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_CPP_DEV_GRAPHICS_3D_DEV_H_ | 5 #ifndef PPAPI_CPP_DEV_GRAPHICS_3D_DEV_H_ |
6 #define PPAPI_CPP_DEV_GRAPHICS_3D_DEV_H_ | 6 #define PPAPI_CPP_DEV_GRAPHICS_3D_DEV_H_ |
7 | 7 |
8 #include "ppapi/c/dev/ppb_graphics_3d_dev.h" | 8 #include "ppapi/c/dev/ppb_graphics_3d_dev.h" |
9 #include "ppapi/c/dev/ppb_opengles_dev.h" | 9 #include "ppapi/c/dev/ppb_opengles_dev.h" |
| 10 #include "ppapi/cpp/completion_callback.h" |
10 #include "ppapi/cpp/instance.h" | 11 #include "ppapi/cpp/instance.h" |
11 #include "ppapi/cpp/resource.h" | 12 #include "ppapi/cpp/resource.h" |
12 | 13 |
13 namespace pp { | 14 namespace pp { |
14 | 15 |
15 class Graphics3D_Dev : public Resource { | 16 class Graphics3D_Dev : public Resource { |
16 public: | 17 public: |
17 static bool GetConfigs(int32_t* configs, int32_t config_size, | 18 static bool GetConfigs(int32_t* configs, int32_t config_size, |
18 int32_t* num_config); | 19 int32_t* num_config); |
19 | 20 |
(...skipping 14 matching lines...) Expand all Loading... |
34 | 35 |
35 // Creates an is_null() Graphics3D object. | 36 // Creates an is_null() Graphics3D object. |
36 Graphics3D_Dev() {} | 37 Graphics3D_Dev() {} |
37 | 38 |
38 Graphics3D_Dev(const Instance& instance, | 39 Graphics3D_Dev(const Instance& instance, |
39 int32_t config, | 40 int32_t config, |
40 int32_t share_context, | 41 int32_t share_context, |
41 const int32_t* attrib_list); | 42 const int32_t* attrib_list); |
42 | 43 |
43 bool MakeCurrent() const; | 44 bool MakeCurrent() const; |
44 bool SwapBuffers() const; | 45 bool SwapBuffers(const CompletionCallback& cc) const; |
45 | 46 |
46 protected: | 47 protected: |
47 explicit Graphics3D_Dev(PP_Resource resource_id) : Resource(resource_id) {} | 48 explicit Graphics3D_Dev(PP_Resource resource_id) : Resource(resource_id) {} |
48 static Graphics3D_Dev FromResource(PP_Resource resource_id); | 49 static Graphics3D_Dev FromResource(PP_Resource resource_id); |
49 }; | 50 }; |
50 | 51 |
51 } // namespace pp | 52 } // namespace pp |
52 | 53 |
53 #endif // PPAPI_CPP_DEV_GRAPHICS_3D_DEV_H_ | 54 #endif // PPAPI_CPP_DEV_GRAPHICS_3D_DEV_H_ |
54 | 55 |
OLD | NEW |