Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Agent Denison

Duration of sound effects

Recommended Posts

Hi. I used to be Mechanos until a few years ago. I have a question for all that know the specs on the original DOOM engine. I, much like most if not all of you, want to make a wad, and part of my planned wad will include adding some ambient sound effects. Now I looked up on the DOOM wiki as well as the unofficial DOOM specs, and they state that the maximum length for any sound effect is six seconds. However, I watched some videos of the vanilla doom wads "The Sky may be" and "Yakworld", which seem to have sounds that seem to exceed six seconds. In the wad Yakworld the part when you fight the cyberdemon a soundbite plays that I counted to be about ten seconds. So my question is is it possible to play a sound in a vanilla wad that can exceed six seconds or was there some dehacked trickery used in Yakworld?

Share this post


Link to post

It is impossible in any way, shape, or form for Dehacked to modify such a limitation (or any limitation). Instead, the answer is already the easiest one: There is no 6 second sound limit on Doom format sounds.
The 6 second limit was based on the assumption that the old sound format only had 16 bits for sample length, in actuality it's 32bit signed. Vanilla can handle longer sounds fine, at least that's what dosbox reveals.

Share this post


Link to post

Thanks for that info. So just how long of a sound clip can one play in vanilla DOOM? I hope to use a sound clip of a supposed recording of Hell that was rumored to be obtained by some geologists drilling a hole in Siberia, which is about a minute long but I can cut it down if need be.

Share this post


Link to post

The maximum length depends on sample rate. Assuming you'll use the standard sample rate of Doom sounds (11025 Hz), and knowing that the number of samples is stored as a signed 32-bit value, and the maximum sound length would be 6 seconds if it was stored as an unsigned 16-bit value, then the real maximum length would be 6 seconds multiplied by 2^15, which is over 54 hours.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×