OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 module media.mojom; | 5 module media.mojom; |
6 | 6 |
7 import "media/mojo/interfaces/demuxer_stream.mojom"; | 7 import "media/mojo/interfaces/demuxer_stream.mojom"; |
8 import "media/mojo/interfaces/media_types.mojom"; | 8 import "media/mojo/interfaces/media_types.mojom"; |
9 import "mojo/common/common_custom_types.mojom"; | 9 import "mojo/common/common_custom_types.mojom"; |
10 import "ui/gfx/geometry/mojo/geometry.mojom"; | 10 import "ui/gfx/geometry/mojo/geometry.mojom"; |
(...skipping 25 matching lines...) Expand all Loading... |
36 // executing the callback with whether the CDM was successfully attached. | 36 // executing the callback with whether the CDM was successfully attached. |
37 SetCdm(int32 cdm_id) => (bool success); | 37 SetCdm(int32 cdm_id) => (bool success); |
38 }; | 38 }; |
39 | 39 |
40 interface RendererClient { | 40 interface RendererClient { |
41 // Called to report media time advancement by |time|. | 41 // Called to report media time advancement by |time|. |
42 // |time| and |max_time| can be used to interpolate time between | 42 // |time| and |max_time| can be used to interpolate time between |
43 // calls to OnTimeUpdate(). | 43 // calls to OnTimeUpdate(). |
44 // |max_time| is typically the media timestamp of the last audio frame | 44 // |max_time| is typically the media timestamp of the last audio frame |
45 // buffered by the audio hardware. | 45 // buffered by the audio hardware. |
| 46 // |capture_time| is monotonic clock time at which the times were captured. |
46 // |max_time| must be greater or equal to |time|. | 47 // |max_time| must be greater or equal to |time|. |
47 OnTimeUpdate(mojo.common.mojom.TimeDelta time, | 48 OnTimeUpdate(mojo.common.mojom.TimeDelta time, |
48 mojo.common.mojom.TimeDelta max_time); | 49 mojo.common.mojom.TimeDelta max_time, |
| 50 mojo.common.mojom.TimeTicks capture_time); |
49 | 51 |
50 // Called to report buffering state changes, see media_types.mojom. | 52 // Called to report buffering state changes, see media_types.mojom. |
51 OnBufferingStateChange(BufferingState state); | 53 OnBufferingStateChange(BufferingState state); |
52 | 54 |
53 // Executed when rendering has reached the end of stream. | 55 // Executed when rendering has reached the end of stream. |
54 OnEnded(); | 56 OnEnded(); |
55 | 57 |
56 // Executed if any error was encountered during decode or rendering. If | 58 // Executed if any error was encountered during decode or rendering. If |
57 // this error happens during an operation that has a completion callback, | 59 // this error happens during an operation that has a completion callback, |
58 // OnError() will be called before firing the completion callback. | 60 // OnError() will be called before firing the completion callback. |
(...skipping 10 matching lines...) Expand all Loading... |
69 OnStatisticsUpdate(PipelineStatistics stats); | 71 OnStatisticsUpdate(PipelineStatistics stats); |
70 | 72 |
71 // Called when the remote renderering service is waiting on the decryption | 73 // Called when the remote renderering service is waiting on the decryption |
72 // key. | 74 // key. |
73 OnWaitingForDecryptionKey(); | 75 OnWaitingForDecryptionKey(); |
74 | 76 |
75 // Executed the first time the metadata is updated, and whenever the duration | 77 // Executed the first time the metadata is updated, and whenever the duration |
76 // changes. | 78 // changes. |
77 OnDurationChange(mojo.common.mojom.TimeDelta duration); | 79 OnDurationChange(mojo.common.mojom.TimeDelta duration); |
78 }; | 80 }; |
OLD | NEW |