Path: blob/master/modules/gapi/src/backends/cpu/gcpukernel.cpp
16344 views
// This file is part of OpenCV project.1// It is subject to the license terms in the LICENSE file found in the top-level directory2// of this distribution and at http://opencv.org/license.html.3//4// Copyright (C) 2018 Intel Corporation567#include "precomp.hpp"89#include <cassert>1011#include "opencv2/gapi/cpu/gcpukernel.hpp"1213const cv::gapi::own::Mat& cv::GCPUContext::inMat(int input)14{15return inArg<cv::gapi::own::Mat>(input);16}1718cv::gapi::own::Mat& cv::GCPUContext::outMatR(int output)19{20return *util::get<cv::gapi::own::Mat*>(m_results.at(output));21}2223const cv::gapi::own::Scalar& cv::GCPUContext::inVal(int input)24{25return inArg<cv::gapi::own::Scalar>(input);26}2728cv::gapi::own::Scalar& cv::GCPUContext::outValR(int output)29{30return *util::get<cv::gapi::own::Scalar*>(m_results.at(output));31}3233cv::detail::VectorRef& cv::GCPUContext::outVecRef(int output)34{35return util::get<cv::detail::VectorRef>(m_results.at(output));36}3738cv::GCPUKernel::GCPUKernel()39{40}4142cv::GCPUKernel::GCPUKernel(const GCPUKernel::F &f)43: m_f(f)44{45}4647void cv::GCPUKernel::apply(GCPUContext &ctx)48{49GAPI_Assert(m_f);50m_f(ctx);51}525354