您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ stopRecording函数代码示例

51自学网 2021-06-03 08:24:10
  C++
这篇教程C++ stopRecording函数代码示例写得很实用,希望能帮到您。

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

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

示例1: stopRecording

xncv::VideoSource::~VideoSource(){	stopRecording();	imgGen.Release();	depthGen.Release();	player.Release();}
开发者ID:ViniGodoy,项目名称:xncv,代码行数:7,


示例2: switch

bool KeySequenceWidget::event(QEvent* event){	if (status() == Recording)	{		switch(event->type())		{			case QEvent::KeyPress:				keyPressEvent(static_cast<QKeyEvent*>(event));				return true;			case QEvent::MouseButtonRelease:				event->accept();				return true;			case QEvent::ShortcutOverride:				event->accept();				return true;			case QEvent::FocusOut:				stopRecording();				if (!valid())				{					keySequence() = backupSequence();					updateOutput();				}				break;			default:				break;		}	}	return QPushButton::event(event);}
开发者ID:335,项目名称:synergy,代码行数:34,


示例3: ROS_ERROR

bool TaskRecorderManagerClient::stopRecording(const ros::Time& start_time,                                              const std::vector<std::string>& message_names,                                              std::vector<task_recorder2_msgs::DataSample>& messages,                                              const bool stop_recording){  bool is_recording;  ros::Time first;  ros::Time last;  double sampling_rate;  if(!getInfo(is_recording, first, last, sampling_rate))  {    ROS_ERROR("Could not stop recording.");    return false;  }  if(!is_recording)  {    ROS_ERROR("Task recorders are not recording, cannot stop.");    return false;  }  if(start_time < first)  {    ROS_ERROR("Requested start time >%f< is invalid. First recorded sample has time stamp is >%f<.", start_time.toSec(), first.toSec());    return false;  }  ros::Duration duration = last - start_time;  const int num_samples = static_cast<int>(duration.toSec() * sampling_rate);  ROS_INFO("Recorded >%f< seconds and asking for >%i< samples.", duration.toSec(), num_samples);  return stopRecording(start_time, last, num_samples, message_names, messages, stop_recording);}
开发者ID:HiroyukiMikita,项目名称:usc-clmc-ros-pkg,代码行数:29,


示例4: stopRecording

