Skip to content

Instantly share code, notes, and snippets.

@TakashiYoshinaga
Created December 5, 2019 02:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TakashiYoshinaga/919a4fdc20e88f0bbcd8686e4382b379 to your computer and use it in GitHub Desktop.
Save TakashiYoshinaga/919a4fdc20e88f0bbcd8686e4382b379 to your computer and use it in GitHub Desktop.
Acquisition of calibration info and function.
private void InitKinect()
{
//0番目のKinectと接続
kinect = Device.Open(0);
//Kinectの各種モードを設定して動作開始(設定内容自体は今回は特に考えなくてOK)
kinect.StartCameras(new DeviceConfiguration
{
ColorFormat = ImageFormat.ColorBGRA32,
ColorResolution = ColorResolution.R720p,
DepthMode = DepthMode.NFOV_2x2Binned,
SynchronizedImagesOnly = true,
CameraFPS = FPS.FPS30
});
//(追加)画像間の位置合わせに関する情報を取得し、transformationに代入
transformation = kinect.GetCalibration().CreateTransformation();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment