{"action":"closed","number":612,"pull_request":{"url":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612","id":62622738,"html_url":"https://github.com/OpenKinect/libfreenect2/pull/612","diff_url":"https://github.com/OpenKinect/libfreenect2/pull/612.diff","patch_url":"https://github.com/OpenKinect/libfreenect2/pull/612.patch","issue_url":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/612","number":612,"state":"closed","locked":false,"title":"Protonect: Add timeout arg for waitForNewFrame()","user":{"login":"hanyazou","id":493387,"avatar_url":"https://avatars.githubusercontent.com/u/493387?v=3","gravatar_id":"","url":"https://api.github.com/users/hanyazou","html_url":"https://github.com/hanyazou","followers_url":"https://api.github.com/users/hanyazou/followers","following_url":"https://api.github.com/users/hanyazou/following{/other_user}","gists_url":"https://api.github.com/users/hanyazou/gists{/gist_id}","starred_url":"https://api.github.com/users/hanyazou/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hanyazou/subscriptions","organizations_url":"https://api.github.com/users/hanyazou/orgs","repos_url":"https://api.github.com/users/hanyazou/repos","events_url":"https://api.github.com/users/hanyazou/events{/privacy}","received_events_url":"https://api.github.com/users/hanyazou/received_events","type":"User","site_admin":false},"body":"From #598 (Protonect ignores ^C)\r\n\r\nAdd timeout argument for waitForNewFrames() in the Protonect main loop. The Protonect exit if no frames come from the Kinect sensor for 10 seconds. This works only with c++11 option.\r\n\r\nTested on Mac OS X and ubuntu.\r\n\r\n * Mac OS X 10.11 with ENABLE_CXX11=ON\r\n   * run \"Protonect -frames 1\" 40,000 times (about 100 hours)\r\n   * Timeout in waitForNewFrames() occurred 26 times\r\n * Mac OS X 10.11 with ENABLE_CXX11=OFF\r\n   * build and run \"Protonect\" normally\r\n * ubuntu 15.10 (Intel Mac) with ENABLE_CXX11=ON\r\n   * build and run \"Protonect -frames 1\" 10,000 times. (no timeout occurred)\r\n * ubuntu 15.10 (Intel Mac) with ENABLE_CXX11=OFF\r\n   * build and run \"Protonect -frames 1\" 10,000 times. (no timeout occurred)\r\n\r\nThere are some remaining issues.\r\n\r\nISSUE 1:\r\nProtonect exit abnormally with \"Abort trap: 6\" in Freenect2DeviceImpl::~Freenect2DeviceImpl() when the timeout fired. The probability is 5/26. (i.e. 5/40,000)\r\nI think we can ignore this issue because the probability is very low.\r\n\r\n>& ./bin/Protonect -frames 1\r\nVersion: 0.2.0\r\nEnvironment variables: LOGFILE=<protonect.log>\r\nUsage: ./bin/Protonect [-gpu=<id>] [gl | cl | cuda | cpu] [<device serial>]\r\n        [-noviewer] [-norgb | -nodepth] [-help] [-version]\r\n        [-frames <number of frames to process>]\r\nTo pause and unpause: pkill -USR1 Protonect\r\n[Info] [OpenCLDepthPacketProcessorImpl]  devices:\r\n[Info] [OpenCLDepthPacketProcessorImpl]   0: Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz (CPU)[Intel]\r\n[Info] [OpenCLDepthPacketProcessorImpl]   1: GeForce GTX 675MX (GPU)[NVIDIA]\r\n[Info] [OpenCLDepthPacketProcessorImpl] selected device: GeForce GTX 675MX (GPU)[NVIDIA]\r\n[Info] [OpenCLDepthPacketProcessorImpl] building OpenCL program...\r\n[Info] [OpenCLDepthPacketProcessorImpl] OpenCL program built successfully\r\n[Info] [Freenect2Impl] enumerating devices...\r\n[Info] [Freenect2Impl] 13 usb devices connected\r\n[Info] [Freenect2Impl] found valid Kinect v2 @20:16 with serial 005697142447\r\n[Info] [Freenect2Impl] found 1 devices\r\n[Info] [Freenect2DeviceImpl] opening...\r\n[Info] [Freenect2DeviceImpl] opened\r\n[Info] [Freenect2DeviceImpl] starting...\r\n[Debug] [Freenect2DeviceImpl] status 0x090000: 1024\r\n[Debug] [Freenect2DeviceImpl] status 0x090000: 9729\r\n[Debug] [Freenect2DeviceImpl] status 0x090000: 9731\r\n[Info] [Freenect2DeviceImpl] submitting rgb transfers...\r\n[Info] [Freenect2DeviceImpl] submitting depth transfers...\r\n[Info] [Freenect2DeviceImpl] started\r\ndevice serial: 005697142447\r\ndevice firmware: 4.0.3912.0\r\n[Info] [VTRgbPacketProcessor] avg. time: 16.7513ms -> ~59.6968Hz\r\n[Info] [VTRgbPacketProcessor] avg. time: 16.6441ms -> ~60.0814Hz\r\ntimeout!\r\n[Info] [Freenect2DeviceImpl] closing...\r\n[Info] [Freenect2DeviceImpl] stopping...\r\n[Info] [Freenect2DeviceImpl] canceling rgb transfers...\r\nlibc++abi.dylib: terminating with uncaught exception of type std::__1::system_error: mutex lock failed: Invalid argument\r\n82471 Abort trap: 6           ./bin/Protonect cl -frames 1\r\n\r\nISSUE2:\r\nProtonect message end with \"status 0x090000: 1024\" and does not show the window and images. The probability is 4,586/40,000. I will report this issue later separately.\r\n\r\n>& ./bin/Protonect -frames 1\r\nVersion: 0.2.0\r\nEnvironment variables: LOGFILE=<protonect.log>\r\nUsage: ./bin/Protonect [-gpu=<id>] [gl | cl | cuda | cpu] [<device serial>]\r\n        [-noviewer] [-norgb | -nodepth] [-help] [-version]\r\n        [-frames <number of frames to process>]\r\nTo pause and unpause: pkill -USR1 Protonect\r\n[Info] [OpenCLDepthPacketProcessorImpl]  devices:\r\n[Info] [OpenCLDepthPacketProcessorImpl]   0: Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz (CPU)[Intel]\r\n[Info] [OpenCLDepthPacketProcessorImpl]   1: GeForce GTX 675MX (GPU)[NVIDIA]\r\n[Info] [OpenCLDepthPacketProcessorImpl] selected device: GeForce GTX 675MX (GPU)[NVIDIA]\r\n[Info] [OpenCLDepthPacketProcessorImpl] building OpenCL program...\r\n[Info] [OpenCLDepthPacketProcessorImpl] OpenCL program built successfully\r\n[Info] [Freenect2Impl] enumerating devices...\r\n[Info] [Freenect2Impl] 13 usb devices connected\r\n[Info] [Freenect2Impl] found valid Kinect v2 @20:31 with serial 005697142447\r\n[Info] [Freenect2Impl] found 1 devices\r\n[Info] [Freenect2DeviceImpl] opening...\r\n[Info] [Freenect2DeviceImpl] opened\r\n[Info] [Freenect2DeviceImpl] starting...\r\n[Debug] [Freenect2DeviceImpl] status 0x090000: 1024","created_at":"2016-03-12T00:30:49Z","updated_at":"2016-03-13T00:11:52Z","closed_at":"2016-03-13T00:11:52Z","merged_at":"2016-03-13T00:11:52Z","merge_commit_sha":"f6a59ec2e67e0a1318985eebf9afb67b1e360d69","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612/commits","review_comments_url":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612/comments","review_comment_url":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/612/comments","statuses_url":"https://api.github.com/repos/OpenKinect/libfreenect2/statuses/238c44868473e87612f1bdcde24e99ef87e68fd2","head":{"label":"hanyazou:wait_new_frames_timeout","ref":"wait_new_frames_timeout","sha":"238c44868473e87612f1bdcde24e99ef87e68fd2","user":{"login":"hanyazou","id":493387,"avatar_url":"https://avatars.githubusercontent.com/u/493387?v=3","gravatar_id":"","url":"https://api.github.com/users/hanyazou","html_url":"https://github.com/hanyazou","followers_url":"https://api.github.com/users/hanyazou/followers","following_url":"https://api.github.com/users/hanyazou/following{/other_user}","gists_url":"https://api.github.com/users/hanyazou/gists{/gist_id}","starred_url":"https://api.github.com/users/hanyazou/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hanyazou/subscriptions","organizations_url":"https://api.github.com/users/hanyazou/orgs","repos_url":"https://api.github.com/users/hanyazou/repos","events_url":"https://api.github.com/users/hanyazou/events{/privacy}","received_events_url":"https://api.github.com/users/hanyazou/received_events","type":"User","site_admin":false},"repo":{"id":35128823,"name":"libfreenect2","full_name":"hanyazou/libfreenect2","owner":{"login":"hanyazou","id":493387,"avatar_url":"https://avatars.githubusercontent.com/u/493387?v=3","gravatar_id":"","url":"https://api.github.com/users/hanyazou","html_url":"https://github.com/hanyazou","followers_url":"https://api.github.com/users/hanyazou/followers","following_url":"https://api.github.com/users/hanyazou/following{/other_user}","gists_url":"https://api.github.com/users/hanyazou/gists{/gist_id}","starred_url":"https://api.github.com/users/hanyazou/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hanyazou/subscriptions","organizations_url":"https://api.github.com/users/hanyazou/orgs","repos_url":"https://api.github.com/users/hanyazou/repos","events_url":"https://api.github.com/users/hanyazou/events{/privacy}","received_events_url":"https://api.github.com/users/hanyazou/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/hanyazou/libfreenect2","description":"Open source drivers for the Kinect for Windows v2 device","fork":true,"url":"https://api.github.com/repos/hanyazou/libfreenect2","forks_url":"https://api.github.com/repos/hanyazou/libfreenect2/forks","keys_url":"https://api.github.com/repos/hanyazou/libfreenect2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hanyazou/libfreenect2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hanyazou/libfreenect2/teams","hooks_url":"https://api.github.com/repos/hanyazou/libfreenect2/hooks","issue_events_url":"https://api.github.com/repos/hanyazou/libfreenect2/issues/events{/number}","events_url":"https://api.github.com/repos/hanyazou/libfreenect2/events","assignees_url":"https://api.github.com/repos/hanyazou/libfreenect2/assignees{/user}","branches_url":"https://api.github.com/repos/hanyazou/libfreenect2/branches{/branch}","tags_url":"https://api.github.com/repos/hanyazou/libfreenect2/tags","blobs_url":"https://api.github.com/repos/hanyazou/libfreenect2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hanyazou/libfreenect2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hanyazou/libfreenect2/git/refs{/sha}","trees_url":"https://api.github.com/repos/hanyazou/libfreenect2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hanyazou/libfreenect2/statuses/{sha}","languages_url":"https://api.github.com/repos/hanyazou/libfreenect2/languages","stargazers_url":"https://api.github.com/repos/hanyazou/libfreenect2/stargazers","contributors_url":"https://api.github.com/repos/hanyazou/libfreenect2/contributors","subscribers_url":"https://api.github.com/repos/hanyazou/libfreenect2/subscribers","subscription_url":"https://api.github.com/repos/hanyazou/libfreenect2/subscription","commits_url":"https://api.github.com/repos/hanyazou/libfreenect2/commits{/sha}","git_commits_url":"https://api.github.com/repos/hanyazou/libfreenect2/git/commits{/sha}","comments_url":"https://api.github.com/repos/hanyazou/libfreenect2/comments{/number}","issue_comment_url":"https://api.github.com/repos/hanyazou/libfreenect2/issues/comments{/number}","contents_url":"https://api.github.com/repos/hanyazou/libfreenect2/contents/{+path}","compare_url":"https://api.github.com/repos/hanyazou/libfreenect2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hanyazou/libfreenect2/merges","archive_url":"https://api.github.com/repos/hanyazou/libfreenect2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hanyazou/libfreenect2/downloads","issues_url":"https://api.github.com/repos/hanyazou/libfreenect2/issues{/number}","pulls_url":"https://api.github.com/repos/hanyazou/libfreenect2/pulls{/number}","milestones_url":"https://api.github.com/repos/hanyazou/libfreenect2/milestones{/number}","notifications_url":"https://api.github.com/repos/hanyazou/libfreenect2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hanyazou/libfreenect2/labels{/name}","releases_url":"https://api.github.com/repos/hanyazou/libfreenect2/releases{/id}","deployments_url":"https://api.github.com/repos/hanyazou/libfreenect2/deployments","created_at":"2015-05-05T23:24:29Z","updated_at":"2016-02-13T08:53:34Z","pushed_at":"2016-03-11T23:31:37Z","git_url":"git://github.com/hanyazou/libfreenect2.git","ssh_url":"git@github.com:hanyazou/libfreenect2.git","clone_url":"https://github.com/hanyazou/libfreenect2.git","svn_url":"https://github.com/hanyazou/libfreenect2","homepage":null,"size":4699,"stargazers_count":7,"watchers_count":7,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":0,"forks":4,"open_issues":0,"watchers":7,"default_branch":"master"}},"base":{"label":"OpenKinect:master","ref":"master","sha":"64de67c1a1421ea0335e0055214f371c5b8c4c8e","user":{"login":"OpenKinect","id":478332,"avatar_url":"https://avatars.githubusercontent.com/u/478332?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenKinect","html_url":"https://github.com/OpenKinect","followers_url":"https://api.github.com/users/OpenKinect/followers","following_url":"https://api.github.com/users/OpenKinect/following{/other_user}","gists_url":"https://api.github.com/users/OpenKinect/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenKinect/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenKinect/subscriptions","organizations_url":"https://api.github.com/users/OpenKinect/orgs","repos_url":"https://api.github.com/users/OpenKinect/repos","events_url":"https://api.github.com/users/OpenKinect/events{/privacy}","received_events_url":"https://api.github.com/users/OpenKinect/received_events","type":"Organization","site_admin":false},"repo":{"id":14847048,"name":"libfreenect2","full_name":"OpenKinect/libfreenect2","owner":{"login":"OpenKinect","id":478332,"avatar_url":"https://avatars.githubusercontent.com/u/478332?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenKinect","html_url":"https://github.com/OpenKinect","followers_url":"https://api.github.com/users/OpenKinect/followers","following_url":"https://api.github.com/users/OpenKinect/following{/other_user}","gists_url":"https://api.github.com/users/OpenKinect/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenKinect/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenKinect/subscriptions","organizations_url":"https://api.github.com/users/OpenKinect/orgs","repos_url":"https://api.github.com/users/OpenKinect/repos","events_url":"https://api.github.com/users/OpenKinect/events{/privacy}","received_events_url":"https://api.github.com/users/OpenKinect/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenKinect/libfreenect2","description":"Open source drivers for the Kinect for Windows v2 device","fork":false,"url":"https://api.github.com/repos/OpenKinect/libfreenect2","forks_url":"https://api.github.com/repos/OpenKinect/libfreenect2/forks","keys_url":"https://api.github.com/repos/OpenKinect/libfreenect2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenKinect/libfreenect2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenKinect/libfreenect2/teams","hooks_url":"https://api.github.com/repos/OpenKinect/libfreenect2/hooks","issue_events_url":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/events{/number}","events_url":"https://api.github.com/repos/OpenKinect/libfreenect2/events","assignees_url":"https://api.github.com/repos/OpenKinect/libfreenect2/assignees{/user}","branches_url":"https://api.github.com/repos/OpenKinect/libfreenect2/branches{/branch}","tags_url":"https://api.github.com/repos/OpenKinect/libfreenect2/tags","blobs_url":"https://api.github.com/repos/OpenKinect/libfreenect2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenKinect/libfreenect2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenKinect/libfreenect2/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenKinect/libfreenect2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenKinect/libfreenect2/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenKinect/libfreenect2/languages","stargazers_url":"https://api.github.com/repos/OpenKinect/libfreenect2/stargazers","contributors_url":"https://api.github.com/repos/OpenKinect/libfreenect2/contributors","subscribers_url":"https://api.github.com/repos/OpenKinect/libfreenect2/subscribers","subscription_url":"https://api.github.com/repos/OpenKinect/libfreenect2/subscription","commits_url":"https://api.github.com/repos/OpenKinect/libfreenect2/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenKinect/libfreenect2/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenKinect/libfreenect2/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenKinect/libfreenect2/contents/{+path}","compare_url":"https://api.github.com/repos/OpenKinect/libfreenect2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenKinect/libfreenect2/merges","archive_url":"https://api.github.com/repos/OpenKinect/libfreenect2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenKinect/libfreenect2/downloads","issues_url":"https://api.github.com/repos/OpenKinect/libfreenect2/issues{/number}","pulls_url":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenKinect/libfreenect2/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenKinect/libfreenect2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenKinect/libfreenect2/labels{/name}","releases_url":"https://api.github.com/repos/OpenKinect/libfreenect2/releases{/id}","deployments_url":"https://api.github.com/repos/OpenKinect/libfreenect2/deployments","created_at":"2013-12-01T21:59:22Z","updated_at":"2016-03-11T15:27:56Z","pushed_at":"2016-03-13T00:11:52Z","git_url":"git://github.com/OpenKinect/libfreenect2.git","ssh_url":"git@github.com:OpenKinect/libfreenect2.git","clone_url":"https://github.com/OpenKinect/libfreenect2.git","svn_url":"https://github.com/OpenKinect/libfreenect2","homepage":null,"size":5915,"stargazers_count":526,"watchers_count":526,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":248,"mirror_url":null,"open_issues_count":37,"forks":248,"open_issues":37,"watchers":526,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612"},"html":{"href":"https://github.com/OpenKinect/libfreenect2/pull/612"},"issue":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/612"},"comments":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/issues/612/comments"},"review_comments":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/pulls/612/commits"},"statuses":{"href":"https://api.github.com/repos/OpenKinect/libfreenect2/statuses/238c44868473e87612f1bdcde24e99ef87e68fd2"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"xlz","id":1385542,"avatar_url":"https://avatars.githubusercontent.com/u/1385542?v=3","gravatar_id":"","url":"https://api.github.com/users/xlz","html_url":"https://github.com/xlz","followers_url":"https://api.github.com/users/xlz/followers","following_url":"https://api.github.com/users/xlz/following{/other_user}","gists_url":"https://api.github.com/users/xlz/gists{/gist_id}","starred_url":"https://api.github.com/users/xlz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xlz/subscriptions","organizations_url":"https://api.github.com/users/xlz/orgs","repos_url":"https://api.github.com/users/xlz/repos","events_url":"https://api.github.com/users/xlz/events{/privacy}","received_events_url":"https://api.github.com/users/xlz/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"commits":1,"additions":5,"deletions":1,"changed_files":1}}