| 843 | } |
| 844 | |
| 845 | void OpenCLKdeDepthPacketProcessor::process(const DepthPacket &packet) |
| 846 | { |
| 847 | if (!listener_) |
| 848 | return; |
| 849 | |
| 850 | if(!impl_->programInitialized && !impl_->initProgram()) |
| 851 | { |
| 852 | impl_->runtimeOk = false; |
| 853 | LOG_ERROR << "could not initialize OpenCLKdeDepthPacketProcessor"; |
| 854 | return; |
| 855 | } |
| 856 | |
| 857 | impl_->startTiming(); |
| 858 | |
| 859 | impl_->ir_frame->timestamp = packet.timestamp; |
| 860 | impl_->depth_frame->timestamp = packet.timestamp; |
| 861 | impl_->ir_frame->sequence = packet.sequence; |
| 862 | impl_->depth_frame->sequence = packet.sequence; |
| 863 | |
| 864 | impl_->runtimeOk = impl_->run(packet); |
| 865 | |
| 866 | impl_->stopTiming(LOG_INFO); |
| 867 | |
| 868 | if (!impl_->runtimeOk) |
| 869 | { |
| 870 | impl_->ir_frame->status = 1; |
| 871 | impl_->depth_frame->status = 1; |
| 872 | } |
| 873 | |
| 874 | if(listener_->onNewFrame(Frame::Ir, impl_->ir_frame)) |
| 875 | impl_->newIrFrame(); |
| 876 | if(listener_->onNewFrame(Frame::Depth, impl_->depth_frame)) |
| 877 | impl_->newDepthFrame(); |
| 878 | } |
| 879 | |
| 880 | Allocator *OpenCLKdeDepthPacketProcessor::getAllocator() |
| 881 | { |
nothing calls this directly
no test coverage detected