[libcamera-devel] [PATCH] qcam: fix Qt5.15.0 compile

Peter Seiderer ps.report at gmx.net
Sun Jun 7 18:56:55 CEST 2020


Fixes:

  ../src/qcam/main_window.cpp:634:16: error: ‘QTextStream& QTextStreamFunctions::fixed(QTextStream&)’ is deprecated: Use Qt::fixed [-Werror=deprecated-declarations]
    634 |   << "fps:" << fixed << qSetRealNumberPrecision(2) << fps;
        |                ^~~~~

Signed-off-by: Peter Seiderer <ps.report at gmx.net>
---
 src/qcam/main_window.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/qcam/main_window.cpp b/src/qcam/main_window.cpp
index 7de0895..1f3bdc1 100644
--- a/src/qcam/main_window.cpp
+++ b/src/qcam/main_window.cpp
@@ -631,7 +631,7 @@ void MainWindow::processViewfinder(FrameBuffer *buffer)
 		<< QString("seq: %1").arg(metadata.sequence, 6, 10, QLatin1Char('0'))
 		<< "bytesused:" << metadata.planes[0].bytesused
 		<< "timestamp:" << metadata.timestamp
-		<< "fps:" << fixed << qSetRealNumberPrecision(2) << fps;
+		<< "fps:" << Qt::fixed << qSetRealNumberPrecision(2) << fps;
 
 	/* Render the frame on the viewfinder. */
 	viewfinder_->render(buffer, &mappedBuffers_[buffer]);
-- 
2.26.2



More information about the libcamera-devel mailing list