Apply _RELATIVE relocations ahead of others.
[chromium-blink-merge.git] / content / common / gpu / devtools_gpu_agent.h
blob3b7f4019a9f6f6606f40b6781531b537c18a7f08
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CONTENT_COMMON_GPU_DEVTOOLS_GPU_AGENT_H_
6 #define CONTENT_COMMON_GPU_DEVTOOLS_GPU_AGENT_H_
8 #include "base/memory/scoped_ptr.h"
9 #include "base/threading/non_thread_safe.h"
10 #include "base/time/time.h"
11 #include "content/common/gpu/devtools_gpu_instrumentation.h"
13 using base::TimeTicks;
14 struct GpuTaskInfo;
16 namespace IPC {
17 class Message;
20 namespace content {
22 class GpuChannel;
24 class DevToolsGpuAgent : public base::NonThreadSafe {
25 public:
26 explicit DevToolsGpuAgent(GpuChannel* gpu_channel);
27 virtual ~DevToolsGpuAgent();
29 void ProcessEvent(TimeTicks timestamp,
30 GpuEventsDispatcher::EventPhase,
31 GpuChannel* channel);
33 bool StartEventsRecording(int32 route_id);
34 void StopEventsRecording();
36 private:
37 typedef std::vector<GpuTaskInfo> GpuTaskInfoList;
39 bool Send(IPC::Message* msg);
41 GpuChannel* gpu_channel_;
42 scoped_ptr<GpuTaskInfoList> tasks_;
43 TimeTicks last_flush_time_;
44 int32 route_id_;
46 DISALLOW_COPY_AND_ASSIGN(DevToolsGpuAgent);
49 } // namespace content
51 #endif // CONTENT_COMMON_GPU_DEVTOOLS_GPU_AGENT_H_