-
-
Notifications
You must be signed in to change notification settings - Fork 21.6k
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
Audio track key end_offset
does not work when it exists outside the animation length
#75197
Comments
Is there a workaround for this without clipping the audio file to the length of the animation? I tried setting the |
End Offset
when animation is looping.End Offset
when animation is looping.
The audio track is basically the key that fires playback and is not trimmed by the animation length. This is the intended behavior. The bug I can tell here is that the EndOffset outside of the animation length is ignored. This is odd, I'll send a PR to fix it later. |
End Offset
when animation is looping.end_offset
does not work when it exists outside the animation length
@TokageItLab A reminder that you wanted to fix this :) |
@TokageItLab |
See above comment
At least, I think ignored offset issue is solved in 4.2 beta, but still there? If so please send MRP. |
If the sound not stopping at the end of the animation is the intended behavior How do I prevent my looping animation audio from overlapping with itself then? And the audio would be cut by the animation length for looping animations in 3.X so why the design change? |
Now the end offset is available if the fix is done correctly, so it might be sufficient you just setting the end offset for all looping animations. For example, there is an animation contain jumping and the last frame landing with sound fx, if you loop and force trim that sound, the landing sound is not played correctly, so trimming shouldn’t be there at least as default. However, AudioPlaybackTrack generally allows to play only 1 sound per 1 track in the same time, so I guess your issue is "previous sound is not stopped when next key is played after looping" not "AudioPlaybackTrack is not trimmed by animation length"; it is another issue from "there is no way to trim audio outside of animation length / end offset is not working correctly", so if you can reproduce it with multiple sounds/keys, please send again it(previous sound is not stopped when next key is played after looping) as new issue. |
Basically it's practically impossible to set the end offset to the very end of the animation length The I guess I'll post "previous sound is not stopped when next key is played after looping" because the AudioStreamPlayer3D shouldn't be able to play multiple sounds at the same time when |
For about that, you can use inspector. |
I actually have to subtract the animation length from the sound length to get the value
But even then it's finnicky and needs adjustment or else it allows audio gaps on the loop. |
I guess the only improvement that could be made for that would be the addition of a snap. If the snap is not effective currently, so you can send another issue. Alternatively, we could add the feature to set the offset to the current timeline position and assign shortcut to the In any case, these topics are off topic here since it is usability issue, not |
Godot version
4.0
System information
Windows 10
Issue description
The
Audio Playback Track
in anAnimation
can only stop the sound at itsEnd Offset
on the first loop, then it fails to do so for every loop after the first:The sound begins overlapping with itself as seen in the top right:
![sound looping](https://user-images.githubusercontent.com/34152090/226741982-3883b08b-cd4f-4413-9e5b-0be747e69951.gif)
Steps to reproduce
AudioStreamPlayer3D
and anAnimationPlayer
in your scene.Audio Playback Track
to it that is connected to theAudioStreamPlayer3D
End Offset
)Minimal reproduction project
N/A
The text was updated successfully, but these errors were encountered: