Skip to content

Conversation

@pavelfeldman
Copy link
Member

No description provided.

+ RetainPtr<CGImageRef> imageRef = m_page.pageClient().takeSnapshotForAutomation();
+ if (m_screencast && m_screencastFramesInFlight <= 1) {
+ auto cfData = adoptCF(CFDataCreateMutable(kCFAllocatorDefault, 0));
+ WebCore::encodeImage(imageRef.get(), CFSTR("public.jpeg"), 0.5, cfData.get());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • 0.5 -> m_screencastQuality?
  • What is this public.jpeg?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Done
  • Don't know

+ if (!m_encoder && !m_screencast)
+ return;
+ RetainPtr<CGImageRef> imageRef = m_page.pageClient().takeSnapshotForAutomation();
+ if (m_screencast && m_screencastFramesInFlight <= 1) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: let's do a named constant for "1" - it is used in multiple places.

@pavelfeldman pavelfeldman merged commit fc9454e into microsoft:master May 4, 2021
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.

2 participants