Skip to content

Conversation

@IanVzs
Copy link

@IanVzs IanVzs commented Aug 30, 2022

OS: Ubuntu 22.04
Qt: 5.12.12
cmake version 3.22.1

build error:
[ 40%] Building CXX object QtScrcpy/QtScrcpyCore/CMakeFiles/QtScrcpyCore.dir/src/device/decoder/videobuffer.cpp.o
In file included from /home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.cpp:1:
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.h:38:33: error: ‘std::function’ has not been declared
38 | void peekRenderedFrame(std::function<void(int width, int height, uint8_t* dataRGB32)> onFrame);
| ^~~~~~~~
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.h:38:41: error: expected ‘,’ or ‘...’ before ‘<’ token
38 | void peekRenderedFrame(std::function<void(int width, int height, uint8_t* dataRGB32)> onFrame);
| ^
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.cpp:110:6: error: variable or field ‘peekRenderedFrame’ declared void
110 | void VideoBuffer::peekRenderedFrame(std::function<void(int width, int height, uint8_t* dataRGB32)> onFrame)
| ^~~~~~~~~~~
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.cpp:110:42: error: ‘function’ is not a member of ‘std’
110 | void VideoBuffer::peekRenderedFrame(std::function<void(int width, int height, uint8_t* dataRGB32)> onFrame)
| ^~~~~~~~
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.cpp:8:1: note: ‘std::function’ is defined in header ‘’; did you forget to ‘#include ’?
7 | #include "libavutil/imgutils.h"
+++ |+#include
8 | }
/home/ian/Desktop/QtScrcpy/QtScrcpy/QtScrcpyCore/src/device/decoder/videobuffer.cpp:110:97: error: expression list treated as compound expression in functional cast [-fpermissive]

@re2zero
Copy link
Contributor

re2zero commented Sep 13, 2022

I think this is same build issue with #4 , the root cause is the header 'function1' did not be included.

@barry-ran barry-ran closed this Sep 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants