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

Side by Side Diff: device/vr/vr_service.mojom

Issue 2384593002: Encode frame number in pixel data for pose sync (Closed)
Patch Set: bajones #10: restoreStateFromContext, skip pixel read for non-async mode Created 4 years, 2 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 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 device; 5 module device;
6 6
7 // A field of view, given by 4 degrees describing the view from a center point. 7 // A field of view, given by 4 degrees describing the view from a center point.
8 struct VRFieldOfView { 8 struct VRFieldOfView {
9 float upDegrees; 9 float upDegrees;
10 float downDegrees; 10 float downDegrees;
11 float leftDegrees; 11 float leftDegrees;
12 float rightDegrees; 12 float rightDegrees;
13 }; 13 };
14 14
15 // A display's position, orientation, velocity, and acceleration state at the 15 // A display's position, orientation, velocity, and acceleration state at the
16 // given timestamp. 16 // given timestamp. The poseNum is a sequential ID that's incremented on
mthiesse 2016/10/04 21:19:17 Again, I think frameIndex is less confusing. The f
klausw 2016/10/04 23:08:14 Renamed to poseIndex.
17 // each distinct getPose result, it may wrap around for long sessions.
17 struct VRPose { 18 struct VRPose {
18 double timestamp; 19 double timestamp;
19 array<float, 4>? orientation; 20 array<float, 4>? orientation;
20 array<float, 3>? position; 21 array<float, 3>? position;
21 array<float, 3>? angularVelocity; 22 array<float, 3>? angularVelocity;
22 array<float, 3>? linearVelocity; 23 array<float, 3>? linearVelocity;
23 array<float, 3>? angularAcceleration; 24 array<float, 3>? angularAcceleration;
24 array<float, 3>? linearAcceleration; 25 array<float, 3>? linearAcceleration;
26 uint32 poseNum;
dcheng 2016/10/04 23:17:53 Nit: can we move the newly added comment here, so
klausw 2016/10/04 23:56:42 Done.
25 }; 27 };
26 28
27 struct VRDisplayCapabilities { 29 struct VRDisplayCapabilities {
28 bool hasOrientation; 30 bool hasOrientation;
29 bool hasPosition; 31 bool hasPosition;
30 bool hasExternalDisplay; 32 bool hasExternalDisplay;
31 bool canPresent; 33 bool canPresent;
32 }; 34 };
33 35
34 // Information about the optical properties for an eye in a VRDisplay. 36 // Information about the optical properties for an eye in a VRDisplay.
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 SubmitFrame(uint32 index, VRPose? pose); 76 SubmitFrame(uint32 index, VRPose? pose);
75 UpdateLayerBounds(uint32 index, VRLayerBounds leftBounds, VRLayerBounds rightB ounds); 77 UpdateLayerBounds(uint32 index, VRLayerBounds leftBounds, VRLayerBounds rightB ounds);
76 }; 78 };
77 79
78 interface VRServiceClient { 80 interface VRServiceClient {
79 OnDisplayChanged(VRDisplay display); 81 OnDisplayChanged(VRDisplay display);
80 OnExitPresent(uint32 index); 82 OnExitPresent(uint32 index);
81 OnDisplayConnected(VRDisplay display); 83 OnDisplayConnected(VRDisplay display);
82 OnDisplayDisconnected(uint32 index); 84 OnDisplayDisconnected(uint32 index);
83 }; 85 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698