void RecorderSlaveBlock::eachFrame() {    if (m_recording) {        // recording        if (m_linkNode->getValue() < LuminosusConstants::triggerThreshold) {            stopRecording();            return;        }        double value = m_inputNode->getValue();        m_data.append(value);        m_outputNode->setValue(value);        emit dataChanged();        return;    }    if (m_playing && !m_data.isEmpty()) {        // playing        double value = m_data[m_playbackPosition % m_data.size()];        m_outputNode->setValue(value);        // either progress frame or stop:        if (m_playbackPosition + 1 >= m_data.size() || m_linkNode->getValue() < LuminosusConstants::triggerThreshold) {            m_playing.setValue(false);            m_playbackPosition = 0;            emit playbackPositionChanged();        } else {            m_playbackPosition = (m_playbackPosition + 1) % m_data.size();            emit playbackPositionChanged();        }    }}
开发者ID:ElectronicTheatreControlsLabs,项目名称:LuminosusEosEdition,代码行数:31,


示例5: stopRecording

void LoopLayer::toggleRecording(uint64_t clockFrame){  if (recording) {    stopRecording(clockFrame);  } else {    startRecording(clockFrame);  }}
开发者ID:acarabott,项目名称:bela-looper,代码行数:8,


示例6: recordMess

/////////////////////////////////////////////////////////// recordMess///////////////////////////////////////////////////////////void pix_record :: recordMess(bool on){  if (on) {    startRecording();  }else{    stopRecording();  }}
开发者ID:kmatheussen,项目名称:libpd,代码行数:12,


示例7: stopRecording

void VideoRecorder::videoDurationChanged(qint64 duration){    if (!shouldContinueRecording(duration)) {        stopRecording();    }    m_duration = duration/1000;    emit durationChanged();}
开发者ID:shivarajsp77,项目名称:bachchao-qtapp,代码行数:8,


示例8: stopRecording

// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -EventStreamer::~EventStreamer(){  stopRecording();  myEventHistory.clear();  myStreamReader.close();  myStreamWriter.close();}
开发者ID:kerheol,项目名称:dingux-2600,代码行数:9,


示例9: processEvent

int processEvent(GameEvent* e) {  int value = 0;  Data *data;  if(game2->mode == GAME_SINGLE_RECORD) {    writeEvent(e);  }  switch(e->type) {  case EVENT_TURN_LEFT:    data = game->player[e->player].data;    if(data->speed > 0) {      data->iposx = e->x;      data->iposy = e->y;      data->turn = TURN_LEFT;      doTurn(data, e->timestamp);    }    break;  case EVENT_TURN_RIGHT:    data = game->player[e->player].data;    if(data->speed > 0) {      data->iposx = e->x;      data->iposy = e->y;      data->turn = TURN_RIGHT;      doTurn(data, e->timestamp);    }    break;  case EVENT_CRASH:     data = game->player[e->player].data;    data->posx = data->iposx = e->x;    data->posy = data->iposy = e->y;    sprintf(messages, "player %d crashed", e->player + 1);    fprintf(stderr, "%s/n", messages);    consoleAddLine(messages);    crashPlayer(e->player);    break;  case EVENT_STOP:    fprintf(stderr, "game stopped/n");    if(game2->mode == GAME_SINGLE_RECORD) {      stopRecording();      game2->mode = GAME_SINGLE;    } else if(game2->mode == GAME_PLAY) {      stopPlaying();      game2->mode = GAME_SINGLE;    }    game->winner = e->player;    sprintf(messages, "winner: %d", game->winner + 1);    printf("%s/n", messages);    consoleAddLine(messages);    switchCallbacks(&pauseCallbacks);    /* screenSaverCheck(0); */    stoptime = SystemGetElapsedTime();    game->pauseflag = PAUSE_GAME_FINISHED;    value = 1;    break;  }  free(e);  return value;}
开发者ID:BackupTheBerlios,项目名称:gltron-svn,代码行数:58,


示例10: folderPath

std::string Driver::minidump(const std::string& prefix){  if (!log_enabled_)  {    const std::string& err = "Log is not enabled, please enable logging before calling minidump";    std::cout << BOLDRED << err << std::endl              << RESETCOLOR << std::endl;    return err;  }  // CHECK SIZE IN FOLDER  long files_size = 0;  boost::filesystem::path folderPath(boost::filesystem::current_path());  helpers::filesystem::getFilesSize(folderPath, files_size);  if (files_size > helpers::filesystem::folderMaximumSize)  {    std::cout << BOLDRED << "No more space on robot. You need to upload the presents bags and remove them to make new ones."                 << std::endl << "To remove all the presents bags, you can run this command:" << std::endl                    << "/t$ qicli call ROS-Driver.removeFiles" << RESETCOLOR << std::endl;    return "No more space on robot. You need to upload the presents bags and remove them to make new ones.";  }  // IF A ROSBAG WAS OPENED, FIRST CLOSE IT  if (record_enabled_)  {    stopRecording();  }  // STOP BUFFERIZING  log_enabled_ = false;  for(EventIter iterator = event_map_.begin(); iterator != event_map_.end(); iterator++)  {    iterator->second.isDumping(true);  }  ros::Time time = ros::Time::now();  // START A NEW ROSBAG  boost::mutex::scoped_lock lock_record( mutex_record_ );  recorder_->startRecord(prefix);  // WRITE ALL BUFFER INTO THE ROSBAG  for(EventIter iterator = event_map_.begin(); iterator != event_map_.end(); iterator++)  {    iterator->second.writeDump(time);  }  for(RecIter iterator = rec_map_.begin(); iterator != rec_map_.end(); iterator++)  {    iterator->second.writeDump(time);  }  // RESTART BUFFERIZING  log_enabled_ = true;  for(EventIter iterator = event_map_.begin(); iterator != event_map_.end(); iterator++)  {    iterator->second.isDumping(false);  }  return recorder_->stopRecord(::naoqi::ros_env::getROSIP("eth0"));}
开发者ID:antegallya,项目名称:naoqi_driver,代码行数:58,


示例11: kommuHandler

void kommuHandler(void){	int i;	while(buildCommand(input_buf,command)){		switch(command[0]){		case 'a':			if(kommuConnected){				sendCommand("a",1);				kommuNoPing = 0;			}			break;		case 'b':			sendCommand("c",1);			kommuConnected = 1;			kommuNoPing = 0;			HAL_GPIO_WritePin(GPIOD,GPIO_PIN_12,GPIO_PIN_SET);			break;		case 's':			stopRecording(command[1]);			break;		case 'r':			if(kommuConnected){				startRecording(command[1]);			}			break;		case 'q':			stopRecordingAll();			break;		case 'x':			if(kommuConnected){				changeValue(command+1);			}			break;		}			}	if(kommuConnected){		for(i = 0; i < sendingCodesCurrent; i++){			sendCode(sendingCodes[i],buffer);		}	}	if(kommuNoPing > maxPingsMissed){ //Max ping loss?		kommuConnected = 0;		HAL_GPIO_WritePin(GPIOD,GPIO_PIN_12,GPIO_PIN_RESET);	}else{		kommuNoPing++;	}	if((output_currentPos>0) && !ptrUSART->GetStatus().tx_busy){		ptrUSART->Send(output_currentBuffer,output_currentPos);		if(output_currentBufferNr == 1){			output_currentBuffer = output_buffer2;			output_currentBufferNr = 2;		}else{			output_currentBuffer = output_buffer1;			output_currentBufferNr = 1;		}		output_currentPos = 0;	}}
开发者ID:RageFlo,项目名称:testImport1,代码行数:58,


示例12: startRecording

void Display::OnChange(int id){CString bmesg;	if(cbox->GetCount()<=0)	return;		if(id==IDC_RADIO1 && radio1->GetCheck())    //Send to client	{		cbox->EnableWindow(TRUE);				if(cbox->GetCount()>=1)		{		curuser.Empty();		cbox->GetLBText(cbox->GetCurSel(),curuser);		log.WriteString("/nConnected to user "+curuser);		selectflag=1;		startRecording();		}		else		{		curuser.Empty();		selectflag=0;		stopRecording();		 //stopPlaying();         //****** REMOVED ******//		}		}		if(id==IDC_RADIO2 && radio2->GetCheck())				//Send to All 	{		curuser="ALL";	if(isstart==0)    //Stop the record and play 	OnStop();		log.WriteString("/n Broadcasting message");		Broadcast bd(IDD_DIALOG5,this);	bd.DoModal();	bmesg="OVER:";	selectflag=1;			if(sockclt.Send(bmesg,bmesg.GetLength()))	log.WriteString("/n Over Mesg sent to Server");	else	log.WriteString("/n Unable to send over mesg to Server");		curuser.Empty();	radio1->SetCheck(1);	radio2->SetCheck(0);				}}
开发者ID:Erls-Corporation,项目名称:VoiceChatWindows,代码行数:58,


示例13: stopRecording

bool ASimModeBase::toggleRecording(){    if (isRecording())        stopRecording();    else        startRecording();    return isRecording();}
开发者ID:abhay-agarwal,项目名称:AirSim,代码行数:9,


示例14: startRecording

void DemodulatorInstance::setRecording(bool recording_in){    if (recording_in) {        startRecording();    }    else {        stopRecording();    }}
开发者ID:Dantali0n,项目名称:CubicSDR,代码行数:9,


示例15: stopRecording

void RecordingManager::slotToggleRecording(double v) {    if (v > 0) {        if (isRecordingActive()) {            stopRecording();        } else {            startRecording();        }    }}
开发者ID:AlbanBedel,项目名称:mixxx,代码行数:9,


示例16: stateToString

void MediaRecorder::stop(ExceptionState& exceptionState){    if (m_state == State::Inactive) {        exceptionState.throwDOMException(InvalidStateError, "The MediaRecorder's state is '" + stateToString(m_state) + "'.");        return;    }    stopRecording();}
开发者ID:joone,项目名称:chromium-crosswalk,代码行数:9,


示例17: stopRecording

bool TaskRecorderManagerClient::stopRecording(const ros::Time& start_time,                                              const ros::Time& end_time,                                              const int num_samples,                                              std::vector<task_recorder2_msgs::DataSample>& messages,                                              const bool stop_recording){  std::vector<std::string> no_message_names;  return stopRecording(start_time, end_time, num_samples, no_message_names, messages, stop_recording);}
开发者ID:HiroyukiMikita,项目名称:usc-clmc-ros-pkg,代码行数:9,


示例18: stopRecording

void RecordBox::buttonRelease(u16 button){    if((button & KEY_A) && recording)    {        stopRecording();#ifdef DEBUG        printf("it worked 2/n");#endif    }}
开发者ID:fincs,项目名称:NitroTracker-FeOS,代码行数:10,


示例19: stopRecording

void testApp::startPlayback() {	stopRecording();	kinect.close();		// set record file and source	kinectPlayer.setup(ofToDataPath("recording.dat"), true);	kinectPlayer.loop();	kinectSource = &kinectPlayer;	playback = true;}
开发者ID:DeRaafMedia,项目名称:ProjectIrrationalMondriaan,代码行数:10,


示例20: processEvent

static void processEvent(SDL_Event* e, InputContext* inputState, PlatformState* state) {    ControllerInput* keyboardController = getContoller(inputState, 0);    switch (e->type) {        case SDL_QUIT:            state->running = false;            break;        case SDL_WINDOWEVENT:            processWindowEvent(&e->window);            break;        case SDL_KEYDOWN:        case SDL_KEYUP:            bool isDown = e->key.state == SDL_PRESSED;            isDown &= e->key.state != SDL_RELEASED;            if(e->key.repeat == 0) {                switch(e->key.keysym.sym) {                    case SDLK_w:                        processKeyPress(&keyboardController->directionUp, isDown);                        break;                    case SDLK_s:                        processKeyPress(&keyboardController->directionDown, isDown);                        break;                    case SDLK_a:                        processKeyPress(&keyboardController->directionLeft, isDown);                        break;                    case SDLK_d:                        processKeyPress(&keyboardController->directionRight, isDown);                        break;                    case SDLK_l: //start/stop recording                        if(isDown && !state->isPlayingBack) {                            if(state->isRecording) {                                stopRecording(state);                            }                            else {                                beginRecording(state);                            }                        }                        break;                    case SDLK_p: //start/stop playback                        if(isDown && !state->isRecording) {                            if(state->isPlayingBack) {                                stopPlayback(state);                                *inputState = {};                            }                            else {                                beginPlayback(state);                            }                        }                        break;                }            }            break;    }}
开发者ID:DanB91,项目名称:SDLHero,代码行数:55,


示例21: stopRecording

void KeySequenceWidget::keyPressEvent(QKeyEvent* event){	event->accept();	if (status() == Stopped)		return;	if (m_KeySequence.appendKey(event->key(), event->modifiers()))		stopRecording();	updateOutput();}
开发者ID:335,项目名称:synergy,代码行数:12,


示例22: debug

Call::~Call() {	debug(QString("Call %1: Call object destructed").arg(id));	if (isRecording)		stopRecording();	delete confirmation;	setStatus("UNKNOWN");	// QT takes care of deleting servers and sockets}
开发者ID:curtiszimmerman,项目名称:skype-call-recorder,代码行数:12,


示例23: stopRecording

void QOpenSLESAudioInput::stop(){    if (m_deviceState == QAudio::StoppedState)        return;    m_deviceState = QAudio::StoppedState;    stopRecording();    m_errorState = QAudio::NoError;    Q_EMIT stateChanged(m_deviceState);}
开发者ID:xjohncz,项目名称:qt5,代码行数:12,


示例24: while

void DccVoiceThread::run(){#ifndef COMPILE_DISABLE_DCC_VOICE    for(;;)    {//		m_uSleepTime = 0;        // Dequeue events        while(KviThreadEvent * e = dequeueEvent())        {            if(e->id() == KVI_THREAD_EVENT_TERMINATE)            {                delete e;                goto exit_dcc;            } else if(e->id() == KVI_DCC_THREAD_EVENT_ACTION)            {                int * act = ((KviThreadDataEvent<int> *)e)->getData();                if(*act)startRecording();                else stopRecording();                delete act;                delete e;            } else {                // Other events are senseless to us                delete e;            }        }        if(!readWriteStep())goto exit_dcc;        if(!soundStep())goto exit_dcc;        m_pInfoMutex->lock();        m_iInputBufferSize = m_inSignalBuffer.size();        m_iOutputBufferSize = (m_outFrameBuffer.size() / m_pOpt->pCodec->encodedFrameSize()) * m_pOpt->pCodec->decodedFrameSize();        m_pInfoMutex->unlock();        // Actually the maximum that we can sleep here is        // around 500 usecs... = 0.0005 sec -> 8 bytes at 8 KHz        //	if(m_uSleepTime)usleep(m_uSleepTime);        // Start recording if the request was not fulfilled yet        if(m_bRecordingRequestPending)startRecording();    }exit_dcc:#endif //! COMPILE_DISABLE_DCC_VOICE    closeSoundcard();    kvi_socket_close(m_fd);    m_fd = KVI_INVALID_SOCKET;}
开发者ID:xeddmc,项目名称:KVIrc,代码行数:52,


示例25: env

void RecordingMode::deactivate() {	DebugL << "Deactivating" << endl;	try {		_isActive = false;		env().media().RecordingStopped.detach(this);		if (isRecording())			stopRecording();	}	catch (std::exception& exc) {		ErrorL << "Deactivation error: " + std::string(exc.what()) << endl;	}}
开发者ID:anionu,项目名称:anionu-sdk,代码行数:13,


示例26: stopRecording

bool PulseSensor::deinit(){	if( ! mSensor )		return false;	stopRecording();	mDeviceName = NO_DEVICE;	mCardioid.clear();	delete mSensor;	mSensor = 0;	return true;}
开发者ID:bgbotond,项目名称:Cinder-PulseSensor,代码行数:14,


示例27: qDebug

void SSBMessageDialog::recButtons(int id){    int nr=id-1;    // if this msg was already recording, stop    if (nowRecording==id) {        recGroup.button(nowRecording)->setChecked(false);        nowRecording=0;        qDebug("id=%d finished",id);        emit(stopRecording(nr));    } else if (nowRecording) {        // some other was recording-cancel it        qDebug("cancelling %d",nowRecording);        emit(stopRecording(nowRecording-1));        recGroup.button(nowRecording)->setChecked(false);        nowRecording=id;        emit(startRecording(nr));    } else {        qDebug("starting id=%d",id);        nowRecording=id;        emit(startRecording(nr));    }    qDebug(" ");}
开发者ID:no3m,项目名称:so2sdr,代码行数:23,


示例28: startRecording

void KeySequenceWidget::mousePressEvent(QMouseEvent* event){	event->accept();	if (status() == Stopped)	{		startRecording();		return;	}	if (m_KeySequence.appendMouseButton(event->button()))		stopRecording();	updateOutput();}
开发者ID:335,项目名称:synergy,代码行数:15,



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


C++ stopServer函数代码示例
C++ stopPoolMining函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。