| | |
| | | VptServerI::VptServerI() {} |
| | | |
| | | VptServerI::~VptServerI() { |
| | | |
| | | for (auto item_ptr : m_map_vptDetectWrapper) { |
| | | if (item_ptr.second != nullptr) { |
| | | delete item_ptr.second; |
| | | item_ptr.second = nullptr; |
| | | } |
| | | m_map_vptDetectWrapper.erase(item_ptr.first); |
| | | } |
| | | } |
| | | |
| | | VptDetect::ObjInfos |
| | | VptServerI::VptDetect(Ice::Int width, Ice::Int height, const ::std::string &shM, |
| | | const ::Ice::Current ¤t) { |
| | | |
| | | thread::id key = std::this_thread::get_id(); |
| | | if (m_map_vptDetectWrapper.find(key) == m_map_vptDetectWrapper.end()) { |
| | | m_map_vptDetectWrapper[key] = new VptDetectWrapper(); |
| | | } |
| | | VptDetectWrapper &m_vptDetectWrapper = *m_map_vptDetectWrapper[key]; |
| | | |
| | | VptDetect::ObjInfos objInfos; |
| | | QSharedMemory shareMemory(QString(shM.c_str())); |
| | | if (shareMemory.attach()) { |