pub trait XRSessionMethods<D: DomTypes> {
Show 36 methods
// Required methods
fn VisibilityState(&self) -> XRVisibilityState;
fn GetFrameRate(&self) -> Option<Finite<f32>>;
fn GetSupportedFrameRates(&self, cx: SafeJSContext) -> Option<Float32Array>;
fn RenderState(&self) -> Root<Dom<XRRenderState>>;
fn InputSources(&self) -> Root<Dom<XRInputSourceArray>>;
fn EnabledFeatures(&self, cx: SafeJSContext, retval: MutableHandleValue<'_>);
fn IsSystemKeyboardSupported(&self) -> bool;
fn UpdateRenderState(
&self,
state: &XRRenderStateInit,
_comp: InRealm<'_>,
) -> Result<(), Error>;
fn UpdateTargetFrameRate(
&self,
rate: Finite<f32>,
_comp: InRealm<'_>,
_can_gc: CanGc,
) -> Rc<Promise>;
fn RequestReferenceSpace(
&self,
type_: XRReferenceSpaceType,
_comp: InRealm<'_>,
_can_gc: CanGc,
) -> Rc<Promise>;
fn RequestAnimationFrame(&self, callback: Rc<XRFrameRequestCallback>) -> i32;
fn CancelAnimationFrame(&self, handle: i32);
fn End(&self, _can_gc: CanGc) -> Rc<Promise>;
fn GetOnend(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnend(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnselect(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnselect(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnsqueeze(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnsqueeze(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOninputsourceschange(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOninputsourceschange(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnselectstart(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnselectstart(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnselectend(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnselectend(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnsqueezestart(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnsqueezestart(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnsqueezeend(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnsqueezeend(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnvisibilitychange(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnvisibilitychange(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnframeratechange(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnframeratechange(&self, value: Option<Rc<EventHandlerNonNull>>);
fn EnvironmentBlendMode(&self) -> XREnvironmentBlendMode;
fn InteractionMode(&self) -> XRInteractionMode;
fn RequestHitTestSource(
&self,
options: &XRHitTestOptionsInit,
_can_gc: CanGc,
) -> Rc<Promise>;
}