A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://developers.google.com/vr/reference/android/com/google/vr/sdk/base/GvrViewerParams below:

GvrViewerParams | Google VR | Google for Developers

GvrViewerParams

Stay organized with collections Save and categorize content based on your preferences.

Defines the physical parameters of a Google VR viewer.

The model assumes the following for any GVR viewer:

  1. Lenses are parallel to the screen of the inserted display.
  2. The center of each lens is at the same height from the bottom of the inserted display.
  3. Lenses are symmetrically placed with respect to the center of the inserted display's screen.
  4. The size of the area visible from the center of each lens is the same.

These parameters might be different for variations of different viewers or lenses. For simplicity, they can be stored in the NFC tag of the GVR viewer.

Nested Classes Public Constructors Public Methods Inherited Methods From class java.lang.Object boolean final Class<?>

getClass()

int

hashCode()

final void

notify()

final void

notifyAll()

String

toString()

final void

wait(long arg0, int arg1)

final void

wait(long arg0)

final void

wait()

Public Constructors public GvrViewerParams ()

Initializes GVR viewer parameters to default values for Cardboard v2.

Consider using getGvrViewerParams to access the parameters for the currently paired headset.

public GvrViewerParams (GvrViewerParams params)

Creates a copy of an existing viewer params object.

Parameters params viewer parameters to copy. Public Methods public static GvrViewerParams cardboardV1ViewerParams ()

Sets parameters to Cardboard v1.0.0

public static GvrViewerParams cardboardV2ViewerParams ()

Sets parameters to Cardboard v2.2

public static GvrViewerParams createFromNfcContents (NdefMessage tagContents)

Initializes physical parameters from the contents of a GVR NFC tag.

Parameters tagContents Contents of the GVR NFC tag. Returns public static GvrViewerParams createFromUri (Uri uri)

Initializes the physical parameters of a GVR headset from a Uri.

Parameters uri Uri to read the parameters from. public boolean equals (Object other)

Compares this instance with the specified object and indicates if they are equal.

This is not strictly an equality operator, as it may conservatively return false when the two objects to compare were built from a Protocol buffer.

Parameters other The object to compare this instance with. Returns public Distortion getDistortion ()

Returns the lens distortion model.

Returns public boolean getHasMagnet ()

Returns whether or not the GVR headset has a magnet.

Returns public float getInterLensDistance ()

Returns the inter lens distance for the viewer.

Returns public FieldOfView getLeftEyeMaxFov ()

Returns the left eye's maximum field of view visible through the lens. The actual rendered field of view will be limited by this and also by the size of the screen. When rendering, a mirrored field of view is expected to be applied to the right eye.

Returns public String getModel ()

Returns the viewer model string.

Returns public float getScreenToLensDistance ()

Returns the screen to lens distance in meters.

Returns public String getVendor ()

Returns the viewer vendor string.

Returns public float getVerticalDistanceToLensCenter ()

Returns the vertical distance to the lens center.

Returns public boolean isDefault () public static boolean isGvrUri (Uri uri)

Return true if given URI identifies a GVR viewer.

public void setHasMagnet (boolean magnet)

Sets whether this GVR headset has a magnet.

public void setInterLensDistance (float interLensDistance)

Sets the inter lens distance of the viewer.

Parameters interLensDistance The distance between the center of each lens in meters. public void setModel (String model)

Sets the viewer model string.

Parameters model The viewer model string to set. public void setScreenToLensDistance (float screenToLensDistance)

Sets the distance from the screen to the optical center of the lens.

This value impacts the scale applied when rendering.

Parameters screenToLensDistance The screen to lens distance in meters. public void setVendor (String vendor)

Sets the viewer vendor string.

Parameters vendor The vendor string to set. public void setVerticalDistanceToLensCenter (float verticalDistanceToLensCenter)

Sets the vertical distance to the lens center.

Parameters verticalDistanceToLensCenter The vertical distance from the center of the lenses to the bottom or top edge of the inserted display. Measured in meters. public String toString ()

Returns a string containing a concise, human-readable description of this object.

Returns public Uri toUri ()

Encodes the current GVR viewer parameters into a Uri.

The returned Uri can be written into the GVR NFC tag, a file, or encoded in a QR code.

Additional extra parameters can be added to the returned URL by using the Uri.buildUpon() and Uri.Builder.appendQueryParameter(key, value) methods. The parameter key name URI_KEY_PARAMS is reserved.

Returns

All rights reserved. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2024-10-09 UTC.

[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-09 UTC."],[[["`GvrViewerParams` defines the physical characteristics of a Google VR viewer, such as lens placement, inter-lens distance, and distortion."],["It assumes lenses are parallel to the screen, symmetrically placed, and at the same height from the display's bottom."],["Parameters can be initialized from default values, NFC tags, or URIs, and include methods for accessing and modifying these properties."],["It provides methods to set parameters for specific viewer models like Cardboard v1 and v2."],["Developers can utilize `GvrViewerParams` to tailor VR experiences based on the specific viewer being used."]]],["`GvrViewerParams` defines physical parameters for Google VR viewers, assuming parallel lenses, centered lens height, symmetric placement, and equal visible areas per lens. Key actions include initializing parameters with default settings or copying existing ones, and setting them for Cardboard versions. It allows creating parameters from NFC tags or URIs. Methods manage lens distortion, inter-lens distance, screen-to-lens distance, magnet presence, FOV, and viewer model/vendor information. They also allow for vertical alignment adjustments and conversion to URIs.\n"]]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4