Ejemplo n.º 1
0
 // Token: 0x06001504 RID: 5380 RVA: 0x00064DB7 File Offset: 0x00062FB7
 private void OnPostRender()
 {
     if (SceneCamera.onSceneCameraPostRender != null)
     {
         SceneCamera.onSceneCameraPostRender(this);
     }
 }
Ejemplo n.º 2
0
 // Token: 0x06000A39 RID: 2617 RVA: 0x0002C990 File Offset: 0x0002AB90
 private static void OnSceneCameraPreRender(SceneCamera sceneCamera)
 {
     if (sceneCamera.cameraRigController)
     {
         DitherModel.RefreshObstructorsForCamera(sceneCamera.cameraRigController);
     }
 }
Ejemplo n.º 3
0
 // Token: 0x06001502 RID: 5378 RVA: 0x00064D8F File Offset: 0x00062F8F
 private void OnPreCull()
 {
     if (SceneCamera.onSceneCameraPreCull != null)
     {
         SceneCamera.onSceneCameraPreCull(this);
     }
 }
Ejemplo n.º 4
0
 // Token: 0x06001285 RID: 4741 RVA: 0x0004F9CF File Offset: 0x0004DBCF
 private void OnPreRender()
 {
     if (SceneCamera.onSceneCameraPreRender != null)
     {
         this.camera.opaqueSortMode = this.sortMode;
         SceneCamera.onSceneCameraPreRender(this);
     }
 }
Ejemplo n.º 5
0
 // Token: 0x0600101D RID: 4125 RVA: 0x00046DF8 File Offset: 0x00044FF8
 private void Awake()
 {
     this.sceneCamera = base.GetComponent <SceneCamera>();
     this.CreateBuffers();
     this.CreateMaterials();
     this.m_RTWidth  = (int)((float)Screen.width / (float)this.m_resolution);
     this.m_RTHeight = (int)((float)Screen.height / (float)this.m_resolution);
 }
Ejemplo n.º 6
0
        // Token: 0x06000669 RID: 1641 RVA: 0x0001A4BC File Offset: 0x000186BC
        private static void OnSceneCameraPreCull(SceneCamera sceneCamera)
        {
            Quaternion rotation = sceneCamera.transform.rotation;

            for (int i = 0; i < Billboard.instanceTransformsList.Count; i++)
            {
                Billboard.instanceTransformsList[i].rotation = rotation;
            }
        }
 // Token: 0x06001772 RID: 6002 RVA: 0x0006F29C File Offset: 0x0006D49C
 private static void OnSceneCameraPreRender(SceneCamera sceneCamera)
 {
     if (sceneCamera.cameraRigController)
     {
         for (int i = 0; i < WeatherParticles.instancesList.Count; i++)
         {
             WeatherParticles weatherParticles = WeatherParticles.instancesList[i];
             weatherParticles.UpdateForCamera(sceneCamera.cameraRigController, weatherParticles.lockPosition, weatherParticles.lockRotation);
         }
     }
 }
Ejemplo n.º 8
0
        // Token: 0x06000E23 RID: 3619 RVA: 0x00045A74 File Offset: 0x00043C74
        private static void OnSceneCameraPreCull(SceneCamera sceneCamera)
        {
            Camera camera = sceneCamera.camera;

            for (int i = 0; i < ConstrainToScreen.instanceTransformsList.Count; i++)
            {
                Transform transform = ConstrainToScreen.instanceTransformsList[i];
                Vector3   vector    = camera.WorldToViewportPoint(transform.position);
                vector.x           = Mathf.Clamp(vector.x, ConstrainToScreen.boundaryUVSize, 1f - ConstrainToScreen.boundaryUVSize);
                vector.y           = Mathf.Clamp(vector.y, ConstrainToScreen.boundaryUVSize, 1f - ConstrainToScreen.boundaryUVSize);
                transform.position = camera.ViewportToWorldPoint(vector);
            }
        }
Ejemplo n.º 9
0
 // Token: 0x06000D20 RID: 3360 RVA: 0x00040EF4 File Offset: 0x0003F0F4
 private static void OnSceneCameraPreRender(SceneCamera sceneCamera)
 {
     if (sceneCamera.cameraRigController)
     {
         CharacterModel.RefreshObstructorsForCamera(sceneCamera.cameraRigController);
     }
     if (sceneCamera.cameraRigController)
     {
         for (int i = 0; i < CharacterModel.instancesList.Count; i++)
         {
             CharacterModel.instancesList[i].UpdateForCamera(sceneCamera.cameraRigController);
         }
     }
 }
Ejemplo n.º 10
0
        // Token: 0x06000F36 RID: 3894 RVA: 0x0004B108 File Offset: 0x00049308
        private static void OnSceneCameraPreCull(SceneCamera sceneCamera)
        {
            Transform  transform = Camera.current.transform;
            Quaternion rotation  = transform.rotation;
            Vector3    forward   = transform.forward;

            for (int i = 0; i < EyeFlare.instancesList.Count; i++)
            {
                EyeFlare eyeFlare = EyeFlare.instancesList[i];
                float    num      = eyeFlare.localScale;
                if (eyeFlare.directionSource)
                {
                    float num2 = Vector3.Dot(forward, eyeFlare.directionSource.forward) * -0.5f + 0.5f;
                    num *= num2 * num2;
                }
                eyeFlare.transform.localScale = new Vector3(num, num, num);
                eyeFlare.transform.rotation   = rotation;
            }
        }
        // Token: 0x060014F5 RID: 5365 RVA: 0x00064B38 File Offset: 0x00062D38
        private static void OnSceneCameraPreCull(SceneCamera sceneCamera)
        {
            Vector3 position = sceneCamera.transform.position;

            for (int i = 0; i < ScaleSpriteByCamDistance.instancesList.Count; i++)
            {
                ScaleSpriteByCamDistance scaleSpriteByCamDistance = ScaleSpriteByCamDistance.instancesList[i];
                Transform transform = scaleSpriteByCamDistance.transform;
                float     num       = 1f;
                float     num2      = Vector3.Distance(position, transform.position);
                switch (scaleSpriteByCamDistance.scalingMode)
                {
                case ScaleSpriteByCamDistance.ScalingMode.Direct:
                    num = num2;
                    break;

                case ScaleSpriteByCamDistance.ScalingMode.Square:
                    num = num2 * num2;
                    break;

                case ScaleSpriteByCamDistance.ScalingMode.Sqrt:
                    num = Mathf.Sqrt(num2);
                    break;

                case ScaleSpriteByCamDistance.ScalingMode.Cube:
                    num = num2 * num2 * num2;
                    break;

                case ScaleSpriteByCamDistance.ScalingMode.CubeRoot:
                    num = Mathf.Pow(num2, 0.33333334f);
                    break;
                }
                num *= scaleSpriteByCamDistance.scaleFactor;
                transform.localScale = new Vector3(num, num, num);
            }
        }
Ejemplo n.º 12
0
        // Token: 0x0600166F RID: 5743 RVA: 0x000607E8 File Offset: 0x0005E9E8
        private void OnPreRenderSceneCam(SceneCamera sceneCam)
        {
            float interpFactor = this.GetInterpFactor(sceneCam.camera.transform.position);

            RenderSettings.ambientLight = Color.Lerp(this.defaultAmbientColor, this.overrideAmbientColor, interpFactor);
        }