• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ GET_PARAM函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中GET_PARAM函数的典型用法代码示例。如果您正苦于以下问题:C++ GET_PARAM函数的具体用法?C++ GET_PARAM怎么用?C++ GET_PARAM使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了GET_PARAM函数的16个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: expFuncRegExExtract

ExpressionValue expFuncRegExExtract(const std::wstring& funcName, const std::vector<ExpressionValue>& parameters)
{
	const std::wstring* source;
	const std::wstring* regexString;
	u64 matchIndex;

	GET_PARAM(parameters,0,source);
	GET_PARAM(parameters,1,regexString);
	GET_OPTIONAL_PARAM(parameters,2,matchIndex,0);

	try
	{
		std::wregex regex(*regexString);
		std::wsmatch result;
		bool found = std::regex_search(*source,result,regex);
		if (found == false || matchIndex >= result.size())
		{
			Logger::queueError(Logger::Error,L"Capture group index %d does not exist",matchIndex);
			return ExpressionValue();
		}
	
		return ExpressionValue(result[(size_t)matchIndex].str());
	} catch (std::regex_error&)
	{
		Logger::queueError(Logger::Error,L"Invalid regular expression");
		return ExpressionValue();
	}
}
开发者ID:JamesLinus,项目名称:armips,代码行数:28,代码来源:ExpressionFunctions.cpp


示例2: GPU_PERF_TEST

GPU_PERF_TEST(ResizeArea, cv::gpu::DeviceInfo, cv::Size, MatType, Scale)
{
    cv::gpu::DeviceInfo devInfo = GET_PARAM(0);
    cv::gpu::setDevice(devInfo.deviceID());

    cv::Size size = GET_PARAM(1);
    int type = GET_PARAM(2);
    int interpolation = cv::INTER_AREA;
    double f = GET_PARAM(3);

    cv::Mat src_host(size, type);
    fill(src_host, 0, 255);

    cv::gpu::GpuMat src(src_host);
    cv::gpu::GpuMat dst;

    cv::gpu::resize(src, dst, cv::Size(), f, f, interpolation);

    declare.time(1.0);

    TEST_CYCLE()
    {
        cv::gpu::resize(src, dst, cv::Size(), f, f, interpolation);
    }
}
开发者ID:vpas,项目名称:opencv,代码行数:25,代码来源:perf_imgproc.cpp


示例3: _radio_setup

adf7021_setup_t*  _radio_setup(void)
{
    uint32_t freq; 
    int16_t  fcal;
    double power; 
    uint16_t dev;
    uint16_t afc;
    
    GET_PARAM(TRX_FREQ, &freq);
    GET_PARAM(TRX_CALIBRATE, &fcal);
    GET_PARAM(TRX_TXPOWER, &power);
    GET_PARAM(TRX_AFSK_DEV, &dev);
    GET_PARAM(TRX_AFC, &afc);

    adf7021_setup_init(&trx_setup);
    adf7021_set_frequency (&trx_setup, freq+fcal);
    trx_setup.vco_osc.xosc_enable = true;
    trx_setup.test_mode.analog = ADF7021_ANALOG_TEST_MODE_RSSI;
    
    adf7021_set_data_rate (&trx_setup, 4400);    
    adf7021_set_modulation (&trx_setup, ADF7021_MODULATION_OVERSAMPLED_2FSK, dev);
    adf7021_set_power (&trx_setup, power, ADF7021_PA_RAMP_OFF);   
    adf7021_set_demodulation (&trx_setup, ADF7021_DEMOD_2FSK_CORRELATOR);
    if (afc > 0)
         adf7021_enable_AFC(&trx_setup, afc);
    
//    ADF7021_INIT_REGISTER(trx_setup.agc, ADF7021_AGC_REGISTER);
//    trx_setup.agc.mode = ADF7021_AGC_MODE_AUTO;
    
    trx_setup.demod.if_bw = ADF7021_DEMOD_IF_BW_12_5;
    adf7021_set_post_demod_filter (&trx_setup, 3400); 
    ADF7021_INIT_REGISTER(trx_setup.test_mode, ADF7021_TEST_MODE_REGISTER);
    trx_setup.test_mode.rx = ADF7021_RX_TEST_MODE_LINEAR_SLICER_ON_TxRxDATA;
    return &trx_setup;
}
开发者ID:PolaricTracker,项目名称:firmware,代码行数:35,代码来源:radio.c


