mirror of
https://github.com/kunkundi/crossdesk.git
synced 2026-07-03 04:21:34 +08:00
[feat] add Linux screen capture fallback support for DRM and Wayland
This commit is contained in:
@@ -17,6 +17,7 @@ struct _XImage;
|
||||
typedef struct _XImage XImage;
|
||||
|
||||
#include <atomic>
|
||||
#include <cctype>
|
||||
#include <cstring>
|
||||
#include <functional>
|
||||
#include <iostream>
|
||||
@@ -50,6 +51,7 @@ class ScreenCapturerX11 : public ScreenCapturer {
|
||||
|
||||
private:
|
||||
void DrawCursor(XImage* image, int x, int y);
|
||||
bool ProbeCapture();
|
||||
|
||||
private:
|
||||
Display* display_ = nullptr;
|
||||
@@ -68,9 +70,10 @@ class ScreenCapturerX11 : public ScreenCapturer {
|
||||
int fps_ = 60;
|
||||
cb_desktop_data callback_;
|
||||
std::vector<DisplayInfo> display_info_list_;
|
||||
int capture_error_count_ = 0;
|
||||
|
||||
std::vector<uint8_t> y_plane_;
|
||||
std::vector<uint8_t> uv_plane_;
|
||||
};
|
||||
} // namespace crossdesk
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user