public IEnumerator LinkPortraitAsync(apPortrait portrait, apOptModifierUnitBase parentModifier, apAsyncTimer asyncTimer)
        {
            _portrait       = portrait;
            _parentModifier = parentModifier;

            switch (_syncTarget)
            {
            case apModifierParamSetGroup.SYNC_TARGET.Static:
                break;

            case apModifierParamSetGroup.SYNC_TARGET.Controller:
                //_keyControlParam = _portrait.GetControlParam(_keyControlParamName);
                _keyControlParam = _portrait.GetControlParam(_keyControlParamID);
                break;

            case apModifierParamSetGroup.SYNC_TARGET.KeyFrame:
                _keyAnimClip = _portrait.GetAnimClip(_keyAnimClipID);
                if (_keyAnimClip == null)
                {
                    Debug.LogError("Error : No AnimClip [" + _keyAnimClipID + "]");
                    break;
                }

                _keyAnimTimeline = _keyAnimClip.GetTimeline(_keyAnimTimelineID);
                if (_keyAnimTimeline == null)
                {
                    Debug.LogError("Error : No AnimTimeline [" + _keyAnimTimelineID + "]");
                    break;
                }

                _keyAnimTimelineLayer = _keyAnimTimeline.GetTimelineLayer(_keyAnimTimelineLayerID);

                if (_keyAnimTimelineLayer == null)
                {
                    Debug.LogError("Error : No AnimTimelineLayer [" + _keyAnimTimelineLayerID + "]");
                    break;
                }

                break;

            default:
                Debug.LogError("apOptParamSetGroup : 알수 없는 타입 : " + _syncTarget);
                break;
            }

            for (int i = 0; i < _paramSetList.Count; i++)
            {
                yield return(_paramSetList[i].LinkParamSetGroupAsync(this, portrait, asyncTimer));
            }

            //Async Wait
            if (asyncTimer.IsYield())
            {
                yield return(asyncTimer.WaitAndRestart());
            }
        }
        public void LinkPortrait(apPortrait portrait, apOptModifierUnitBase parentModifier)
        {
            _portrait       = portrait;
            _parentModifier = parentModifier;

            switch (_syncTarget)
            {
            case apModifierParamSetGroup.SYNC_TARGET.Static:
                break;

            case apModifierParamSetGroup.SYNC_TARGET.Controller:
                //_keyControlParam = _portrait.GetControlParam(_keyControlParamName);
                _keyControlParam = _portrait.GetControlParam(_keyControlParamID);
                break;

            case apModifierParamSetGroup.SYNC_TARGET.KeyFrame:
                _keyAnimClip = _portrait.GetAnimClip(_keyAnimClipID);
                if (_keyAnimClip == null)
                {
                    Debug.LogError("Error : No AnimClip [" + _keyAnimClipID + "]");
                    break;
                }

                _keyAnimTimeline = _keyAnimClip.GetTimeline(_keyAnimTimelineID);
                if (_keyAnimTimeline == null)
                {
                    Debug.LogError("Error : No AnimTimeline [" + _keyAnimTimelineID + "]");
                    break;
                }

                _keyAnimTimelineLayer = _keyAnimTimeline.GetTimelineLayer(_keyAnimTimelineLayerID);

                if (_keyAnimTimelineLayer == null)
                {
                    Debug.LogError("Error : No AnimTimelineLayer [" + _keyAnimTimelineLayerID + "]");
                    break;
                }

                break;

            default:
                Debug.LogError("apOptParamSetGroup : 알수 없는 타입 : " + _syncTarget);
                break;
            }

            for (int i = 0; i < _paramSetList.Count; i++)
            {
                _paramSetList[i].LinkParamSetGroup(this, portrait);
            }

            // 삭제 19.5.20 : _calculatedWeightedVertexList 변수 삭제
            //for (int i = 0; i < _calculatedWeightedVertexList.Count; i++)
            //{
            //	_calculatedWeightedVertexList[i].Link(portrait.GetOptTransform(_calculatedWeightedVertexList[i]._meshTransform_ID));
            //}
        }
        // [런타임에서] Portrait를 연결하고, Portrait를 검색하여 animPlayData를 세팅한다.
        // 다른 Link가 모두 끝난뒤에 호출하자
        /// <summary>
        /// Connect to Portrait and initialize it for runtime processing.
        /// </summary>
        /// <param name="portrait"></param>
        public void LinkPortrait(apPortrait portrait)
        {
            _portrait = portrait;

            InitAndLink();

            if (_animPlayDataList == null)
            {
                _animPlayDataList = new List <apAnimPlayData>();
            }

            apAnimPlayData animPlayData = null;

            for (int i = 0; i < _animPlayDataList.Count; i++)
            {
                animPlayData          = _animPlayDataList[i];
                animPlayData._isValid = false;                //일단 유효성 초기화 (나중에 값 넣으면 자동으로 true)

                apAnimClip animClip = _portrait.GetAnimClip(animPlayData._animClipID);


                apOptRootUnit rootUnit = _portrait._optRootUnitList.Find(delegate(apOptRootUnit a)
                {
                    if (a._rootOptTransform != null)
                    {
                        if (a._rootOptTransform._meshGroupUniqueID == animPlayData._meshGroupID)
                        {
                            return(true);
                        }
                    }
                    return(false);
                });

                if (animClip != null && rootUnit != null)
                {
                    animPlayData.Link(animClip, rootUnit);

                    //추가 : 여기서 ControlParamResult를 미리 만들어서 이후에 AnimClip이 미리 만들수 있게 해주자
                    animClip.MakeAndLinkControlParamResults();
                }
            }

            //추가 : 메카님 연동
            _mecanim.LinkPortrait(portrait, this);


            if (portrait._isUsingMecanim && portrait._animator != null)
            {
                _isMecanim = true;
            }
            else
            {
                _isMecanim = false;
            }
        }