OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 file, hence no include guard here, but see below | 5 // Multiply-included message file, hence no include guard here, but see below |
6 // for a much smaller-than-usual include guard section. | 6 // for a much smaller-than-usual include guard section. |
7 | 7 |
8 #include "gpu/config/gpu_info.h" | 8 #include "gpu/config/gpu_info.h" |
9 #include "gpu/ipc/common/gpu_param_traits_macros.h" | 9 #include "gpu/ipc/common/gpu_param_traits_macros.h" |
10 #include "ipc/ipc_message_macros.h" | 10 #include "ipc/ipc_message_macros.h" |
11 #include "ipc/param_traits_macros.h" | 11 #include "ipc/param_traits_macros.h" |
12 #include "media/gpu/ipc/common/media_param_traits.h" | 12 #include "media/gpu/ipc/common/media_param_traits.h" |
13 #include "media/video/jpeg_decode_accelerator.h" | 13 #include "media/video/jpeg_decode_accelerator.h" |
14 #include "media/video/video_decode_accelerator.h" | 14 #include "media/video/video_decode_accelerator.h" |
15 #include "media/video/video_encode_accelerator.h" | 15 #include "media/video/video_encode_accelerator.h" |
16 #include "ui/gfx/ipc/color/gfx_param_traits.h" | |
16 #include "ui/gfx/ipc/gfx_param_traits.h" | 17 #include "ui/gfx/ipc/gfx_param_traits.h" |
17 | 18 |
18 #define IPC_MESSAGE_START MediaMsgStart | 19 #define IPC_MESSAGE_START MediaMsgStart |
19 | 20 |
20 IPC_STRUCT_BEGIN(AcceleratedJpegDecoderMsg_Decode_Params) | 21 IPC_STRUCT_BEGIN(AcceleratedJpegDecoderMsg_Decode_Params) |
21 IPC_STRUCT_MEMBER(media::BitstreamBuffer, input_buffer) | 22 IPC_STRUCT_MEMBER(media::BitstreamBuffer, input_buffer) |
22 IPC_STRUCT_MEMBER(gfx::Size, coded_size) | 23 IPC_STRUCT_MEMBER(gfx::Size, coded_size) |
23 IPC_STRUCT_MEMBER(base::SharedMemoryHandle, output_video_frame_handle) | 24 IPC_STRUCT_MEMBER(base::SharedMemoryHandle, output_video_frame_handle) |
24 IPC_STRUCT_MEMBER(uint32_t, output_buffer_size) | 25 IPC_STRUCT_MEMBER(uint32_t, output_buffer_size) |
25 IPC_STRUCT_END() | 26 IPC_STRUCT_END() |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
100 media::VideoPixelFormat, /* Picture buffer format */ | 101 media::VideoPixelFormat, /* Picture buffer format */ |
101 uint32_t, /* Number of textures per frame */ | 102 uint32_t, /* Number of textures per frame */ |
102 gfx::Size, /* Requested size of buffer */ | 103 gfx::Size, /* Requested size of buffer */ |
103 uint32_t) /* Texture target */ | 104 uint32_t) /* Texture target */ |
104 | 105 |
105 // Decoder reports that a picture is ready and buffer does not need to be passed | 106 // Decoder reports that a picture is ready and buffer does not need to be passed |
106 // back to the decoder. | 107 // back to the decoder. |
107 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_DismissPictureBuffer, | 108 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_DismissPictureBuffer, |
108 int32_t) /* Picture buffer ID */ | 109 int32_t) /* Picture buffer ID */ |
109 | 110 |
111 typedef std::pair<bool, bool> BoolPair; | |
112 | |
110 // Decoder reports that a picture is ready. | 113 // Decoder reports that a picture is ready. |
111 IPC_MESSAGE_ROUTED5(AcceleratedVideoDecoderHostMsg_PictureReady, | 114 IPC_MESSAGE_ROUTED5(AcceleratedVideoDecoderHostMsg_PictureReady, |
112 int32_t, /* Picture buffer ID */ | 115 int32_t, /* Picture buffer ID */ |
113 int32_t, /* Bitstream buffer ID */ | 116 int32_t, /* Bitstream buffer ID */ |
114 gfx::Rect, /* Visible rectangle */ | 117 gfx::Rect, /* Visible rectangle */ |
115 bool, /* Buffer is HW overlay capable */ | 118 gfx::ColorSpace, /* color space */ |
116 bool) /* VDA updated picture size */ | 119 BoolPair) /* Buffer is HW overlay capable */ |
sandersd (OOO until July 31)
2016/09/16 21:54:13
I'm going to call out that I don't like this, even
hubbe
2016/09/21 22:04:26
Acknowledged.
| |
120 /* VDA updated picture size */ | |
117 | 121 |
118 // Confirm decoder has been flushed. | 122 // Confirm decoder has been flushed. |
119 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_FlushDone) | 123 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_FlushDone) |
120 | 124 |
121 // Confirm decoder has been reset. | 125 // Confirm decoder has been reset. |
122 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_ResetDone) | 126 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_ResetDone) |
123 | 127 |
124 // Video decoder has encountered an error. | 128 // Video decoder has encountered an error. |
125 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_ErrorNotification, | 129 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_ErrorNotification, |
126 uint32_t /* Error ID */) | 130 uint32_t /* Error ID */) |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
213 IPC_MESSAGE_ROUTED0(AcceleratedJpegDecoderMsg_Destroy) | 217 IPC_MESSAGE_ROUTED0(AcceleratedJpegDecoderMsg_Destroy) |
214 | 218 |
215 //------------------------------------------------------------------------------ | 219 //------------------------------------------------------------------------------ |
216 // Accelerated JPEG Decoder Host Messages | 220 // Accelerated JPEG Decoder Host Messages |
217 // These messages are sent from the GPU process to Browser process. | 221 // These messages are sent from the GPU process to Browser process. |
218 // | 222 // |
219 // Report decode status. | 223 // Report decode status. |
220 IPC_MESSAGE_ROUTED2(AcceleratedJpegDecoderHostMsg_DecodeAck, | 224 IPC_MESSAGE_ROUTED2(AcceleratedJpegDecoderHostMsg_DecodeAck, |
221 int32_t, /* bitstream_buffer_id */ | 225 int32_t, /* bitstream_buffer_id */ |
222 media::JpegDecodeAccelerator::Error /* error */) | 226 media::JpegDecodeAccelerator::Error /* error */) |
OLD | NEW |