From 5f63df740d8e184aedd6f8e135803aee49b3295c Mon Sep 17 00:00:00 2001 From: TinyOh Date: Sat, 16 Mar 2019 11:13:36 +0800 Subject: [PATCH] fix(api): points cloud ghost data --- src/mynteye/api/processor/points_processor.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mynteye/api/processor/points_processor.cc b/src/mynteye/api/processor/points_processor.cc index 6903121..ea5b08e 100644 --- a/src/mynteye/api/processor/points_processor.cc +++ b/src/mynteye/api/processor/points_processor.cc @@ -105,6 +105,9 @@ bool PointsProcessor::OnProcess( // Missing points denoted by NaNs if (!DepthTraits::valid(depth)) { + dptr[u][0] = 0; + dptr[u][1] = 0; + dptr[u][2] = 0; continue; } dptr[u][0] = (u - center_x) * depth * constant_x ;