示例4: cmd_converse

static void cmd_converse(Stream *chp, int argc, char* argv[])
{
  (void) argc;
  (void) argv; 
  
  static FBUF packet; 
  chprintf(chp, "***** CONVERSE MODE. Ctrl-D to exit *****\r\n");
  radio_require();
  mon_activate(true); 
  fbq_t* outframes = hdlc_get_encoder_queue();
  
  while (!shellGetLine(chp, buf, BUFSIZE)) { 
    addr_t from, to; 
    GET_PARAM(MYCALL, &from);
    GET_PARAM(DEST, &to);       
    addr_t digis[7];
    uint8_t ndigis = GET_BYTE_PARAM(NDIGIS); 
    GET_PARAM(DIGIS, &digis);  
    fbuf_new(&packet);
    ax25_encode_header(&packet, &from, &to, digis, ndigis, FTYPE_UI, PID_NO_L3);
    fbuf_putstr(&packet, buf);                        
    fbq_put(outframes, packet);
  }
  mon_activate(false);
  radio_release();
}
开发者ID:ohanssen,项目名称:ArcticTracker,代码行数:26,代码来源:commands.c


示例5: GPU_PERF_TEST

GPU_PERF_TEST(Filter2D, cv::gpu::DeviceInfo, cv::Size, MatType, KernelSize)
{
    cv::gpu::DeviceInfo devInfo = GET_PARAM(0);
    cv::gpu::setDevice(devInfo.deviceID());

    cv::Size size = GET_PARAM(1);
    int type = GET_PARAM(2);
    int ksize = GET_PARAM(3);

    cv::Mat src_host(size, type);
    fill(src_host, 0.0, 255.0);

    cv::Mat kernel(ksize, ksize, CV_32FC1);
    fill(kernel, 0.0, 1.0);

    cv::gpu::GpuMat src(src_host);
    cv::gpu::GpuMat dst;

    cv::gpu::filter2D(src, dst, -1, kernel);

    TEST_CYCLE()
    {
        cv::gpu::filter2D(src, dst, -1, kernel);
    }
}
开发者ID:BRAINSia,项目名称:OpenCV_TruncatedSVN,代码行数:25,代码来源:perf_filters.cpp


示例6: trgt_param_get

static void trgt_param_get(struct iscsi_trgt_param *param, struct iscsi_param_info *info)
{
	u32 *iparam = info->target_param;

	GET_PARAM(param, info, iparam, wthreads);
	GET_PARAM(param, info, iparam, target_type);
	GET_PARAM(param, info, iparam, queued_cmnds);
}
开发者ID:BackupTheBerlios,项目名称:iscsitarget-svn,代码行数:8,代码来源:param.c


示例7: SetUp

    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        cv::gpu::setDevice(devInfo.deviceID());

        img = readImage(GET_PARAM(1), cv::IMREAD_GRAYSCALE);
        ASSERT_FALSE(img.empty());
    }
开发者ID:4auka,项目名称:opencv,代码行数:8,代码来源:test_objdetect.cpp


示例8: SetUp

    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        cv::cuda::setDevice(devInfo.deviceID());

        cv::Rect roi(0, 0, 16, 32);
        img = readImage(GET_PARAM(1), cv::IMREAD_GRAYSCALE);
        ASSERT_FALSE(img.empty());
        c_img = img(roi);
    }
开发者ID:Tetragramm,项目名称:opencv_contrib,代码行数:10,代码来源:test_objdetect.cpp


示例9: expFuncSubstr

ExpressionValue expFuncSubstr(const std::wstring& funcName, const std::vector<ExpressionValue>& parameters)
{
	u64 start, count;
	const std::wstring* source;

	GET_PARAM(parameters,0,source);
	GET_PARAM(parameters,1,start);
	GET_PARAM(parameters,2,count);

	return ExpressionValue(source->substr((size_t)start,(size_t)count));
}
开发者ID:JamesLinus,项目名称:armips,代码行数:11,代码来源:ExpressionFunctions.cpp


