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

Resolve Frame Drop Issue in Video Frame Reduction #12

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

raykim2414
Copy link

Summary of the Changes

This PR specifically addresses the frame drop issue encountered during the frame reduction process in FYVideoCompressor. The changes made are:

  1. Improvement in Frame Reduction Logic: The reduce method in ReduceFrameEvenlySpaced has been modified to correctly handle frame indexes, using originalFPS * videoDuration as the loop condition. This effectively prevents frame drops, ensuring that each frame is appropriately processed.

  2. Refinement of Video Compression Settings: The video settings in the createVideoSettingsWithBitrate function have been refined to use targetFPS accurately, ensuring consistent frame rates during video compression.

Testing and Verification

These changes have been rigorously tested with various video files to ensure the frame drop issue is effectively resolved.

Invitation for Review

I would appreciate feedback from the FYVideoCompressor maintainers and contributors on these changes.

1. Updated the `reduce` method in `ReduceFrameEvenlySpaced` to use `originalFPS * videoDuration` for loop condition and index checks, preventing frame drop by ensuring all frames are correctly processed.
2. Altered video compression settings in `createVideoSettingsWithBitrate` to accurately use `targetFPS`, enhancing the frame rate consistency during compression.

These changes collectively resolve the previously observed frame drop issue, ensuring a more reliable and accurate frame reduction in FYVideoCompressor.
Copy link
Contributor

@wzio wzio left a comment

Choose a reason for hiding this comment

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

seem it is good to me

soobeen27 added a commit to soobeen27/FYVideoCompressor that referenced this pull request Sep 10, 2024
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