public virtual void Awake() { s3dDeviceMan = (s3dDeviceManager)gameObject.GetComponent(typeof(s3dDeviceManager)); // if object has s3dDeviceManager.js, use that script's camera & touchpads if (s3dDeviceMan) { stereoParamsTouchpad = s3dDeviceMan.stereoParamsTouchpad; interaxialTouchpad = s3dDeviceMan.interaxialTouchpad; zeroPrlxTouchpad = s3dDeviceMan.zeroPrlxTouchpad; hitTouchpad = s3dDeviceMan.hitTouchpad; } }
public virtual IEnumerator checkResolutionToDetermineDevice() { yield return(new WaitForSeconds(1f)); this.s3dDeviceMan = (s3dDeviceManager)this.gameObject.GetComponent(typeof(s3dDeviceManager)); if (this.s3dDeviceMan) { if (((Screen.width == 960) && (Screen.height == 640)) || ((Screen.width == 640) && (Screen.height == 960))) { this.s3dDeviceMan.phoneLayout = phoneType.iPhone4_LandLeft; } else { if ((Screen.width == 1024) && (Screen.height == 768)) { this.s3dDeviceMan.phoneLayout = phoneType.iPad2_LandLeft; } else { if ((Screen.width == 768) && (Screen.height == 1024)) { this.s3dDeviceMan.phoneLayout = phoneType.iPad2_Portrait; } else { if ((Screen.width == 2048) && (Screen.height == 1536)) { this.s3dDeviceMan.phoneLayout = phoneType.iPad3_LandLeft; } else { if ((Screen.width == 1536) && (Screen.height == 2048)) { this.s3dDeviceMan.phoneLayout = phoneType.iPad3_Portrait; } else { } } } } } // (resolution doesn't match any iOS device, so leave it alone) this.s3dDeviceMan.setPhoneLayout(); this.s3dDeviceMan.camera3D.initStereoCamera(); } }
public virtual IEnumerator checkResolutionToDetermineDevice() { yield return(new WaitForSeconds(1f)); this.s3dDeviceMan = (s3dDeviceManager)this.gameObject.GetComponent(typeof(s3dDeviceManager)); if (this.s3dDeviceMan) { if (((Screen.width == 800) && (Screen.height == 480)) || ((Screen.width == 480) && (Screen.height == 800))) { this.s3dDeviceMan.phoneLayout = phoneType.Thrill_LandLeft; } else { if (((Screen.width == 960) && (Screen.height == 540)) || ((Screen.width == 540) && (Screen.height == 960))) { this.s3dDeviceMan.phoneLayout = phoneType.OneS_LandLeft; } else { if (((Screen.width == 1280) && (Screen.height == 720)) || ((Screen.width == 720) && (Screen.height == 1280))) { this.s3dDeviceMan.phoneLayout = phoneType.GalaxyNexus_LandLeft; } else { if (((Screen.width == 1280) && (Screen.height == 800)) || ((Screen.width == 800) && (Screen.height == 1280))) { this.s3dDeviceMan.phoneLayout = phoneType.GalaxyNote_LandLeft; } else { } } } } // (resolution doesn't match any iOS device, so leave it alone) this.s3dDeviceMan.setPhoneLayout(); this.s3dDeviceMan.camera3D.initStereoCamera(); } }