1. timogus

    OP timogus Member
    Newcomer

    Joined:
    Oct 28, 2016
    Messages:
    22
    Country:
    United States
    I made this little tool yesterday. Really nothing special, just repacking the file with a different head + endian.

    https://bitbucket.org/timogus/wav2btsnd

    You need to use RIFF WAVE files, 48000khz, 16bit stereo. You can easily create them with for example audacity
     
    MundoU, AboodXD, CatmanFan and 10 others like this.
  2. NexoCube

    NexoCube stop using piracy :(
    Member

    Joined:
    Nov 3, 2015
    Messages:
    1,220
    Country:
    France
    Have you tested it ?

    Sounds great btw :D
     
  3. timogus

    OP timogus Member
    Newcomer

    Joined:
    Oct 28, 2016
    Messages:
    22
    Country:
    United States
    Yes of course. Why would I release something untested?
     
    iAqua, Mazamin, N28582R and 7 others like this.
  4. NexoCube

    NexoCube stop using piracy :(
    Member

    Joined:
    Nov 3, 2015
    Messages:
    1,220
    Country:
    France
    I don't know :P Wasn't meant to be rude, and thanks :D
     
  5. cathor

    cathor Advanced Member
    Newcomer

    Joined:
    Oct 15, 2016
    Messages:
    77
    Country:
    Thanks , just what i was looking for!

    Trying to run this from osx terimnal. What are the arguments for input/output file? any other options/flags available?

    tried to run
    java -jar wav2btsnd.jar myfile.wav

    myfile.wav is 3 sec / 48000khz / 16bit stereo

    This is what i get
    "You need to provide a 48000khz 16bit steroe .wav as input"

    Cheers,
     
  6. BDS

    BDS GBAtemp Regular
    Member

    Joined:
    Jan 7, 2016
    Messages:
    179
    Country:
    France
    For anyone wondering about btsnd's and loops, afaik they all loop from their loop start value to the end of the stream. The loop start value is the 32bit uint (in big endian) at 0x4 at the beginning of a btsnd.
    If you don't want a loop, you just need to loop "silence".

    To find the start value you want to set with your wav, either act as if you were about to make a brstm with BrawlBox (for example, if you have another free software that can do custom loops, you're free to share your knowledge) and get the number of samples for the start value or (much more "painful") try to be as precise as possible in some audio editing software (ex: Audacity) when finding the start point and multiply that value (in seconds) by 48000 (the sample rate). Then convert your number of frames in hex, for example with Windows'calc in programmer mode, open your btsnd with a hex editor such as HxD, select the block from 0x4 to 0x7 and (if your value has less than 8 chars, complete it with 0's at the beginning, ex: 296575=>0x4867f=>0x00048674) enter your start point value in hex.
     
  7. Xuman

    Xuman GBAtemp Fan
    Member

    Joined:
    Jan 26, 2012
    Messages:
    407
    Country:
    United States
    Perfect time for those to make and share theirs
     
  8. Zarklord

    Zarklord GBAtemp Regular
    Member

    Joined:
    May 13, 2016
    Messages:
    194
    Country:
    United States
  9. galneon

    galneon GBAtemp Regular
    Member

    Joined:
    Jul 9, 2006
    Messages:
    251
    Country:
    United States
    Same problem, only in Windows. File is definitely right, but I get the same error. Tried your syntax and [source] [destination].
     
  10. Zarklord

    Zarklord GBAtemp Regular
    Member

    Joined:
    May 13, 2016
    Messages:
    194
    Country:
    United States
    does the wav have metadata? cause as far as i can tell you cant have metadata
     
  11. galneon

    galneon GBAtemp Regular
    Member

    Joined:
    Jul 9, 2006
    Messages:
    251
    Country:
    United States
    Nope, straight out of Presonus and as basic as it gets.
     
  12. Zarklord

    Zarklord GBAtemp Regular
    Member

    Joined:
    May 13, 2016
    Messages:
    194
    Country:
    United States
    its probably not a "RIFF" wav file do you mind uploading the wav file?
     
  13. galneon

    galneon GBAtemp Regular
    Member

    Joined:
    Jul 9, 2006
    Messages:
    251
    Country:
    United States
    Here it is (yes, it's dead air).
     
  14. Zarklord

    Zarklord GBAtemp Regular
    Member

    Joined:
    May 13, 2016
    Messages:
    194
    Country:
    United States
    yeah its not a compatible wav(i might look into adding support) but for now just run it through audacity(open the wav and then re-export)
     
    galneon likes this.
  15. galneon

    galneon GBAtemp Regular
    Member

    Joined:
    Jul 9, 2006
    Messages:
    251
    Country:
    United States
    That worked. Thanks!

    Edit: Here's my placeholder (dead air) boot sound if anyone wants it.

    It can be useful for your Haxchi launcher, or shortcuts to homebrew apps in sigpatched mode. How useful, I don't know--does the absence of a boot sound prevent an application from launching? Beats me, but if an application already has a boot sound, you can replace it with this.
     
    Last edited by galneon, Nov 17, 2016
  16. AboodXD

    AboodXD I hack NSMB games, and other shiz.
    Member

    Joined:
    Oct 11, 2014
    Messages:
    2,865
    Country:
    United Arab Emirates
  17. Zarklord

    Zarklord GBAtemp Regular
    Member

    Joined:
    May 13, 2016
    Messages:
    194
    Country:
    United States
    actually non looping bootSounds are not possible my no loop bootSound is looping silence added right at the end of the sound
     
  18. AboodXD

    AboodXD I hack NSMB games, and other shiz.
    Member

    Joined:
    Oct 11, 2014
    Messages:
    2,865
    Country:
    United Arab Emirates
    Yeah, I just tried it...
    It's silent... :(
     
  19. JohnathanMonkey

    JohnathanMonkey GBAtemp Advanced Fan
    Member

    Joined:
    Apr 26, 2013
    Messages:
    629
    Country:
    United States
    When we export this using audacity, what exactly do we need to export this as? I click export, but there doesn't seem to be an option for a Riff wav using audacity. Please see the attached images. I think I am just missing something, but when I replace the bootSound.btsnd, it just plays the original sound like I never replaced it at all.
    Capture.PNG

    Untitled.png

    Here is the WAV file:
    Code:
    https://mega.nz/#!5wJWiTaY!0fHIdbN0ik43dMxqUecBUWLPPX5Ne5j8PuiA_tkLdNg
     
    Last edited by JohnathanMonkey, Feb 12, 2017
  20. Deleted User

    Deleted User Newbie

    Audacity outputs RIFF WAV files by default. You just need to make sure that at the bottom of the screen, you select 48000Hz (the default selection is 44100Hz), then click File -> Export Audio and make sure that WAV is selected as the file format. On the next screen, you will be asked to add metadata to the file, ensure that all these boxes are blank.
     
Draft saved Draft deleted
Loading...

Hide similar threads Similar threads with keywords - wav2btsnd, simple, create