post all desktop capturer apis to worker threads
This commit is contained in:
parent
6c604e1eb3
commit
5a28759fea
2 changed files with 67 additions and 34 deletions
|
@ -34,6 +34,11 @@ class DesktopCapturer : public mate::EventEmitter<DesktopCapturer>,
|
|||
bool capture_screen,
|
||||
const gfx::Size& thumbnail_size);
|
||||
|
||||
std::unique_ptr<DesktopMediaList> media_list_;
|
||||
#if defined(OS_WIN)
|
||||
bool using_directx_capturer_;
|
||||
#endif // defined(OS_WIN)
|
||||
|
||||
protected:
|
||||
explicit DesktopCapturer(v8::Isolate* isolate);
|
||||
~DesktopCapturer() override;
|
||||
|
@ -47,10 +52,7 @@ class DesktopCapturer : public mate::EventEmitter<DesktopCapturer>,
|
|||
bool OnRefreshFinished() override;
|
||||
|
||||
private:
|
||||
std::unique_ptr<DesktopMediaList> media_list_;
|
||||
#if defined(OS_WIN)
|
||||
bool using_directx_capturer_;
|
||||
#endif // defined(OS_WIN)
|
||||
scoped_refptr<base::SequencedTaskRunner> capture_thread_;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(DesktopCapturer);
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue