Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use std::cout / cerr instead of QTextStream #10

Merged
merged 1 commit into from
Aug 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions src/CameraModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
#include <TimeLapse/pipeline_write_frame.h>
#include <TimeLapse/pipeline_cpt_qcamera.h>

#include <ostream>
#include <iostream>

CameraModel::CameraModel(QObject *parent):
QAbstractListModel(parent)
{
Expand All @@ -36,10 +39,10 @@ CameraModel::CameraModel(QObject *parent):
if (devices.isEmpty()) {
verboseOutput << QCoreApplication::translate("main", "No compatible capture device found");
} else {
verboseOutput << "Found devices: " << endl;
std::cout << "Found devices: " << std::endl;
for (QSharedPointer<timelapse::CaptureDevice> d : devices) {
connect(d.data(), &timelapse::CaptureDevice::update, this, &CameraModel::onCameraUpdate);
verboseOutput << " " << d->toString() << endl;
std::cout << " " << d->toString().toStdString() << std::endl;
}
}
}
Expand Down Expand Up @@ -115,7 +118,7 @@ QList<QSharedPointer<timelapse::CaptureDevice>> CameraModel::listDevices() {
result.push_back(QSharedPointer<timelapse::Gphoto2Device>(new timelapse::Gphoto2Device(gp2Dev)));
}
} catch (std::exception &e) {
err << "Can't get Gphoto2 devices. " << QString::fromUtf8(e.what()) << endl;
std::cerr << "Can't get Gphoto2 devices. " << e.what() << std::endl;
}

{
Expand Down
Loading