fix(src): if camera is s1030, the frame rate is not show.

This commit is contained in:
Osenberg 2019-08-02 14:59:50 +08:00
parent 404d74b0b7
commit de6dc0d712
2 changed files with 9 additions and 4 deletions

View File

@ -61,8 +61,8 @@ const std::map<Model, std::map<Capabilities, StreamRequests>>
stream_requests_map = { stream_requests_map = {
{Model::STANDARD, {Model::STANDARD,
{{Capabilities::STEREO, { {{Capabilities::STEREO, {
{752, 480, Format::YUYV, 60}, {752, 480, Format::YUYV, 0},
{376, 240, Format::YUYV, 60}} {376, 240, Format::YUYV, 0}}
}} }}
}, },
{Model::STANDARD2, {Model::STANDARD2,

View File

@ -188,8 +188,13 @@ std::size_t bytes_per_pixel(const Format &value) {
} }
std::ostream &operator<<(std::ostream &os, const StreamRequest &request) { std::ostream &operator<<(std::ostream &os, const StreamRequest &request) {
if (request.fps == 0) {
return os << "width: " << request.width << ", height: " << request.height
<< ", format: " << request.format;
} else {
return os << "width: " << request.width << ", height: " << request.height return os << "width: " << request.width << ", height: " << request.height
<< ", format: " << request.format << ", fps: " << request.fps; << ", format: " << request.format << ", fps: " << request.fps;
}
} }
const char *to_string(const CalibrationModel &model) { const char *to_string(const CalibrationModel &model) {