//추가 : ModMeshSet을 이용한다.
 public ModWeightPair(apOptModifiedMesh_Vertex modMeshSet_Vertex)
 {
     _isCalculated      = false;
     _modMesh           = null;
     _modMeshSet_Vertex = modMeshSet_Vertex;
     _weight            = 0.0f;
 }
Exemple #2
0
        // Link
        //---------------------------------------------------------------------------------
        public void Link(apPortrait portrait)
        {
            _portrait = portrait;

            if (IsVertex)
            {
                apOptModifiedMesh_Vertex sub_Vertex = SubModMesh_Vertex;
                if (sub_Vertex != null)
                {
                    sub_Vertex.Link(this);
                }
            }

            if (IsTransform)
            {
                apOptModifiedMesh_Transform sub_Transform = SubModMesh_Transform;
                if (sub_Transform != null)
                {
                    sub_Transform.Link(this);
                }
            }

            if (IsRigging)
            {
                apOptModifiedMesh_VertexRig sub_Rigging = SubModMesh_Rigging;
                if (sub_Rigging != null)
                {
                    sub_Rigging.Link(portrait, this);
                }
            }

            if (IsPhysics)
            {
                apOptModifiedMesh_Physics sub_Physics = SubModMesh_Physics;
                if (sub_Physics != null)
                {
                    sub_Physics.Link(portrait, this);
                }
            }

            if (IsColor)
            {
                apOptModifiedMesh_Color sub_Color = SubModMesh_Color;
                if (sub_Color != null)
                {
                    sub_Color.Link(this);
                }
            }

            if (IsExtra)
            {
                apOptModifiedMesh_Extra sub_Extra = SubModMesh_Extra;
                if (sub_Extra != null)
                {
                    sub_Extra.Link(portrait, this);
                }
            }
        }
Exemple #3
0
        //서브 Bake 함수들
        //---------------------------------------------------------------------------------
        public void Bake_Vertex(        //apOptMesh targetMesh,
            List <apModifiedVertex> modVerts)
        {
            _dataType |= DATA_TYPE.Vertex;

            _subModMesh_Vertex    = new apOptModifiedMesh_Vertex[1];
            _subModMesh_Vertex[0] = new apOptModifiedMesh_Vertex();
            apOptModifiedMesh_Vertex subMod_Vertex = _subModMesh_Vertex[0];


            //if (_targetMesh == null)
            //{
            //	Debug.LogError("Vert Morph인데 Target Mesh가 Null");
            //	Debug.LogError("Target Transform [" + _targetTransform.transform.name + "]");
            //}

            subMod_Vertex.Bake(modVerts);
        }