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

Side by Side Diff: ppapi/proxy/ppapi_messages.h

Issue 7545014: Implement PPAPI VideoDecode out-of-process support (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: responses to ddorwin and piman 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
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 // Multiply-included message header, no traditional include guard. 5 // Multiply-included message header, no traditional include guard.
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
11 #include "base/process.h" 11 #include "base/process.h"
12 #include "base/shared_memory.h" 12 #include "base/shared_memory.h"
13 #include "base/string16.h" 13 #include "base/string16.h"
14 #include "base/sync_socket.h" 14 #include "base/sync_socket.h"
15 #include "gpu/command_buffer/common/command_buffer.h" 15 #include "gpu/command_buffer/common/command_buffer.h"
16 #include "gpu/ipc/gpu_command_buffer_traits.h" 16 #include "gpu/ipc/gpu_command_buffer_traits.h"
17 #include "ipc/ipc_channel_handle.h" 17 #include "ipc/ipc_channel_handle.h"
18 #include "ipc/ipc_message_macros.h" 18 #include "ipc/ipc_message_macros.h"
19 #include "ipc/ipc_message_utils.h" 19 #include "ipc/ipc_message_utils.h"
20 #include "ipc/ipc_platform_file.h" 20 #include "ipc/ipc_platform_file.h"
21 #include "ppapi/c/pp_bool.h" 21 #include "ppapi/c/pp_bool.h"
22 #include "ppapi/c/pp_file_info.h" 22 #include "ppapi/c/pp_file_info.h"
23 #include "ppapi/c/pp_instance.h" 23 #include "ppapi/c/pp_instance.h"
24 #include "ppapi/c/pp_module.h" 24 #include "ppapi/c/pp_module.h"
25 #include "ppapi/c/pp_point.h" 25 #include "ppapi/c/pp_point.h"
26 #include "ppapi/c/pp_rect.h" 26 #include "ppapi/c/pp_rect.h"
27 #include "ppapi/c/pp_resource.h" 27 #include "ppapi/c/pp_resource.h"
28 #include "ppapi/c/pp_size.h" 28 #include "ppapi/c/pp_size.h"
29 #include "ppapi/c/dev/pp_video_dev.h"
29 #include "ppapi/c/private/ppb_flash_tcp_socket.h" 30 #include "ppapi/c/private/ppb_flash_tcp_socket.h"
30 #include "ppapi/proxy/ppapi_param_traits.h" 31 #include "ppapi/proxy/ppapi_param_traits.h"
31 #include "ppapi/proxy/serialized_flash_menu.h" 32 #include "ppapi/proxy/serialized_flash_menu.h"
32 #include "ppapi/proxy/serialized_structs.h" 33 #include "ppapi/proxy/serialized_structs.h"
33 #include "ppapi/shared_impl/input_event_impl.h" 34 #include "ppapi/shared_impl/input_event_impl.h"
34 #include "ppapi/shared_impl/ppapi_preferences.h" 35 #include "ppapi/shared_impl/ppapi_preferences.h"
35 36
36 #define IPC_MESSAGE_START PpapiMsgStart 37 #define IPC_MESSAGE_START PpapiMsgStart
37 38
38 IPC_ENUM_TRAITS(PP_InputEvent_Type) 39 IPC_ENUM_TRAITS(PP_InputEvent_Type)
(...skipping 12 matching lines...) Expand all
51 IPC_STRUCT_TRAITS_BEGIN(PP_Size) 52 IPC_STRUCT_TRAITS_BEGIN(PP_Size)
52 IPC_STRUCT_TRAITS_MEMBER(height) 53 IPC_STRUCT_TRAITS_MEMBER(height)
53 IPC_STRUCT_TRAITS_MEMBER(width) 54 IPC_STRUCT_TRAITS_MEMBER(width)
54 IPC_STRUCT_TRAITS_END() 55 IPC_STRUCT_TRAITS_END()
55 56
56 IPC_STRUCT_TRAITS_BEGIN(PP_Rect) 57 IPC_STRUCT_TRAITS_BEGIN(PP_Rect)
57 IPC_STRUCT_TRAITS_MEMBER(point) 58 IPC_STRUCT_TRAITS_MEMBER(point)
58 IPC_STRUCT_TRAITS_MEMBER(size) 59 IPC_STRUCT_TRAITS_MEMBER(size)
59 IPC_STRUCT_TRAITS_END() 60 IPC_STRUCT_TRAITS_END()
60 61
62 IPC_STRUCT_TRAITS_BEGIN(PP_PictureBuffer_Dev)
63 IPC_STRUCT_TRAITS_MEMBER(id)
64 IPC_STRUCT_TRAITS_MEMBER(size)
65 IPC_STRUCT_TRAITS_MEMBER(texture_id)
66 IPC_STRUCT_TRAITS_END()
67
61 IPC_STRUCT_TRAITS_BEGIN(::ppapi::Preferences) 68 IPC_STRUCT_TRAITS_BEGIN(::ppapi::Preferences)
62 IPC_STRUCT_TRAITS_MEMBER(standard_font_family) 69 IPC_STRUCT_TRAITS_MEMBER(standard_font_family)
63 IPC_STRUCT_TRAITS_MEMBER(fixed_font_family) 70 IPC_STRUCT_TRAITS_MEMBER(fixed_font_family)
64 IPC_STRUCT_TRAITS_MEMBER(serif_font_family) 71 IPC_STRUCT_TRAITS_MEMBER(serif_font_family)
65 IPC_STRUCT_TRAITS_MEMBER(sans_serif_font_family) 72 IPC_STRUCT_TRAITS_MEMBER(sans_serif_font_family)
66 IPC_STRUCT_TRAITS_MEMBER(default_font_size) 73 IPC_STRUCT_TRAITS_MEMBER(default_font_size)
67 IPC_STRUCT_TRAITS_MEMBER(default_fixed_font_size) 74 IPC_STRUCT_TRAITS_MEMBER(default_fixed_font_size)
68 IPC_STRUCT_TRAITS_END() 75 IPC_STRUCT_TRAITS_END()
69 76
70 IPC_STRUCT_TRAITS_BEGIN(::ppapi::InputEventData) 77 IPC_STRUCT_TRAITS_BEGIN(::ppapi::InputEventData)
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 312
306 // PPB_URLLoader 313 // PPB_URLLoader
307 // (Messages from browser to plugin to notify it of changes in state.) 314 // (Messages from browser to plugin to notify it of changes in state.)
308 IPC_MESSAGE_ROUTED1(PpapiMsg_PPBURLLoader_UpdateProgress, 315 IPC_MESSAGE_ROUTED1(PpapiMsg_PPBURLLoader_UpdateProgress,
309 pp::proxy::PPBURLLoader_UpdateProgress_Params /* params */) 316 pp::proxy::PPBURLLoader_UpdateProgress_Params /* params */)
310 IPC_MESSAGE_ROUTED3(PpapiMsg_PPBURLLoader_ReadResponseBody_Ack, 317 IPC_MESSAGE_ROUTED3(PpapiMsg_PPBURLLoader_ReadResponseBody_Ack,
311 pp::proxy::HostResource /* loader */, 318 pp::proxy::HostResource /* loader */,
312 int32 /* result */, 319 int32 /* result */,
313 std::string /* data */) 320 std::string /* data */)
314 321
322 // PPB_VideoDecoder_Dev.
323 // (Messages from renderer to plugin to notify it to run callbacks.)
324 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBVideoDecoder_EndOfBitstreamACK,
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 s/ACK/Callback/g ? I guess ACK is also used elsewh
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Yeah, I'm not a fan of ACK, either. brettw/piman
325 pp::proxy::HostResource /* video_decoder */,
326 int32_t /* pp_error */)
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 pp_error doesn't name a type. The only thing I can
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 I changed it to "error result for callback," a des
327 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBVideoDecoder_FlushACK,
328 pp::proxy::HostResource /* video_decoder */,
329 int32_t /* pp_error */)
330 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBVideoDecoder_ResetACK,
331 pp::proxy::HostResource /* video_decoder */,
332 int32_t /* pp_error */)
333
334 // PPP_VideoDecoder_Dev.
335 IPC_MESSAGE_ROUTED3(PpapiMsg_PPPVideoDecoder_ProvidePictureBuffers,
336 pp::proxy::HostResource /* video_decoder */,
337 uint32_t /* requested number of buffers */,
338 PP_Size /* dimensions of buffer */)
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 s/buffer/buffers/
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
339 IPC_MESSAGE_ROUTED2(PpapiMsg_PPPVideoDecoder_DismissPictureBuffer,
340 pp::proxy::HostResource /* video_decoder */,
341 int32_t /* picture id */)
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 s/picture/picture buffer/ (here and below)
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
342 IPC_MESSAGE_ROUTED3(PpapiMsg_PPPVideoDecoder_PictureReady,
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 Any reason not to pass a PP_Picture_Dev?
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 No. Done!
343 pp::proxy::HostResource /* video_decoder */,
344 int32_t /* picture id */,
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 ditto
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 n/a w/ PP_Picture_Dev.
345 int32_t /* bitstream id */)
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 s/bitstream/bitstream buffer/
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 n/a w/ PP_Picture_Dev.
346 IPC_MESSAGE_ROUTED1(PpapiMsg_PPPVideoDecoder_NotifyEndOfStream,
347 pp::proxy::HostResource /* video_decoder */)
348 IPC_MESSAGE_ROUTED2(PpapiMsg_PPPVideoDecoder_NotifyError,
349 pp::proxy::HostResource /* video_decoder */,
350 uint32_t /* error id */)
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 PP_VideoDecodeError_Dev ?
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
351
315 // ----------------------------------------------------------------------------- 352 // -----------------------------------------------------------------------------
316 // These are from the plugin to the renderer. 353 // These are from the plugin to the renderer.
317 354
318 // Reply to PpapiMsg_CreateChannel. The handle will be NULL if the channel 355 // Reply to PpapiMsg_CreateChannel. The handle will be NULL if the channel
319 // could not be established. This could be because the IPC could not be created 356 // could not be established. This could be because the IPC could not be created
320 // for some weird reason, but more likely that the plugin failed to load or 357 // for some weird reason, but more likely that the plugin failed to load or
321 // initialize properly. 358 // initialize properly.
322 IPC_MESSAGE_CONTROL1(PpapiHostMsg_ChannelCreated, 359 IPC_MESSAGE_CONTROL1(PpapiHostMsg_ChannelCreated,
323 IPC::ChannelHandle /* handle */) 360 IPC::ChannelHandle /* handle */)
324 361
(...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after
894 PP_Bool /* is_always_opaque */, 931 PP_Bool /* is_always_opaque */,
895 pp::proxy::HostResource /* result */) 932 pp::proxy::HostResource /* result */)
896 IPC_SYNC_MESSAGE_ROUTED4_3(PpapiHostMsg_ResourceCreation_ImageData, 933 IPC_SYNC_MESSAGE_ROUTED4_3(PpapiHostMsg_ResourceCreation_ImageData,
897 PP_Instance /* instance */, 934 PP_Instance /* instance */,
898 int32 /* format */, 935 int32 /* format */,
899 PP_Size /* size */, 936 PP_Size /* size */,
900 PP_Bool /* init_to_zero */, 937 PP_Bool /* init_to_zero */,
901 pp::proxy::HostResource /* result_resource */, 938 pp::proxy::HostResource /* result_resource */,
902 std::string /* image_data_desc */, 939 std::string /* image_data_desc */,
903 pp::proxy::ImageHandle /* result */) 940 pp::proxy::ImageHandle /* result */)
941 // PPB_VideoDecoder.
942 IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBVideoDecoder_Create,
943 PP_Instance /* instance */,
944 pp::proxy::HostResource /* context */,
945 std::vector<int32_t> /* config */,
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 PP_VideoConfigElement ?
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
946 pp::proxy::HostResource /* result */)
947 IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBVideoDecoder_Decode,
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 Pass PP_VideoBitstreamBuffer_Dev instead?
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 I tried to do this, and I think it makes the plugi
Ami GONE FROM CHROMIUM 2011/08/03 20:25:53 I think it's worth trying harder not so much becau
948 pp::proxy::HostResource /* video_decoder */,
949 pp::proxy::HostResource /* bitstream buffer */,
950 int32 /* bitstream buffer id */,
951 int32 /* size of buffer */)
952 IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBVideoDecoder_AssignPictureBuffers,
953 pp::proxy::HostResource /* video_decoder */,
954 std::vector<PP_PictureBuffer_Dev> /* picture buffers */)
955 IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBVideoDecoder_ReusePictureBuffer,
956 pp::proxy::HostResource /* video_decoder */,
957 int32_t /* picture buffer id */)
958 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBVideoDecoder_Flush,
959 pp::proxy::HostResource /* video_decoder */)
960 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBVideoDecoder_Reset,
961 pp::proxy::HostResource /* video_decoder */)
962 IPC_SYNC_MESSAGE_ROUTED1_0(PpapiHostMsg_PPBVideoDecoder_Destroy,
963 pp::proxy::HostResource /* video_decoder */)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698