#ifndef PCLBODY_H
#define PCLBODY_H

#define NOMINMAX
#include <Kinect.h>
#include <pcl\visualization\cloud_viewer.h>

class pclBody
{
	IKinectSensor* kinect;
	IBodyFrameSource* bodyFrameSource;
	IBodyFrameReader* bodyFrameReader;
	IBody* bodies[BODY_COUNT];
	Joint joints[JointType::JointType_Count];
	IFrameDescription* cameraDescription;
	HRESULT hResult;
public:
	pclBody();
	void updateBodyFrame();
	BOOLEAN touchPlane(double a, double b, double c, double d, int jointType);
	pcl::PointCloud<pcl::PointXYZRGB>::Ptr jointsToPointCloud();
	pcl::PointCloud<pcl::PointXYZRGB>::Ptr handsToPointCloud();
};

#endif