{"action":"created","comment":{"url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/comments/53819726","id":53819726,"diff_hunk":"@@ -0,0 +1,512 @@\n+<pre class=\"metadata\">\n+Title: WebVR\n+Status: ED\n+ED: https://github.com/mozvr/webvr-spec/\n+Shortname: webvr\n+Level: 1\n+Editor: Vladimir Vukicevic, Mozilla https://mozilla.org/, vladimir@mozilla.com\n+Editor: Brandon Jones, Google http://google.com/, bajones@google.com\n+Editor: Kearwood Gilbert, Mozilla https://mozilla.org/, kgilbert@mozilla.com\n+Editor: Chris Van Wiemeersch, Mozilla https://mozilla.org/, cvan@mozilla.com\n+Abstract: This specification describes support for accessing virtual reality devices, including sensors and head-mounted displays on the Web.\n+Repository: mozvr/webvr-spec\n+Mailing List: web-vr-discuss@mozilla.org\n+Mailing List Archives: https://mail.mozilla.org/pipermail/web-vr-discuss/\n+</pre>\n+\n+<pre class=\"anchors\">\n+urlPrefix: http://www.w3.org/TR/hr-time/\n+    type: typedef; text: DOMHighResTimeStamp\n+    type: dfn; text: timestamp origin\n+urlPrefix: https://wiki.whatwg.org/wiki/OffscreenCanvas\n+    type: typedef; text: OffscreenCanvas\n+    type: dfn; text: offscreen canvas\n+urlPrefix: https://www.w3.org/TR/gamepad/\n+    type: interface; text: Gamepad\n+</pre>\n+\n+# Introduction # {#intro}\n+\n+Hardware that enables Virtual Reality applications requires high-precision, low-latency interfaces to deliver an acceptable experience.\n+Other interfaces, such as device orientation events, can be repurposed to surface VR input but doing so dilutes the interface's original\n+intent and often does not provide the precision necessary for high-quality VR. The WebVR API provides purpose-built interfaces\n+to VR hardware to allow developers to build compelling, comfortable VR experiences.\n+\n+\n+# DOM Interfaces # {#dom}\n+\n+This section describes the interfaces and functionality added to the DOM to support runtime access to the functionality described above.\n+\n+## VRDisplay ## {#vrdisplay}\n+\n+The {{VRDisplay}} interface forms the base of all VR devices supported by this API. It includes generic information such as device IDs and descriptions.\n+\n+<pre class=\"idl\">\n+interface VRDisplay : EventTarget {\n+  readonly attribute boolean isConnected;\n+  readonly attribute boolean isPresenting;\n+\n+  /**\n+   * Dictionary of capabilities describing the VRDisplay.\n+   */\n+  [Constant] readonly attribute VRDisplayCapabilities capabilities;\n+\n+  /**\n+   * If this VRDisplay supports room-scale experiences, the optional\n+   * stage attribute contains details on the room-scale parameters.\n+   */\n+  readonly attribute VRStageParameters? stageParameters;\n+\n+  /* Return the current VREyeParameters for the given eye. */\n+  VREyeParameters getEyeParameters(VREye whichEye);\n+\n+  /**\n+   * An identifier for this distinct VRDisplay. Used as an\n+   * association point in the Gamepad API.\n+   */\n+  [Constant] readonly attribute unsigned long displayId;\n+\n+  /**\n+   * A display name, a user-readable name identifying it.\n+   */\n+  [Constant] readonly attribute DOMString displayName;\n+\n+  /**\n+   * Return a VRPose containing the future predicted pose of the VRDisplay when the\n+   * current frame will be presented. The value returned will not change until javascript\n+   * has returned control to the browser.\n+   *\n+   * The VRPose will contain the position, orientation, velocity,\n+   * and acceleration of each of these properties.\n+   */\n+  [NewObject] VRPose getPose();\n+\n+  /**\n+   * Return the current instantaneous pose of the VRDisplay, with no\n+   * prediction applied.\n+   */\n+  [NewObject] VRPose getImmediatePose();\n+\n+  /**\n+   * Reset this sensor, treating its current position and orientation\n+   * as the \"origin/zero\" values. VRPose.position,\n+   * VRPose.orientation, and VRStageParameters.sittingToStandingTransform\n+   * may be updated when calling resetPose(). This should only\n+   * be called in a sitting space experience.\n+   */\n+  void resetPose();\n+\n+  /**\n+   * z-depth defining the near plane of the eye view frustum\n+   * enables mapping of values in the render target depth\n+   * attachment to scene coordinates. Initially set to 0.01.\n+   */\n+  attribute double depthNear;\n+  /**\n+   * z-depth defining the far plane of the eye view frustum\n+   * enables mapping of values in the render target depth\n+   * attachment to scene coordinates. Initially set to 10000.0.\n+   */\n+  attribute double depthFar;\n+\n+  /**\n+   * The callback passed to `requestAnimationFrame` will be called\n+   * any time a new frame should be rendered. When the VRDisplay is\n+   * presenting the callback will be called at the native refresh\n+   * rate of the HMD. When not presenting this function acts\n+   * identically to window.requestAnimationFrame. Content should make no\n+   * assumptions of frame rate or vsync behavior as the HMD runs\n+   * asynchronously from other displays and at differing refresh rates.\n+   */\n+  [Throws] long requestAnimationFrame(FrameRequestCallback callback);\n+\n+  /**\n+   * Passing the value returned by `requestAnimationFrame` to\n+   * `cancelAnimationFrame` will unregister the callback.\n+   */\n+  [Throws] void cancelAnimationFrame(long handle);\n+\n+  /**\n+   * Begin presenting to the VRDisplay. Must be called in response to a user gesture.\n+   * Repeat calls while already presenting will update the VRLayer being displayed.\n+   */\n+  Promise&lt;void&gt; requestPresent();","path":"index.bs","position":133,"original_position":133,"commit_id":"cfd9c4c3a70f9ab6b6efb4b9d083b830e9e9801d","original_commit_id":"cfd9c4c3a70f9ab6b6efb4b9d083b830e9e9801d","user":{"login":"toji","id":805273,"avatar_url":"https://avatars.githubusercontent.com/u/805273?v=3","gravatar_id":"","url":"https://api.github.com/users/toji","html_url":"https://github.com/toji","followers_url":"https://api.github.com/users/toji/followers","following_url":"https://api.github.com/users/toji/following{/other_user}","gists_url":"https://api.github.com/users/toji/gists{/gist_id}","starred_url":"https://api.github.com/users/toji/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/toji/subscriptions","organizations_url":"https://api.github.com/users/toji/orgs","repos_url":"https://api.github.com/users/toji/repos","events_url":"https://api.github.com/users/toji/events{/privacy}","received_events_url":"https://api.github.com/users/toji/received_events","type":"User","site_admin":false},"body":"requestPresent Needs to accept a VRLayer","created_at":"2016-02-23T17:53:20Z","updated_at":"2016-02-23T17:53:20Z","html_url":"https://github.com/MozVR/webvr-spec/pull/12#discussion_r53819726","pull_request_url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/comments/53819726"},"html":{"href":"https://github.com/MozVR/webvr-spec/pull/12#discussion_r53819726"},"pull_request":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12","id":60304310,"html_url":"https://github.com/MozVR/webvr-spec/pull/12","diff_url":"https://github.com/MozVR/webvr-spec/pull/12.diff","patch_url":"https://github.com/MozVR/webvr-spec/pull/12.patch","issue_url":"https://api.github.com/repos/MozVR/webvr-spec/issues/12","number":12,"state":"open","locked":false,"title":"initial spec rewrite (v1.0)","user":{"login":"cvan","id":203725,"avatar_url":"https://avatars.githubusercontent.com/u/203725?v=3","gravatar_id":"","url":"https://api.github.com/users/cvan","html_url":"https://github.com/cvan","followers_url":"https://api.github.com/users/cvan/followers","following_url":"https://api.github.com/users/cvan/following{/other_user}","gists_url":"https://api.github.com/users/cvan/gists{/gist_id}","starred_url":"https://api.github.com/users/cvan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cvan/subscriptions","organizations_url":"https://api.github.com/users/cvan/orgs","repos_url":"https://api.github.com/users/cvan/repos","events_url":"https://api.github.com/users/cvan/events{/privacy}","received_events_url":"https://api.github.com/users/cvan/received_events","type":"User","site_admin":false},"body":"r? @toji @kearwood \r\n\r\nHere's the initial draft. There are omissions and issues. I'll continue work on this, but don't hesitate to say something when you see something.","created_at":"2016-02-23T08:32:42Z","updated_at":"2016-02-23T17:53:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b090db1119814d784456138093aebbf7c374b132","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12/commits","review_comments_url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12/comments","review_comment_url":"https://api.github.com/repos/MozVR/webvr-spec/pulls/comments{/number}","comments_url":"https://api.github.com/repos/MozVR/webvr-spec/issues/12/comments","statuses_url":"https://api.github.com/repos/MozVR/webvr-spec/statuses/cfd9c4c3a70f9ab6b6efb4b9d083b830e9e9801d","head":{"label":"cvan:v1.0-update","ref":"v1.0-update","sha":"cfd9c4c3a70f9ab6b6efb4b9d083b830e9e9801d","user":{"login":"cvan","id":203725,"avatar_url":"https://avatars.githubusercontent.com/u/203725?v=3","gravatar_id":"","url":"https://api.github.com/users/cvan","html_url":"https://github.com/cvan","followers_url":"https://api.github.com/users/cvan/followers","following_url":"https://api.github.com/users/cvan/following{/other_user}","gists_url":"https://api.github.com/users/cvan/gists{/gist_id}","starred_url":"https://api.github.com/users/cvan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cvan/subscriptions","organizations_url":"https://api.github.com/users/cvan/orgs","repos_url":"https://api.github.com/users/cvan/repos","events_url":"https://api.github.com/users/cvan/events{/privacy}","received_events_url":"https://api.github.com/users/cvan/received_events","type":"User","site_admin":false},"repo":{"id":35596830,"name":"webvr-spec","full_name":"cvan/webvr-spec","owner":{"login":"cvan","id":203725,"avatar_url":"https://avatars.githubusercontent.com/u/203725?v=3","gravatar_id":"","url":"https://api.github.com/users/cvan","html_url":"https://github.com/cvan","followers_url":"https://api.github.com/users/cvan/followers","following_url":"https://api.github.com/users/cvan/following{/other_user}","gists_url":"https://api.github.com/users/cvan/gists{/gist_id}","starred_url":"https://api.github.com/users/cvan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cvan/subscriptions","organizations_url":"https://api.github.com/users/cvan/orgs","repos_url":"https://api.github.com/users/cvan/repos","events_url":"https://api.github.com/users/cvan/events{/privacy}","received_events_url":"https://api.github.com/users/cvan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/cvan/webvr-spec","description":"WebVR Specification","fork":true,"url":"https://api.github.com/repos/cvan/webvr-spec","forks_url":"https://api.github.com/repos/cvan/webvr-spec/forks","keys_url":"https://api.github.com/repos/cvan/webvr-spec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cvan/webvr-spec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cvan/webvr-spec/teams","hooks_url":"https://api.github.com/repos/cvan/webvr-spec/hooks","issue_events_url":"https://api.github.com/repos/cvan/webvr-spec/issues/events{/number}","events_url":"https://api.github.com/repos/cvan/webvr-spec/events","assignees_url":"https://api.github.com/repos/cvan/webvr-spec/assignees{/user}","branches_url":"https://api.github.com/repos/cvan/webvr-spec/branches{/branch}","tags_url":"https://api.github.com/repos/cvan/webvr-spec/tags","blobs_url":"https://api.github.com/repos/cvan/webvr-spec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cvan/webvr-spec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cvan/webvr-spec/git/refs{/sha}","trees_url":"https://api.github.com/repos/cvan/webvr-spec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cvan/webvr-spec/statuses/{sha}","languages_url":"https://api.github.com/repos/cvan/webvr-spec/languages","stargazers_url":"https://api.github.com/repos/cvan/webvr-spec/stargazers","contributors_url":"https://api.github.com/repos/cvan/webvr-spec/contributors","subscribers_url":"https://api.github.com/repos/cvan/webvr-spec/subscribers","subscription_url":"https://api.github.com/repos/cvan/webvr-spec/subscription","commits_url":"https://api.github.com/repos/cvan/webvr-spec/commits{/sha}","git_commits_url":"https://api.github.com/repos/cvan/webvr-spec/git/commits{/sha}","comments_url":"https://api.github.com/repos/cvan/webvr-spec/comments{/number}","issue_comment_url":"https://api.github.com/repos/cvan/webvr-spec/issues/comments{/number}","contents_url":"https://api.github.com/repos/cvan/webvr-spec/contents/{+path}","compare_url":"https://api.github.com/repos/cvan/webvr-spec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cvan/webvr-spec/merges","archive_url":"https://api.github.com/repos/cvan/webvr-spec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cvan/webvr-spec/downloads","issues_url":"https://api.github.com/repos/cvan/webvr-spec/issues{/number}","pulls_url":"https://api.github.com/repos/cvan/webvr-spec/pulls{/number}","milestones_url":"https://api.github.com/repos/cvan/webvr-spec/milestones{/number}","notifications_url":"https://api.github.com/repos/cvan/webvr-spec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cvan/webvr-spec/labels{/name}","releases_url":"https://api.github.com/repos/cvan/webvr-spec/releases{/id}","deployments_url":"https://api.github.com/repos/cvan/webvr-spec/deployments","created_at":"2015-05-14T07:08:50Z","updated_at":"2015-05-14T07:08:51Z","pushed_at":"2016-02-23T08:28:23Z","git_url":"git://github.com/cvan/webvr-spec.git","ssh_url":"git@github.com:cvan/webvr-spec.git","clone_url":"https://github.com/cvan/webvr-spec.git","svn_url":"https://github.com/cvan/webvr-spec","homepage":null,"size":152,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"MozVR:master","ref":"master","sha":"8b87f0e9028f04e82383e167f551991257f2ce6a","user":{"login":"MozVR","id":8397321,"avatar_url":"https://avatars.githubusercontent.com/u/8397321?v=3","gravatar_id":"","url":"https://api.github.com/users/MozVR","html_url":"https://github.com/MozVR","followers_url":"https://api.github.com/users/MozVR/followers","following_url":"https://api.github.com/users/MozVR/following{/other_user}","gists_url":"https://api.github.com/users/MozVR/gists{/gist_id}","starred_url":"https://api.github.com/users/MozVR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MozVR/subscriptions","organizations_url":"https://api.github.com/users/MozVR/orgs","repos_url":"https://api.github.com/users/MozVR/repos","events_url":"https://api.github.com/users/MozVR/events{/privacy}","received_events_url":"https://api.github.com/users/MozVR/received_events","type":"Organization","site_admin":false},"repo":{"id":29875036,"name":"webvr-spec","full_name":"MozVR/webvr-spec","owner":{"login":"MozVR","id":8397321,"avatar_url":"https://avatars.githubusercontent.com/u/8397321?v=3","gravatar_id":"","url":"https://api.github.com/users/MozVR","html_url":"https://github.com/MozVR","followers_url":"https://api.github.com/users/MozVR/followers","following_url":"https://api.github.com/users/MozVR/following{/other_user}","gists_url":"https://api.github.com/users/MozVR/gists{/gist_id}","starred_url":"https://api.github.com/users/MozVR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MozVR/subscriptions","organizations_url":"https://api.github.com/users/MozVR/orgs","repos_url":"https://api.github.com/users/MozVR/repos","events_url":"https://api.github.com/users/MozVR/events{/privacy}","received_events_url":"https://api.github.com/users/MozVR/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MozVR/webvr-spec","description":"WebVR Specification","fork":false,"url":"https://api.github.com/repos/MozVR/webvr-spec","forks_url":"https://api.github.com/repos/MozVR/webvr-spec/forks","keys_url":"https://api.github.com/repos/MozVR/webvr-spec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MozVR/webvr-spec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MozVR/webvr-spec/teams","hooks_url":"https://api.github.com/repos/MozVR/webvr-spec/hooks","issue_events_url":"https://api.github.com/repos/MozVR/webvr-spec/issues/events{/number}","events_url":"https://api.github.com/repos/MozVR/webvr-spec/events","assignees_url":"https://api.github.com/repos/MozVR/webvr-spec/assignees{/user}","branches_url":"https://api.github.com/repos/MozVR/webvr-spec/branches{/branch}","tags_url":"https://api.github.com/repos/MozVR/webvr-spec/tags","blobs_url":"https://api.github.com/repos/MozVR/webvr-spec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MozVR/webvr-spec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MozVR/webvr-spec/git/refs{/sha}","trees_url":"https://api.github.com/repos/MozVR/webvr-spec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MozVR/webvr-spec/statuses/{sha}","languages_url":"https://api.github.com/repos/MozVR/webvr-spec/languages","stargazers_url":"https://api.github.com/repos/MozVR/webvr-spec/stargazers","contributors_url":"https://api.github.com/repos/MozVR/webvr-spec/contributors","subscribers_url":"https://api.github.com/repos/MozVR/webvr-spec/subscribers","subscription_url":"https://api.github.com/repos/MozVR/webvr-spec/subscription","commits_url":"https://api.github.com/repos/MozVR/webvr-spec/commits{/sha}","git_commits_url":"https://api.github.com/repos/MozVR/webvr-spec/git/commits{/sha}","comments_url":"https://api.github.com/repos/MozVR/webvr-spec/comments{/number}","issue_comment_url":"https://api.github.com/repos/MozVR/webvr-spec/issues/comments{/number}","contents_url":"https://api.github.com/repos/MozVR/webvr-spec/contents/{+path}","compare_url":"https://api.github.com/repos/MozVR/webvr-spec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MozVR/webvr-spec/merges","archive_url":"https://api.github.com/repos/MozVR/webvr-spec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MozVR/webvr-spec/downloads","issues_url":"https://api.github.com/repos/MozVR/webvr-spec/issues{/number}","pulls_url":"https://api.github.com/repos/MozVR/webvr-spec/pulls{/number}","milestones_url":"https://api.github.com/repos/MozVR/webvr-spec/milestones{/number}","notifications_url":"https://api.github.com/repos/MozVR/webvr-spec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MozVR/webvr-spec/labels{/name}","releases_url":"https://api.github.com/repos/MozVR/webvr-spec/releases{/id}","deployments_url":"https://api.github.com/repos/MozVR/webvr-spec/deployments","created_at":"2015-01-26T18:26:13Z","updated_at":"2016-02-23T00:14:10Z","pushed_at":"2016-02-23T17:50:43Z","git_url":"git://github.com/MozVR/webvr-spec.git","ssh_url":"git@github.com:MozVR/webvr-spec.git","clone_url":"https://github.com/MozVR/webvr-spec.git","svn_url":"https://github.com/MozVR/webvr-spec","homepage":"https://mozvr.github.io/webvr-spec/webvr.html","size":165,"stargazers_count":104,"watchers_count":104,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":18,"mirror_url":null,"open_issues_count":5,"forks":18,"open_issues":5,"watchers":104,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12"},"html":{"href":"https://github.com/MozVR/webvr-spec/pull/12"},"issue":{"href":"https://api.github.com/repos/MozVR/webvr-spec/issues/12"},"comments":{"href":"https://api.github.com/repos/MozVR/webvr-spec/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/MozVR/webvr-spec/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/MozVR/webvr-spec/statuses/cfd9c4c3a70f9ab6b6efb4b9d083b830e9e9801d"}}}}