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

Added a dialog tab to easily access the "ABNK" tab #177

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

Conversation

UlysseM
Copy link

@UlysseM UlysseM commented Jan 6, 2023

Additionally, I fixed a bug where audio files (ASND) could only play once, and once played, downloading them would return an empty file.

Additionally, I fixed a bug where audio files (ASND) could only play once, and once played, downloading them would return an empty file.
@UlysseM
Copy link
Author

UlysseM commented Jan 6, 2023

On another note, I noticed that the sound files being downloaded include the "File head" and "chunk head" header (the first few bytes includes something like PF���� �ASNDASND)

mp3 is a fairly resilient format as players will attempt to find a specific magic header in the file and start from there, but it may be nice to clean this up.

I also noticed that some sounds couldn't play, which I assume is due to some compression as I haven't encountered this sound in game (from https://wiki.guildwars2.com/wiki/Gw2.dat).

Do you know if the library provides an easy way to decompress these?

@UlysseM
Copy link
Author

UlysseM commented Jan 7, 2023

One thing that also came to mind is that we could in theory have the renderer extract the data, put it in a blob, generate a URL, and pass that URL to an audio tag. This would add a player with a progress bar and a button to download automatically.

We could even have some "autoplay sound" checkbox.

In order to do this, we'd need some kind of callback to remove the blob URL when another object is loaded, to avoid memory leaks. Do you know if this mechanism already exists ?

@UlysseM
Copy link
Author

UlysseM commented Apr 9, 2023

ping @njibhu ?

@njibhu
Copy link
Owner

njibhu commented Sep 22, 2024

Hello 👋
Thanks for your contribution. I wasn't active on Guildwars2 anymore during the after EoD / SoTO period, which explain the lack of answer/activity.

For your PR, I'd probably extract the two parts (the ASND fix and the ABNK changes) in different two different PRs.

Concerning the question about the sound files, ABNK is I think the only chunk containing a nested PF file. These are like ASND files inside the ABNK file. The current implementation doesn't support parsing nested files, but I wouldn't expect it to be a very difficult change. It must happen inside the library though, I'll check it later.

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