我想跟踪Kinect的联合位置(LeftKnee)。问题是我在reference to a non-shared member requires an object reference
部分得到了Skeleton.Joints
。有人可以帮帮我吗?
Private Sub SensorSkeletonFrameReady(ByVal sender As Object, ByVal e As SkeletonFrameReadyEventArgs)
Dim skeletons(-1) As Skeleton
Using skeletonFrame As SkeletonFrame = e.OpenSkeletonFrame()
If skeletonFrame IsNot Nothing Then
skeletons = New Skeleton(skeletonFrame.SkeletonArrayLength - 1) {}
skeletonFrame.CopySkeletonDataTo(skeletons)
Dim j As Joint = Skeleton.Joints(JointType.LeftKnee)
End If
End Using
答案 0 :(得分:0)
您错误地引用了JointType
枚举。请参阅MSDN上的JointType Enumeration documentation以获取可能的枚举值列表。
它是JointType.KneeLeft
,而不是'LeftKnee'。