Skip to content

Stream ogg songs from disk#1023

Merged
Interkarma merged 2 commits intoInterkarma:masterfrom
petchema:stream-ogg-songs
Nov 14, 2018
Merged

Stream ogg songs from disk#1023
Interkarma merged 2 commits intoInterkarma:masterfrom
petchema:stream-ogg-songs

Conversation

@petchema
Copy link
Copy Markdown
Collaborator

MidnightPrince assembled a kickass soundscape for Daggerfall Unity
https://forums.dfworkshop.net/viewtopic.php?f=14&t=1347#p16078

All songs are replaced with OGG music, and there's a noticeable frames drop when songs (re)start.
This patch uses Unity audioClip streaming for digital songs.

MidnightPrince assembled a kickass soundscape for Daggerfall Unity
https://forums.dfworkshop.net/viewtopic.php?f=14&t=1347#p16078

All songs are replaced with OGG music, and there's a noticeable frames
drop when songs (re)start.
This patch uses Unity audioClip streaming for digital songs.
@Midknightprince
Copy link
Copy Markdown

I likey !

/// Import sound data from modding locations as an audio clip.
/// </summary>
private static bool TryImportAudioClip(string name, string extension, out AudioClip audioClip)
private static bool TryImportAudioClip(string name, string extension, out AudioClip audioClip, bool streaming = false)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm ok with this. Just a small note: the convention is to place the out parameter in the last position. I would prefer if you move streaming before it and just pass true and false respectively.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Done. Somehow I was expecting to have more places to update...

@Interkarma Interkarma merged commit dd0b46c into Interkarma:master Nov 14, 2018
@petchema petchema deleted the stream-ogg-songs branch December 23, 2018 08:54
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.

4 participants