-
Notifications
You must be signed in to change notification settings - Fork 28
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
minor issue: granulepos of the last packet of the cut segment (vcut.c) #25
Comments
[Alpt]
I believe the following patch should be applied in
process_audio_packet:
Can you tell us why you believe so, and is there a test case to detect
the problem it solves?
…--
Vennlig hilsen
Petter Reinholdtsen
|
In line 456, packet->granule_pos is calculated as follow:
Instead, in line 426, it is rel_cutpoint, which is calculated as
(this if segment->cuttime >= 0) What I am trying to say is that both in 426 and 456 (granulepos - initial_granpos) is considered, but in 456 also vs->samples_cut is considered. The problem to be observed should be that the last granulepos of the cut segment is wrong if vs->samples_cut is greater than 0. I am working on a fork of vcut and I was observing this. I solved it with the mentioned patch. Best regards. |
Ok, I don't know if it happens in other cases, e.g. chained streams, but it surely happens if you perform more than one cut. To perform more than one cut, set segment->next to another valid vcut_segment. See master...Alpt:pof-ok Here is the output of running the PoC
Moreover, this issue creates gaps when concatenating the segments. By applying, the patch mentioned above in this issue, all these problems are solved.
|
I believe the following patch should be applied in process_audio_packet:
line 426 of vcut.c, commit 70d0d8e
The text was updated successfully, but these errors were encountered: