private void OnEnable()
        {
            voxelDeformer = (RandomDeformer) target;

            if (voxelDeformer.ConstrainBox == null)
                voxelDeformer.ConstrainBox = new PicaVoxelBox(0, 0, 0, voxelDeformer.GetComponent<Volume>().XSize,
                    voxelDeformer.GetComponent<Volume>().YSize, voxelDeformer.GetComponent<Volume>().ZSize);

            constrainBox = voxelDeformer.ConstrainBox;
            constrainToBox = voxelDeformer.ConstrainToBox;
            add = voxelDeformer.AddVoxels;
            num = voxelDeformer.NumVoxels;
            interval = voxelDeformer.Interval;

        }
Пример #2
0
        private void OnEnable()
        {
            voxelDeformer = (RandomDeformer)target;

            if (voxelDeformer.ConstrainBox == null)
            {
                voxelDeformer.ConstrainBox = new PicaVoxelBox(0, 0, 0, voxelDeformer.GetComponent <Volume>().XSize,
                                                              voxelDeformer.GetComponent <Volume>().YSize, voxelDeformer.GetComponent <Volume>().ZSize);
            }

            constrainBox   = voxelDeformer.ConstrainBox;
            constrainToBox = voxelDeformer.ConstrainToBox;
            add            = voxelDeformer.AddVoxels;
            num            = voxelDeformer.NumVoxels;
            interval       = voxelDeformer.Interval;
        }