shared_ptr<RemoteHandler> ButtonRemoteFactory:: operator()(common::OriginalSource const &source, common::InterfaceList &ifaces, common::ClientContext &) { shared_ptr<RemoteHandler> ret; if (source.hasTransform()) { OSVR_DEV_VERBOSE( "Ignoring transform found on route for Button data!"); } auto const &devElt = source.getDeviceElement(); /// @todo find out why make_shared causes a crash here ret.reset(new VRPNButtonHandler(m_conns.getConnection(devElt), devElt.getFullDeviceName().c_str(), source.getSensorNumber(), ifaces)); return ret; }
shared_ptr<RemoteHandler> ImagingRemoteFactory:: operator()(common::OriginalSource const &source, common::InterfaceList &ifaces, common::ClientContext &) { shared_ptr<RemoteHandler> ret; if (source.hasTransform()) { OSVR_DEV_VERBOSE( "Ignoring transform found on route for Imaging data!"); } /// @todo This is where we'd take a different path for IPC imaging data. auto const &devElt = source.getDeviceElement(); /// @todo find out why make_shared causes a crash here ret.reset(new NetworkImagingRemoteHandler( m_conns.getConnection(devElt), devElt.getFullDeviceName(), source.getSensorNumberAsChannelCount(), ifaces)); return ret; }