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

Side by Side Diff: content/common/gpu/gpu_messages.h

Issue 14999012: Move cc/debug/latency_info to ui/base. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/shared_memory.h" 11 #include "base/shared_memory.h"
12 #include "cc/debug/latency_info.h"
13 #include "content/common/content_export.h" 12 #include "content/common/content_export.h"
14 #include "content/common/gpu/gpu_memory_allocation.h" 13 #include "content/common/gpu/gpu_memory_allocation.h"
15 #include "content/common/gpu/gpu_memory_uma_stats.h" 14 #include "content/common/gpu/gpu_memory_uma_stats.h"
16 #include "content/common/gpu/gpu_process_launch_causes.h" 15 #include "content/common/gpu/gpu_process_launch_causes.h"
17 #include "content/common/gpu/gpu_rendering_stats.h" 16 #include "content/common/gpu/gpu_rendering_stats.h"
18 #include "content/public/common/common_param_traits.h" 17 #include "content/public/common/common_param_traits.h"
19 #include "content/public/common/gpu_memory_stats.h" 18 #include "content/public/common/gpu_memory_stats.h"
20 #include "gpu/command_buffer/common/command_buffer.h" 19 #include "gpu/command_buffer/common/command_buffer.h"
21 #include "gpu/command_buffer/common/constants.h" 20 #include "gpu/command_buffer/common/constants.h"
22 #include "gpu/config/gpu_info.h" 21 #include "gpu/config/gpu_info.h"
23 #include "gpu/ipc/gpu_command_buffer_traits.h" 22 #include "gpu/ipc/gpu_command_buffer_traits.h"
24 #include "ipc/ipc_channel_handle.h" 23 #include "ipc/ipc_channel_handle.h"
25 #include "ipc/ipc_message_macros.h" 24 #include "ipc/ipc_message_macros.h"
26 #include "media/video/video_decode_accelerator.h" 25 #include "media/video/video_decode_accelerator.h"
26 #include "ui/base/latency_info.h"
27 #include "ui/gfx/native_widget_types.h" 27 #include "ui/gfx/native_widget_types.h"
28 #include "ui/gfx/size.h" 28 #include "ui/gfx/size.h"
29 #include "ui/gl/gpu_preference.h" 29 #include "ui/gl/gpu_preference.h"
30 #include "ui/surface/transport_dib.h" 30 #include "ui/surface/transport_dib.h"
31 31
32 #if defined(OS_ANDROID) 32 #if defined(OS_ANDROID)
33 #include "content/common/android/surface_texture_peer.h" 33 #include "content/common/android/surface_texture_peer.h"
34 #endif 34 #endif
35 35
36 #define IPC_MESSAGE_START GpuMsgStart 36 #define IPC_MESSAGE_START GpuMsgStart
37 37
38 IPC_STRUCT_BEGIN(GPUCreateCommandBufferConfig) 38 IPC_STRUCT_BEGIN(GPUCreateCommandBufferConfig)
39 IPC_STRUCT_MEMBER(int32, share_group_id) 39 IPC_STRUCT_MEMBER(int32, share_group_id)
40 IPC_STRUCT_MEMBER(std::string, allowed_extensions) 40 IPC_STRUCT_MEMBER(std::string, allowed_extensions)
41 IPC_STRUCT_MEMBER(std::vector<int>, attribs) 41 IPC_STRUCT_MEMBER(std::vector<int>, attribs)
42 IPC_STRUCT_MEMBER(GURL, active_url) 42 IPC_STRUCT_MEMBER(GURL, active_url)
43 IPC_STRUCT_MEMBER(gfx::GpuPreference, gpu_preference) 43 IPC_STRUCT_MEMBER(gfx::GpuPreference, gpu_preference)
44 IPC_STRUCT_END() 44 IPC_STRUCT_END()
45 45
46 #undef IPC_MESSAGE_EXPORT 46 #undef IPC_MESSAGE_EXPORT
47 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT 47 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT
48 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params) 48 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params)
49 IPC_STRUCT_MEMBER(int32, surface_id) 49 IPC_STRUCT_MEMBER(int32, surface_id)
50 IPC_STRUCT_MEMBER(uint64, surface_handle) 50 IPC_STRUCT_MEMBER(uint64, surface_handle)
51 IPC_STRUCT_MEMBER(int32, route_id) 51 IPC_STRUCT_MEMBER(int32, route_id)
52 IPC_STRUCT_MEMBER(std::string, mailbox_name) 52 IPC_STRUCT_MEMBER(std::string, mailbox_name)
53 IPC_STRUCT_MEMBER(gfx::Size, size) 53 IPC_STRUCT_MEMBER(gfx::Size, size)
54 IPC_STRUCT_MEMBER(float, scale_factor) 54 IPC_STRUCT_MEMBER(float, scale_factor)
55 IPC_STRUCT_MEMBER(cc::LatencyInfo, latency_info) 55 IPC_STRUCT_MEMBER(ui::LatencyInfo, latency_info)
56 IPC_STRUCT_END() 56 IPC_STRUCT_END()
57 #undef IPC_MESSAGE_EXPORT 57 #undef IPC_MESSAGE_EXPORT
58 #define IPC_MESSAGE_EXPORT 58 #define IPC_MESSAGE_EXPORT
59 59
60 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params) 60 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params)
61 IPC_STRUCT_MEMBER(int32, surface_id) 61 IPC_STRUCT_MEMBER(int32, surface_id)
62 IPC_STRUCT_MEMBER(uint64, surface_handle) 62 IPC_STRUCT_MEMBER(uint64, surface_handle)
63 IPC_STRUCT_MEMBER(int32, route_id) 63 IPC_STRUCT_MEMBER(int32, route_id)
64 IPC_STRUCT_MEMBER(int, x) 64 IPC_STRUCT_MEMBER(int, x)
65 IPC_STRUCT_MEMBER(int, y) 65 IPC_STRUCT_MEMBER(int, y)
66 IPC_STRUCT_MEMBER(int, width) 66 IPC_STRUCT_MEMBER(int, width)
67 IPC_STRUCT_MEMBER(int, height) 67 IPC_STRUCT_MEMBER(int, height)
68 IPC_STRUCT_MEMBER(std::string, mailbox_name) 68 IPC_STRUCT_MEMBER(std::string, mailbox_name)
69 IPC_STRUCT_MEMBER(gfx::Size, surface_size) 69 IPC_STRUCT_MEMBER(gfx::Size, surface_size)
70 IPC_STRUCT_MEMBER(float, surface_scale_factor) 70 IPC_STRUCT_MEMBER(float, surface_scale_factor)
71 IPC_STRUCT_MEMBER(cc::LatencyInfo, latency_info) 71 IPC_STRUCT_MEMBER(ui::LatencyInfo, latency_info)
72 IPC_STRUCT_END() 72 IPC_STRUCT_END()
73 73
74 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfaceRelease_Params) 74 IPC_STRUCT_BEGIN(GpuHostMsg_AcceleratedSurfaceRelease_Params)
75 IPC_STRUCT_MEMBER(int32, surface_id) 75 IPC_STRUCT_MEMBER(int32, surface_id)
76 IPC_STRUCT_MEMBER(int32, route_id) 76 IPC_STRUCT_MEMBER(int32, route_id)
77 IPC_STRUCT_END() 77 IPC_STRUCT_END()
78 78
79 IPC_STRUCT_BEGIN(AcceleratedSurfaceMsg_BufferPresented_Params) 79 IPC_STRUCT_BEGIN(AcceleratedSurfaceMsg_BufferPresented_Params)
80 IPC_STRUCT_MEMBER(std::string, mailbox_name) 80 IPC_STRUCT_MEMBER(std::string, mailbox_name)
81 IPC_STRUCT_MEMBER(uint32, sync_point) 81 IPC_STRUCT_MEMBER(uint32, sync_point)
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 // Resize the window that is being drawn into. It's important that this 364 // Resize the window that is being drawn into. It's important that this
365 // resize be synchronized with the swapping of the front and back buffers. 365 // resize be synchronized with the swapping of the front and back buffers.
366 IPC_MESSAGE_CONTROL3(GpuHostMsg_ResizeView, 366 IPC_MESSAGE_CONTROL3(GpuHostMsg_ResizeView,
367 int32 /* surface_id */, 367 int32 /* surface_id */,
368 int32 /* route_id */, 368 int32 /* route_id */,
369 gfx::Size /* size */) 369 gfx::Size /* size */)
370 370
371 // Tells the browser that a frame with the specific latency info was drawn to 371 // Tells the browser that a frame with the specific latency info was drawn to
372 // the screen 372 // the screen
373 IPC_MESSAGE_CONTROL1(GpuHostMsg_FrameDrawn, 373 IPC_MESSAGE_CONTROL1(GpuHostMsg_FrameDrawn,
374 cc::LatencyInfo /* latency_info */) 374 ui::LatencyInfo /* latency_info */)
375 375
376 // Same as above with a rect of the part of the surface that changed. 376 // Same as above with a rect of the part of the surface that changed.
377 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfaceBuffersSwapped, 377 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfaceBuffersSwapped,
378 GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params) 378 GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params)
379 379
380 // This message notifies the browser process that the renderer 380 // This message notifies the browser process that the renderer
381 // swapped a portion of the buffers associated with the given "window", which 381 // swapped a portion of the buffers associated with the given "window", which
382 // should cause the browser to redraw the compositor's contents. 382 // should cause the browser to redraw the compositor's contents.
383 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfacePostSubBuffer, 383 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfacePostSubBuffer,
384 GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params) 384 GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params)
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
510 // Asynchronously synchronize the put and get offsets of both processes. 510 // Asynchronously synchronize the put and get offsets of both processes.
511 // Caller passes its current put offset. Current state (including get offset) 511 // Caller passes its current put offset. Current state (including get offset)
512 // is returned in shared memory. 512 // is returned in shared memory.
513 IPC_MESSAGE_ROUTED2(GpuCommandBufferMsg_AsyncFlush, 513 IPC_MESSAGE_ROUTED2(GpuCommandBufferMsg_AsyncFlush,
514 int32 /* put_offset */, 514 int32 /* put_offset */,
515 uint32 /* flush_count */) 515 uint32 /* flush_count */)
516 516
517 // Sends information about the latency of the current frame to the GPU 517 // Sends information about the latency of the current frame to the GPU
518 // process. 518 // process.
519 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_SetLatencyInfo, 519 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_SetLatencyInfo,
520 cc::LatencyInfo /* latency_info */) 520 ui::LatencyInfo /* latency_info */)
521 521
522 // Asynchronously process any commands known to the GPU process. This is only 522 // Asynchronously process any commands known to the GPU process. This is only
523 // used in the event that a channel is unscheduled and needs to be flushed 523 // used in the event that a channel is unscheduled and needs to be flushed
524 // again to process any commands issued subsequent to unscheduling. The GPU 524 // again to process any commands issued subsequent to unscheduling. The GPU
525 // process actually sends it (deferred) to itself. 525 // process actually sends it (deferred) to itself.
526 IPC_MESSAGE_ROUTED0(GpuCommandBufferMsg_Rescheduled) 526 IPC_MESSAGE_ROUTED0(GpuCommandBufferMsg_Rescheduled)
527 527
528 // Sent by the GPU process to display messages in the console. 528 // Sent by the GPU process to display messages in the console.
529 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_ConsoleMsg, 529 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_ConsoleMsg,
530 GPUCommandBufferConsoleMessage /* msg */) 530 GPUCommandBufferConsoleMessage /* msg */)
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
671 671
672 // Confirm decoder has been flushed. 672 // Confirm decoder has been flushed.
673 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_FlushDone) 673 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_FlushDone)
674 674
675 // Confirm decoder has been reset. 675 // Confirm decoder has been reset.
676 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_ResetDone) 676 IPC_MESSAGE_ROUTED0(AcceleratedVideoDecoderHostMsg_ResetDone)
677 677
678 // Video decoder has encountered an error. 678 // Video decoder has encountered an error.
679 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_ErrorNotification, 679 IPC_MESSAGE_ROUTED1(AcceleratedVideoDecoderHostMsg_ErrorNotification,
680 uint32) /* Error ID */ 680 uint32) /* Error ID */
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_command_buffer_stub.cc ('k') | content/common/gpu/image_transport_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698