Author Topic: A useful audio resource site  (Read 5893 times)

0 Members and 1 Guest are viewing this topic.

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
A useful audio resource site
« on: January 25, 2022, 03:36:32 am »
For everyone who likes to add little tidbits of sound and such to their programs, I thought I'd share this little website for you guys:  https://evolution.voxeo.com/library/audio/prompts/

It's a collection of pre-recorded, royalty-free, open-license sound files which cover a whole lot of the things which I personally tend to make use of in various programs.  Letters, numbers, dates, currency, math, ect...   

With these, I've written spelling programs for children before, which toss an image of something onto the screen and then ask the child to Spell It!  (Example, a picture of a CAT appears on screen.)  If right, it praises the child.  If wrong, the program then goes on to specify.  "C"... "A"... "T"...   "This is a" "C"... "A"... "T"...  <pause for 2 seconds>...  "C"... "A"... "T"...   

Clocks can tell time with these (as illustrated above).  You can have currency amounts read out to you.  You can set up a calculator to read things back to you...   Lots of small little plug-in uses, and honestly, I think everyone should have this little archive somewhere on their computer. 

Only one issue which I've found with it -- and it's not with it, in particular, but with QB64 -- and that's with the fact that these are WAV files which we *should* be able to work with, but we can't.  You'll need to convert them to OGG or MP3 to fully make use of them in QB64 projects, but there's a ton of tools available out there to do so.  (Hint... Hint... VLC can convert file formats, last time I checked, and it's free, and almost everyone has a copy of it already...)



EDIT:  For those folks who can't be bothered to convert files as needed, I went ahead and did so here for everyone:   [ You are not allowed to view this attachment ]  

Note that I left the original WAV files in the archive as well, so if you end up deciding you don't need those, that'll reduce the size of your resource files by half.  (From 4 MB to 2... Woooo!!!   If 2 MB storage is an issue for you on modern systems, you need an upgrade! :P )
« Last Edit: January 25, 2022, 04:05:40 am by SMcNeill »
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: A useful audio resource site
« Reply #1 on: January 25, 2022, 10:55:49 am »
but with QB64 -- and that's with the fact that these are WAV files which we *should* be able to work with, but we can't. 


What do you mean by, "..but we can't."?
Granted after becoming radioactive I only have a half-life!

Offline bplus

  • Global Moderator
  • Forum Resident
  • Posts: 8053
  • b = b + ...
    • View Profile
Re: A useful audio resource site
« Reply #2 on: January 25, 2022, 11:33:35 am »
Thanks Steve, I have this bookmarked.

Yeah some .wav's are trouble, I download them and many don't work maybe up to 40% of what I have tried, usually the ones that sound perfect for my needs :( , so it may seem like more than there really are.

Are there different formats for .WAV?

For example O.wav Steve just passed to me here: https://qb64forum.alephc.xyz/index.php?topic=4592.msg140056#msg140056

« Last Edit: January 25, 2022, 11:53:50 am by bplus »

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: A useful audio resource site
« Reply #3 on: January 25, 2022, 12:19:52 pm »
Are there different formats for .WAV?

apparently there is. Looking at the HEX layout of the O.wav file and the HEX layout of the same file exported from Audacity they are completely different.

  [ You are not allowed to view this attachment ]  
Granted after becoming radioactive I only have a half-life!

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: A useful audio resource site
« Reply #4 on: January 25, 2022, 12:37:27 pm »
I think the most glaring difference is the Format Type value, which in the original O.wav file is 7 (???) and not a 1(PCM).

So what ever format 7 is the codec used by QB64 cannot decode it.

if you change it to a 1 the file loads and plays in a distorted way.

note: A Format Type 7 seems to be some kind of 4bit ADPCM encoded.
« Last Edit: January 25, 2022, 12:57:13 pm by Cobalt »
Granted after becoming radioactive I only have a half-life!

Offline bplus

  • Global Moderator
  • Forum Resident
  • Posts: 8053
  • b = b + ...
    • View Profile
Re: A useful audio resource site
« Reply #5 on: January 25, 2022, 01:30:51 pm »
Yeah change the format and make everyone get Your Products Player that handles all the formats. :(

But who is kicking out all the .wav files with crazy formats, must be an advantage to .wav file creators to have new probably more flexible formats.

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
Re: A useful audio resource site
« Reply #6 on: January 25, 2022, 01:32:18 pm »
What do you mean by, "..but we can't."?

All you have to do is try the sounds in the package and you'll see we can't make use of them.  QB64 fails to load and decode them properly.

It's a known issue for us, and is even addressed in the wiki: http://www.[abandoned, outdated and now likely malicious qb64 dot net website - don’t go there]/wiki/index-php/SNDOPEN/

"If a WAV sound file won't play, try it using the Windows Play WAV sounds library to check it or convert the sound file to OGG."

Edit:  Why is google pointing us to the old, malicious qb64 site when we do a search for stuff on the wiki?  Is our WIKI still down??

Edit2:  Try this wiki link: https://wiki.qb64.org/wiki/SNDOPEN
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
Re: A useful audio resource site
« Reply #7 on: January 25, 2022, 01:41:28 pm »
Yeah change the format and make everyone get Your Products Player that handles all the formats. :(

But who is kicking out all the .wav files with crazy formats, must be an advantage to .wav file creators to have new probably more flexible formats.

Audio in WAV files can be encoded in a variety of audio coding formats, such as GSM or MP3, to reduce the file size. This is a reference to compare the monophonic (not stereophonic ) audio quality and compression bitrates of audio coding formats available for WAV files including PCM , ADPCM , Microsoft GSM 06.10 , CELP , SBC , Truespeech and MPEG Layer-3.


And apparently we only decode and work with some of those.
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: A useful audio resource site
« Reply #8 on: January 25, 2022, 05:04:18 pm »
But who is kicking out all the .wav files with crazy formats, must be an advantage to .wav file creators to have new probably more flexible formats.
seems to be a very old encoding developed in the early 70s for use in phone calls. Why somebody would still use it in the past 20 years I don't even want to wonder, or Steve's audio resources are as old as he is?! 😜

All you have to do is try the sounds in the package and you'll see we can't make use of them.  QB64 fails to load and decode them properly.
The way you put it sounded more like we can't open WAV files at all.
Granted after becoming radioactive I only have a half-life!

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
Re: A useful audio resource site
« Reply #9 on: January 25, 2022, 05:08:21 pm »
The way you put it sounded more like we can't open WAV files at all.

We can't-- at least not dependably.  Download a batch of wav files for your project.  How many of them work?  How many won't work?  There's no way to know without attempting to load and manually test each one, and who wants to do that??

I just go with the basic idea, "wav files don't work always, so it's best to convert them", and prevent any issues before they start.  ;)
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline Cobalt

  • QB64 Developer
  • Forum Resident
  • Posts: 878
  • At 60 I become highly radioactive!
    • View Profile
Re: A useful audio resource site
« Reply #10 on: January 25, 2022, 05:25:19 pm »
We can't-- at least not dependably.  Download a batch of wav files for your project.  How many of them work?  How many won't work?  There's no way to know without attempting to load and manually test each one, and who wants to do that??

Guess I'm just too picky on where I get my wav files.

Though now that I think about it, this isn't the first time someone has found audio files that wouldn't load.

this nice quote might help explain the problem some:
Quote
A Bastardized Standard
The WAVE format is sort of a bastardized standard that was concocted by too many "cooks" who didn't properly coordinate the addition of "ingredients" to the "soup". Unlike with the AIFF standard which was mostly designed by a small, coordinated group, the WAVE format has had all manner of much-too-independent, uncoordinated aberrations inflicted upon it. The net result is that there are far too many chunks that may be found in a WAVE file -- many of them duplicating the same information found in other chunks (but in an unnecessarily different way) simply because there have been too many programmers who took too many liberties with unilaterally adding their own additions to the WAVE format without properly coming to a concensus of what everyone else needed (and therefore it encouraged an "every man for himself" attitude toward adding things to this "standard"). One example is the Instrument chunk versus the Sampler chunk. Another example is the Note versus Label chunks in an Associated Data List. I don't even want to get into the totally irresponsible proliferation of compressed formats. (ie, It seems like everyone and his pet Dachshound has come up with some compressed version of storing wave data -- like we need 100 different ways to do that). Furthermore, there are lots of inconsistencies, for example how 8-bit data is unsigned, but 16-bit data is signed.

also from the same paper:

Quote
I've attempted to document only those aspects that you're very likely to encounter in a WAVE file. I suggest that you concentrate upon these and refuse to support the work of programmers who feel the need to deviate from a standard with inconsistent, proprietary, self-serving, unnecessary extensions. Please do your part to rein in half-assed programming.
Granted after becoming radioactive I only have a half-life!

Offline madscijr

  • Seasoned Forum Regular
  • Posts: 295
    • View Profile
Re: A useful audio resource site
« Reply #11 on: January 25, 2022, 10:36:55 pm »
For everyone who likes to add little tidbits of sound and such to their programs, I thought I'd share this little website for you guys:  https://evolution.voxeo.com/library/audio/prompts/

Wow, that's pretty cool - thanks for sharing that, these will be loads of fun!

PS I've got a sound-related request of my own (will post separately).