javirs
javirs

Reputation: 1100

google cardboard adapt for other screens

Im using google cardboard for unity SDK, it allows you to use different phones but I'm using the galaxy S2 that is not in the list.

The definitions in the code look like this:

 /// Parameters for a Nexus 6 device.
  public static readonly Screen Nexus6 = new Screen {
    width = 0.133f,
    height = 0.074f,
    border = 0.004f
  };

  /// Parameters for a Galaxy S6 device.
  public static readonly Screen GalaxyS6 = new Screen {
    width = 0.114f,
    height = 0.0635f,
    border = 0.0035f
  };

Does anyone knows what are those parameters and in witch units ?

Upvotes: 1

Views: 213

Answers (3)

javirs
javirs

Reputation: 1100

As stated before you cannot configure the glasses from the game itself, you need to create your own profile QR using this site:

enter link description here

Then you can load it into google cardboard settings application as if your glasses where official ones.

Upvotes: 0

smd
smd

Reputation: 839

That particular list is only used when playing the scene in the Unity editor. It is a simulator, essentially. When running on the phone, the values are collected from the phone itself.

Upvotes: 1

javirs
javirs

Reputation: 1100

/// Information about the screen.  All distances are in meters, measured as the phone is expected
  /// to be placed in the Cardboard, i.e. landscape orientation.
  [System.Serializable]
  public struct Screen {
    public float width;   // The long edge of the phone.
    public float height;  // The short edge of the phone.
    public float border;  // Distance from bottom of the cardboard to the bottom edge of screen.
  }

That's the answer : )

Upvotes: 1

Related Questions