我想从包含joint / x / y / z的文本文件创建一个骨架 我有创建关节的问题
string[] JointPoints = line.Split('/');
float x = (float)Convert.ToDouble(JointPoints[1]);
float y = (float)Convert.ToDouble(JointPoints[2]);
float z = (float)Convert.ToDouble(JointPoints[3]);
Joint j = new Joint();
var pos = j.Position;
switch (JointPoints[0].ToUpper())
{
case "HEAD":
//j.JointType = JointType.Head; <--- Can't do this,
pos.X = x;pos.Y = y;pos.Z = z;
playSkeleton.Joints[JointType.Head] = j;
break;