Playsound

Previous topic - Next topic

Hemlos

#15
sndrec32.exe in c:/windows/system32/

If you open any wav in that program, you select "file", then click "properties".
It has a converter builtin to your operating system.
I selected the PCM 44khz 16 bit stereo..which is the same format as Sensaura.wav in the glbasic samples directory.

EDIT: Windows XP
Bing ChatGpt is pretty smart :O

Hemlos

By the way, a note about sound and compression.

Sound is similiar to images when it comes to compression and reducing the resolution.

If you crush it down to a small format, you will lose information.
Its a good idea to keep a high resolution copy of your sound, so you can make a new sound at any lower compression rate.
Bing ChatGpt is pretty smart :O

Ian Price

Be aware that Windows7 does NOT come with SNDREC32 - it comes with a new version called SOUNDRECORDER which doesn't have ANY of the features of SNDREC32. It's only purpose is to save sfx and it only saves in .WMA format "out of the box" - you can use a commandline to force saving in .WAV though.

I recommend that everyone that upgrades to Windows7 to get either a decent sound editing software or grab your old copy of SNDREC32 from Windows Xp or 98. It works, but on initially running it it states that there's a registry issue. If you can find and copy the registry info it should work properly.

MS really stuffed up by not including SNDREC32 as standard. Sure it's basic and there are better apps available, but what it does, it does well.
I came. I saw. I played.

Hemlos

I agree Ian, having better software is good.
And ms definetly messed up if they didnt add sndrec32.
Anyway, I wonder if its legal to copy sndrec32.exe and use it in windows7(assuming its compatible)

I have a creative soundblaster 24 bit 7.1 sound card. and it comes with a complete creative software sound package which works rather well too.

Bing ChatGpt is pretty smart :O

Ian Price

QuoteI wonder if its legal to copy sndrec32.exe and use it in windows7

That's a good question, but honestly I don't really care :P I purchased the license to use that software when I bought Win98 and WinXP, so I'm using it. I can no longer use the laptop that it came from, so it's not being used on two machines.
I came. I saw. I played.

erico

hi there,

Don't know the answer to your question, for one thing, my encoding goes on an old version of sound forge, so far no problem. I have an issue with the volume though but it is just me(1 works fine, less doesn't work), did not mess with it enough. I will try your sound file and let you know how it goes...

Hemlos

Ian pointed out it was the file format, i was ignorant to which compression rate glbasic expects.
Bing ChatGpt is pretty smart :O

MrTAToad

Its one advantage of using FMOD - unfortunately, if you want to use the latest version, you cant with Linux...

Hemlos

Found another problem here...this time i think it isnt me  :S

The volume must be higher than 0.5 to hear it at all.
Volume is unproportional to the input.
if you play the sound at 50%...   0.5 volume then the sound is almost impossible to hear it.
can anyone else confirm this?

Test it with GLBasic samples:
You can use the GLBasic 'Playsound.gbap' sample to see what i mean....
BTW, You must click the mouse to start the sound in that sample.
Move the mouse to control the panning and the volume.
It shows % of volume there.
Bing ChatGpt is pretty smart :O

Ian Price

With ear-phones I can hear the sound below 50% - at around 30% I can just about hear something. At under 25% my old ears hear nothing.

Have you had your hearing checked lately? :P
I came. I saw. I played.

Hemlos

Hmm im 37, i didnt expect to need to having a hearing test so soon.
Bing ChatGpt is pretty smart :O

Ian Price

I'm 38 and not quite deaf yet :P
I came. I saw. I played.

erico

opa! that's the problem I have, so 30% and 50% (.3 and .5) works, nice, thanks.
I was waiting to check the sound commands latter.

Moru

Last time I played around with sounds (midi and other) I was getting so different valued depending on what other sound programs I was running earlier and if I had run GLBasic already. I didn't realy figure out in what order I had to start programs I just gave up with sound totally. Volume was never the same no matter what I set it to.

Hemlos

#29
Quote from: Moru on 2009-Nov-27
Last time I played around with sounds (midi and other) I was getting so different valued depending on what other sound programs I was running earlier and if I had run GLBasic already. I didn't realy figure out in what order I had to start programs I just gave up with sound totally. Volume was never the same no matter what I set it to.

First, midi is electronic code for a computer to read and synthesize to the speakers.
The volume in a midi file is coded in, and it might be adjustable with the proper software.
So for midi it is system dependant for volume.

For wav, you have a wav form pattern, and you can increase or decrease this wav size in most audio applications. I played a sound.wav in windows and it plays at a different level of volume in glbasic for some reason.

And i found a fast and dirty solution, and here it is with a warning:
I opened the file in sndrec32.exe in windows...it has an option to increase or decrease volume by 25%, which is additive, you can do it a few times.
Be careful though...you can make it too loud and it causes the wav form to "square" at the top and bottom of the wav forms....you want to increase the volume right before it hits the top of the wave display region. Dont square your sound, or itll rip your speakers apart. Be certain you dont square your waves, as this is unprofessional, and dangerous to your electronics, sndrec32.exe might not be the best way, but it is decent.

Squared patterns will remain square, you must start over if you end up with it like this.
Increase volume slow, and dont let the wave hit the top or bottom of the indicator.
The square is a resolution, just like an image file...if you decrease the resolution, you are messing up the data, and you have to start over.


Bing ChatGpt is pretty smart :O