Roll WebRTC 9217:9227, Libjingle 9216:9227
[chromium-blink-merge.git] / cc / debug / frame_timing_request.h
blob09379980fa072527136274e3d88539e77cd670db
1 // Copyright 2015 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 CC_DEBUG_FRAME_TIMING_REQUEST_H_
6 #define CC_DEBUG_FRAME_TIMING_REQUEST_H_
8 #include "cc/base/cc_export.h"
9 #include "ui/gfx/geometry/rect.h"
11 namespace cc {
13 // This class represents a request to record frame timing information about the
14 // given rect (in layer space) and an associated request id. When this request
15 // is propagated to the active LayerImpl, it will cause events to be saved in
16 // FrameTimingTracker, which in turn can be consumed by the requester.
17 class CC_EXPORT FrameTimingRequest {
18 public:
19 FrameTimingRequest();
20 FrameTimingRequest(int64_t request_id, const gfx::Rect& rect);
22 // Return the ID for the request.
23 int64_t id() const { return id_; }
25 // Return the layer space rect for this request.
26 const gfx::Rect& rect() const { return rect_; }
28 private:
29 int64_t id_;
30 gfx::Rect rect_;
33 } // namespace cc
35 #endif // CC_DEBUG_FRAME_TIMING_REQUEST_H_