Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(amfenc): stop busy waiting for encoder output #350

Merged
merged 1 commit into from
Sep 2, 2024

Conversation

cgutman
Copy link
Contributor

@cgutman cgutman commented Sep 2, 2024

Description

This adds a patch to use the AMF QUERY_OUTPUT encoder feature to avoid busy looping while waiting for encoder output.

According to my testing with the EncoderLatency sample in the AMF repository, this has no impact to output latency (avg/min/max encoding time in milliseconds):

  • OneInOne algorithm, AMF_VIDEO_ENCODER_QUERY_TIMEOUT=0, no sleep in AMF_REPEAT case (equivalent to Sunshine today): 1.76/1.47/3.76
  • OneInOne algorithm, AMF_VIDEO_ENCODER_QUERY_TIMEOUT=50, no sleep in AMF_REPEAT case (equivalent to this PR): 1.74/1.48/3.76

Screenshot

Issues Fixed or Closed

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

@ReenigneArcher ReenigneArcher enabled auto-merge (squash) September 2, 2024 23:43
@ReenigneArcher ReenigneArcher merged commit a65a35b into LizardByte:master Sep 2, 2024
12 checks passed
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