1 /* Copyright 2014 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.
7 * This file defines the PPB_InputEvent_Private interfaces.
15 * The <code>PPB_InputEvent_Private</code> interface contains pointers to several
16 * functions related to generic input events on the browser.
19 interface PPB_InputEvent_Private
{
21 * TraceInputLatency() traces the latency of the input event. The input
22 * latency is shown in the trace viewer. The starting point of the input
23 * latency is when the input event is sent from renderer to plugin. If the
24 * input event does not cause any rendering damage, the end point of input
25 * latency is when TraceInputLatency() is called on the event. If the input
26 * event does cause rendering damage, the end point of input latency is when
27 * the resulted plugin frame eventually reaches screen.
29 * Notes: In the current version, only Graphics2D damage is considered as
30 * rendering damage. And it works only when the Graphics2Ds are bound to
31 * the plugin instance.
33 * @param[in] event A <code>PP_Resource</code> corresponding to an input
36 * @param[in] has_damage A bool indicating whether the event has caused any
39 * @return <code>PP_TRUE</code> if the latency for the given event is tracked.
41 PP_Bool TraceInputLatency
([in] PP_Resource event
,
42 [in] PP_Bool has_damage
);
45 * StartTrackingLatency() requests input latency to be tracked.
47 * Without calling StartTrackingLatency() first, TraceInputLatency() won't
50 * @param[in] instance The <code>PP_Instance</code> of the instance requesting
51 * to start tracking input latency.
53 void StartTrackingLatency
([in] PP_Instance instance
);