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 | 5 |
6 #ifndef PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ | 6 #ifndef PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ |
7 #define PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ | 7 #define PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ |
8 | 8 |
9 #include "ppapi/c/dev/pp_graphics_3d_dev.h" | 9 #include "ppapi/c/dev/pp_graphics_3d_dev.h" |
10 #include "ppapi/c/pp_bool.h" | 10 #include "ppapi/c/pp_bool.h" |
| 11 #include "ppapi/c/pp_completion_callback.h" |
11 #include "ppapi/c/pp_instance.h" | 12 #include "ppapi/c/pp_instance.h" |
12 #include "ppapi/c/pp_resource.h" | 13 #include "ppapi/c/pp_resource.h" |
13 | 14 |
14 #define PPB_SURFACE_3D_DEV_INTERFACE "PPB_Surface3D(Dev);0.1" | 15 #define PPB_SURFACE_3D_DEV_INTERFACE "PPB_Surface3D(Dev);0.1" |
15 | 16 |
16 struct PPB_Surface3D_Dev { | 17 struct PPB_Surface3D_Dev { |
17 // Creates a render surface and returns a handle to it. | 18 // Creates a render surface and returns a handle to it. |
18 // Any PPB_Context3D_Dev created with a compatible PP_Config3D_Dev | 19 // Any PPB_Context3D_Dev created with a compatible PP_Config3D_Dev |
19 // can be used to render into this surface. The returned surface is | 20 // can be used to render into this surface. The returned surface is |
20 // off-screen to start with. It must be attached to a plugin instance | 21 // off-screen to start with. It must be attached to a plugin instance |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 // plugin's current state is actually on the screen, this function provides a | 103 // plugin's current state is actually on the screen, this function provides a |
103 // way to rate limit animations. By waiting until the image is on the screen | 104 // way to rate limit animations. By waiting until the image is on the screen |
104 // before painting the next frame, you can ensure you're not generating | 105 // before painting the next frame, you can ensure you're not generating |
105 // updates faster than the screen can be updated. | 106 // updates faster than the screen can be updated. |
106 // | 107 // |
107 int32_t (*SwapBuffers)(PP_Resource surface, | 108 int32_t (*SwapBuffers)(PP_Resource surface, |
108 struct PP_CompletionCallback callback); | 109 struct PP_CompletionCallback callback); |
109 }; | 110 }; |
110 | 111 |
111 #endif // PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ | 112 #endif // PPAPI_C_DEV_PPB_SURFACE_3D_DEV_H_ |
OLD | NEW |