Skip to content

Commit 439db95

Browse files
authored
Update mv_cam.cpp
#12 默认加入打印。方便查看当前相机问题
1 parent b757b8c commit 439db95

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

example/GigeCam/mv_cam.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,12 +192,12 @@ void MvCam::Receive(void *handle, const std::string &name) {
192192
}
193193
// 这里的time_stamp_us是相机触发时间,需要加上曝光时间的一半,以获得相机拍摄的时间
194194
if (params.find(name) == params.end()) {
195-
LOG(ERROR) << "cam " << name << " not found!";
195+
LOG(ERROR) << "cam: " << name << " not found!";
196196
} else {
197197
if (uint64_t time; GET_LAST_TRIGGER_STATUS(params[name], time)) {
198198
cam_data.time_stamp_us = time + static_cast<uint64_t>(expose_time.fCurValue / 2.);
199199
} else {
200-
LOG(ERROR) << "cam " << name << " not found!";
200+
LOG(ERROR) << "Trigger cam: " << name << " not found!";
201201
}
202202
}
203203
MvGvspPixelType en_dst_pixel_type = PixelType_Gvsp_Undefined;
@@ -259,8 +259,11 @@ void MvCam::Start() {
259259
name = "cam_" + std::to_string(cam_index++);
260260
LOG(WARNING) << "Camera name is empty,Create new name: " << name;
261261
}
262+
else {
263+
LOG(INFO) << "Camera name is " << name;
264+
}
262265
cam_threads.emplace_back(&MvCam::Receive, this, handle, name);
263266
LOG(INFO) << "Camera name is " << name << " start.";
264267
}
265268
}
266-
} // namespace infinite_sense
269+
} // namespace infinite_sense

0 commit comments

Comments
 (0)