Skip to content

Commit

Permalink
Clarified when exclusive sessions are rejected
Browse files Browse the repository at this point in the history
  • Loading branch information
toji committed Feb 12, 2019
1 parent f20c7ec commit c01dfef
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion explainer.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ In this sample, the `beginXRSession` function, which is assumed to be run by cli

If `supportsSessionMode` resolved for a given mode, then requesting a session with the same mode should be reasonably expected to succeed, barring external factors (such as `requestSession` not being called in a user activation event for an immersive session.) The UA is ultimately responsible for determining if it can honor the request.

Only one immersive session per XR hardware device is allowed at a time across the entire UA. All inline sessions are [suspended](#handling-suspended-sessions) when an immersive session is active. Inline sessions are not required to be created within a user activation event unless paired with another option that explicitly does require it.
Only one immersive session per XR hardware device is allowed at a time across the entire UA. If an immersive session is requested and the UA already has an active immersive session or a pending request for an immersive session, then the new request must be rejected. All inline sessions are [suspended](#handling-suspended-sessions) when an immersive session is active. Inline sessions are not required to be created within a user activation event unless paired with another option that explicitly does require it.

Once the session has started, some setup must be done to prepare for rendering.
- An `XRReferenceSpace` should be created to establish a space in which `XRViewerPose` data will be defined. See the [Spatial Tracking Explainer](spatial-tracking-explainer.md) for more information.
Expand Down
8 changes: 6 additions & 2 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -360,10 +360,14 @@ When an {{XRSession}} is shut down the following steps are run:

<div class="algorithm" data-algorithm="end-session">

The <dfn method for="XRSession">end()</dfn> method provides a way to manually shut down a session. When invoked, it MUST return [=a new Promise=] |promise| and run the following steps [=in parallel=]:
The <dfn method for="XRSession">end()</dfn> method provides a way to manually shut down a session. When invoked, it MUST run the following steps:

1. Let |promise| be [=a new Promise=].
1. [=Shut down the session|Shut down=] the target {{XRSession}} object.
1. [=/Resolve=] |promise|.
1. [=Queue a task=] to perform the following steps:
1. Wait until any platform-specific steps related to shutting down the session have completed.
1. [=/Resolve=] |promise|.
1. Return |promise|.

</div>

Expand Down

0 comments on commit c01dfef

Please sign in to comment.