Esempio n. 1
0
 public virtual void Init(PostProcessParam param)
 {
     m_mgr        = param.mgr;
     m_mainCamera = param.mainCamera;
     m_LodLevel   = param.lodLevel;
     m_enable     = false;
 }
Esempio n. 2
0
 void OnLodChanged(LODMgr.LOD_LEVEL lodLevel)
 {
     for (int i = 0; i < m_PostProcessList.Length; ++i)
     {
         m_PostProcessList[i].SetLodLevel(lodLevel);
     }
     m_flipPostProcess.SetLodLevel(lodLevel);
 }
Esempio n. 3
0
 void Start()
 {
     LODMgr.LOD_LEVEL lodLevel = LODMgr.LOD_LEVEL.LOD_LEVEL_HIGH;
     if (LODMgr.GetInstance() != null)
     {
         lodLevel = LODMgr.GetInstance().GetLODLevel();
         OnLodChanged(lodLevel);
         LODMgr.GetInstance().AddLODChangedListener(OnLodChanged);
     }
 }
Esempio n. 4
0
    void Awake()
    {
        m_MainCamera = gameObject.GetComponent <Camera>();
        if (m_MainCamera == null)
        {
            Debug.LogError("this script must be main camera component!");
        }

        LODMgr.LOD_LEVEL lodLevel = LODMgr.LOD_LEVEL.LOD_LEVEL_HIGH;
        m_flipPostProcess = gameObject.AddComponent <FlipPostProcess>();
        GenPostProcessChain();
        PostProcessParam param = new PostProcessParam();

        param.mgr        = this;
        param.mainCamera = m_MainCamera;
        param.lodLevel   = lodLevel;
        for (int i = 0; i < m_PostProcessList.Length; ++i)
        {
            m_PostProcessList[i].Init(param);
        }
        m_flipPostProcess.Init(param);
        Regist(this);
    }
Esempio n. 5
0
 public void SetLodLevel(LODMgr.LOD_LEVEL lod)
 {
     m_LodLevel = lod;
 }