Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: What sound format best suits our game?  (Read 2270 times)

0 Members and 1 Guest are viewing this topic.

SpectreNectar

  • Newbie
  • *
  • Posts: 39
    • View Profile
What sound format best suits our game?
« on: July 12, 2017, 12:00:46 pm »
Hello audio devs,
we used to store music and sound effects in separate .ogg files but now we noticed that the total clip length of each file has decreased after conversion from .wav. This is especially unfortunate for music/voice acting clips because quality decreased as a result.

What is your experience and what can you suggest we do in the future?

Cheers
http://giantgoblinstudio.com

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: What sound format best suits our game?
« Reply #1 on: July 12, 2017, 07:19:49 pm »
Clip length as in file size or play back time?

If you convert from wav (lossless) to ogg (compressed) the play back time should stay the same and the file size will decrease slightly, as it now is compressed. But due to OGG's compression the quality shouldn't decrease noticably, unless you picked some really like w quality setting.

What converter did you use?
« Last Edit: July 12, 2017, 07:22:10 pm by eXpl0it3r »
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

SpectreNectar

  • Newbie
  • *
  • Posts: 39
    • View Profile
Re: What sound format best suits our game?
« Reply #2 on: July 12, 2017, 08:09:28 pm »
Play back time. On all files, but only slightly.

For converter we used both REAPER and Audacity.

John discovered the decrease in duration after noticing the music was different after conversion.

Hapax

  • Hero Member
  • *****
  • Posts: 3379
  • My number of posts is shown in hexadecimal.
    • View Profile
    • Links
Re: What sound format best suits our game?
« Reply #3 on: July 16, 2017, 12:59:05 pm »
Is it possible, do you think, that OGG requires a length to be a multiple of specific amounts (possibly based on bitrate)?

Is your sound clipped from the beginning of the sound, the end or both? If it's the end, which is most likely, you can simply add silence to the original. However, if it includes the beginning (which I think I remember seeing happening somewhere), you could try adding silence to the beginning if the only problem is that a small amount of the sound is clipped. If the problem is exact timing (as expected from dialogue), however, if the beginning is different, code would need to accommodate that (you could offset the start position, for example).
Selba Ward -SFML drawables
Cheese Map -Drawable Layered Tile Map
Kairos -Timing Library
Grambol
 *Hapaxia Links*

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: What sound format best suits our game?
« Reply #4 on: July 16, 2017, 07:19:08 pm »
How big is the difference? Can you provide an WAV and an OGG example?
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/