18 #ifndef AUDIO_EVENT_REGISTER_HPP
19 #define AUDIO_EVENT_REGISTER_HPP
23 #include <boost/make_shared.hpp>
24 #include <boost/shared_ptr.hpp>
25 #include <boost/thread/mutex.hpp>
26 #include <boost/enable_shared_from_this.hpp>
28 #include <qi/session.hpp>
31 #include <naoqi_bridge_msgs/AudioBuffer.h>
37 #include "../src/converters/audio.hpp"
39 #include "../src/publishers/basic.hpp"
41 #include "../recorder/basic_event.hpp"
62 AudioEventRegister(
const std::string& name,
const float& frequency,
const qi::SessionPtr& session );
66 void resetRecorder( boost::shared_ptr<naoqi::recorder::GlobalRecorder> gr );
78 void processRemote(
int nbOfChannels,
int samplesByChannel, qi::AnyValue altimestamp, qi::AnyValue buffer);
86 boost::shared_ptr<converter::AudioEventConverter>
converter_;
87 boost::shared_ptr<publisher::BasicPublisher<naoqi_bridge_msgs::AudioBuffer> >
publisher_;
88 boost::shared_ptr<recorder::BasicEventRecorder<naoqi_bridge_msgs::AudioBuffer> >
recorder_;
unsigned int serviceId
Definition: audio.hpp:95
AudioEventRegister()
Constructor for recorder interface.
Definition: audio.cpp:35
bool isStarted_
Definition: audio.hpp:99
std::vector< uint8_t > channelMap
Definition: audio.hpp:94
void writeDump(const ros::Time &time)
Definition: audio.cpp:124
qi::FutureSync< qi::AnyObject > p_audio_extractor_request
Definition: audio.hpp:93
void stopProcess()
Definition: audio.cpp:109
void startProcess()
Definition: audio.cpp:87
void isRecording(bool state)
Definition: audio.cpp:137
QI_REGISTER_OBJECT(Driver, _whoIsYourDaddy, minidump, minidumpConverters, setBufferDuration, getBufferDuration, startPublishing, stopPublishing, getMasterURI, setMasterURI, setMasterURINet, getAvailableConverters, getSubscribedPublishers, addMemoryConverters, registerMemoryConverter, registerEventConverter, getFilesList, removeAllFiles, removeFiles, startRecording, startRecordingConverters, stopRecording, startLogging, stopLogging)
qi::AnyObject p_robot_model_
Definition: audio.hpp:92
void resetPublisher(ros::NodeHandle &nh)
Definition: audio.cpp:77
bool isPublishing_
Definition: audio.hpp:100
void processRemote(int nbOfChannels, int samplesByChannel, qi::AnyValue altimestamp, qi::AnyValue buffer)
Definition: audio.cpp:163
qi::SessionPtr session_
Definition: audio.hpp:90
void resetRecorder(boost::shared_ptr< naoqi::recorder::GlobalRecorder > gr)
Definition: audio.cpp:82
qi::AnyObject p_audio_
Definition: audio.hpp:91
bool isRecording_
Definition: audio.hpp:101
~AudioEventRegister()
Definition: audio.cpp:72
boost::shared_ptr< publisher::BasicPublisher< naoqi_bridge_msgs::AudioBuffer > > publisher_
Definition: audio.hpp:87
void isDumping(bool state)
Definition: audio.cpp:149
void isPublishing(bool state)
Definition: audio.cpp:143
GlobalRecorder concept interface.
Definition: audio.hpp:53
bool isDumping_
Definition: audio.hpp:102
boost::shared_ptr< converter::AudioEventConverter > converter_
Definition: audio.hpp:86
boost::mutex mutex_
Definition: audio.hpp:97
void unregisterCallback()
Definition: audio.cpp:159
void setBufferDuration(float duration)
Definition: audio.cpp:132
boost::shared_ptr< recorder::BasicEventRecorder< naoqi_bridge_msgs::AudioBuffer > > recorder_
Definition: audio.hpp:88
void registerCallback()
Definition: audio.cpp:155