示例10: PARAM_TEST_CASE

PARAM_TEST_CASE(Canny, AppertureSize, L2gradient)
{
    int apperture_size;
    bool useL2gradient;

    cv::Mat edges_gold;
    virtual void SetUp()
    {
        apperture_size = GET_PARAM(0);
        useL2gradient = GET_PARAM(1);
    }
开发者ID:AaronPlay,项目名称:opencv,代码行数:11,代码来源:test_canny.cpp


示例11: handle_coreblas_taskw

void handle_coreblas_taskw (struct fxt_ev_64 *ev)
{
    FUNC_NAME;
    assert( GET_NBPARAMS(ev) == 2 );
    INIT_PROCESS_ID(process_id);
    INIT_SPECIFIC_THREAD_ID(thread_id, CUR_ID, (unsigned int)GET_PARAM(ev, 1));
    int value = (int)GET_PARAM(ev, 2);
    CHANGE() addVar (CURRENT, COREBLAS_TASKR_ALIAS,  process_id, (varPrec)value);
    CHANGE() addVar (CURRENT, COREBLAS_TASKWR_ALIAS, thread_id,  (varPrec)value);
    free(thread_id);
    free(process_id);
}
开发者ID:joao-lima,项目名称:plasma-kaapi,代码行数:12,代码来源:eztrace_convert_coreblas.c


示例12: PARAM_TEST_CASE

PARAM_TEST_CASE(GoodFeaturesToTrack, cv::gpu::DeviceInfo, MinDistance)
{
    cv::gpu::DeviceInfo devInfo;
    double minDistance;

    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        minDistance = GET_PARAM(1);

        cv::gpu::setDevice(devInfo.deviceID());
    }
开发者ID:MasaMune692,项目名称:alcexamples,代码行数:12,代码来源:test_video.cpp


示例13: PARAM_TEST_CASE

PARAM_TEST_CASE(PyrLKOpticalFlow, cv::cuda::DeviceInfo, Chan, DataType)
{
    cv::cuda::DeviceInfo devInfo;
    int channels;
    int dataType;
    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        channels = GET_PARAM(1);
        dataType = GET_PARAM(2);
        cv::cuda::setDevice(devInfo.deviceID());
    }
开发者ID:cyberCBM,项目名称:DetectO,代码行数:12,代码来源:test_optflow.cpp


示例14: expFuncRFind

ExpressionValue expFuncRFind(const std::wstring& funcName, const std::vector<ExpressionValue>& parameters)
{
	u64 start;
	const std::wstring* source;
	const std::wstring* value;

	GET_PARAM(parameters,0,source);
	GET_PARAM(parameters,1,value);
	GET_OPTIONAL_PARAM(parameters,2,start,std::wstring::npos);

	size_t pos = source->rfind(*value,(size_t)start);
	return ExpressionValue(pos == std::wstring::npos ? (u64) -1 : pos);
}
开发者ID:JamesLinus,项目名称:armips,代码行数:13,代码来源:ExpressionFunctions.cpp


示例15: PARAM_TEST_CASE

PARAM_TEST_CASE(CalcHist, cv::gpu::DeviceInfo, cv::Size)
{
    cv::gpu::DeviceInfo devInfo;

    cv::Size size;

    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        size = GET_PARAM(1);

        cv::gpu::setDevice(devInfo.deviceID());
    }
开发者ID:jayrambhia,项目名称:opencv,代码行数:13,代码来源:test_imgproc.cpp


示例16: PARAM_TEST_CASE

PARAM_TEST_CASE(Integral, cv::gpu::DeviceInfo, cv::Size, UseRoi)
{
    cv::gpu::DeviceInfo devInfo;
    cv::Size size;
    bool useRoi;

    virtual void SetUp()
    {
        devInfo = GET_PARAM(0);
        size = GET_PARAM(1);
        useRoi = GET_PARAM(2);

        cv::gpu::setDevice(devInfo.deviceID());
    }
开发者ID:4auka,项目名称:opencv,代码行数:14,代码来源:test_imgproc.cpp



注:本文中的GET_PARAM函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ GET_PKT_DATA函数代码示例发布时间:2022-05-30
下一篇:
C++ GET_PAD_FROM_NET_DEV函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap