I am using XNA to develop a game which requires both sound effects and music. I'm trying to figure out how to implement the sound engine. Microsoft provides the ability to use the Content Pipeline to load and play audio. However, I also seen people use Xact to do the same thing. My question is, whats the difference and what would be the better approach to making a sound engine?
Xact is feature rich but complex to use. It was originally the only way to play sound but people wanted something simpler so Microsoft added the content pipeline method.
Use the Content Pipeline if you want:
To play a sound (2d or 3d)
To not have to invest a lot of time
learning an audio framework
Use Xact if you want:
Categories of sounds that can be
interdependently controlled, like
mute game sounds but not menu sounds
Real time advanced control over sound
pitch, volume. For things like
turrets spinning up, cars
accelerating etc.
To have multiple varieties of a
single sound effect like a seven
different pain sounds and have Xact
choose which one to play.
To have a sound play with slightly
different pitch, volume, filter or 3d
pan every time it is played. This is
really good for bullets and
repetitive things like that. There
is nothing that says fake computer
simulation like a repeating sound
with no variance.
To allow a game designer or sound
designer full control to edit and
change sounds without touching the
code.
To have sound banks (collections of
sound) that you can load or unload as
a group, which can use different
compression settings and can be in
memory or streaming.
To mix the volume, pitch and priority
of sounds in an editor.
To apply filtering to a sound.
To control whether the sound is
looping or not.
To use DSP Effects
One of my favourite things about Xact is editing and previewing of sound functions in editor. For example a volume fade on a turret overheat sound. With XACT you can sit down with the sound designer, even if he's not a technical guy and edit the control curves until he's happy with the sound. Once you've set it up it's really easy to change later on. In this example image here a turret is overheated. At the end of the overheat cycle the hissing steam noise volume is reduced, but because it's a curve I have a lot of control over how the sound fades out. I've used this with a beam weapon as well, dropping the frequency according to a curve as it runs out of ammo.
Related
TL;DR - I'm looking for a plugin or technique to pitch shift audio assets precisely.
I'm working on a unity3d project to create a binaural VR music visualizer (why I'm trying). I've created a basic visualizer and the music player components pretty easily with tutorials online but I'd like to find an easy way of frequency shifting audio tracks. This is similar to pitch-shifting, which unity supports via the Audio Pitch Shifter Effect but it's expressed as a multiplier rather then a unit of measure and effects playback speed. However, I need to pitch-shift the audio while maintaining playback rate as the normal audio plays in one ear, and the effected audio plays in the other.
The goal being that I can use a standard slider to decide the frequency of the binaural wave, and relate it to the left and right audio output, and with the VR solution, I can provide similar bi-visual effects at the appropriate frequency in each eye for a more intense effect.
I think I might have found my own solution buried in plugins - but it's much more specific then I would have thought: https://www.assetstore.unity3d.com/en/#!/content/66518
Though I would like to hear anyone else's approach to advanced audio effects like this.
I'm a college student who has learned to program. I have a game that is just wrapping up, and my graphics and design team is (Freshman) spotty. I'm planning for the worst, and would like recommendations for animation and design software that a programmer can easily pick up and use with no longer than 8-10 hours to learn it. If you could post a couple down below and a brief description of what it can do, that would be great. I will post my specifications below.
Working on Unity
Broke... Like College students are. I can put down a little money though
I will be creating a lot of sprite 2D images
I will be making somewhere around 2-5 animations depending on how well I pick up on it.
I do have Blender, but I cannot figure out how to color things on it. I barely figured out how to design an explosion.
Using of graphical tool can't make your graphical design and art better. You have to be an artist or learn to. So you can go with 2 ways:
1) Try to be an artist (it's hard long way full of risks). You need much time for practicing with ANY tools (pen and paper are good for the start). When you be able to create amazing things you find tools very quickly.
2) Focus on programming or game-design and use simplified design styles (baby-painting, hand-writing with pen, flat-design) or even use technical sprites like simple geometry. When your game will be almost finished you can hire an artist to redraw your art. It is much easier when your have all necessary image lists and even images with right ration and resolution. Just redraw them and put in your game and game is ready for production.
What I'm trying to say? Don't try to compete with your average graphics. Today's market is full of hi-quality games with amazing graphics. Impress gamers with your cool ideas and gameplay and may be they forgive you bad graphics. Anyway you have many options:
Make your game with technical images first and then will see what to do next (best option)
Use free images under creative commons license (it's difficult to gather full set of images in unique style)
Use primitive graphics that gamers forgive you (your game must be very cool)
Hire a professional artist (best option if you have money and finished game)
Regarding animations - it's pretty easy to avoid drawing each frame. You can transform your objects in Unity so that your scene will look vivid with standard Unity features
Sorry that I don't suggest you concrete tool, but I want to save your time and energy to encourage you making cool games, not fighting with tools that are useless for non-artist.
I'm making a War Game for iOS using Monotouch and C#. I'm running into some problem with the audio sound effects.
Here's what I require: The ability to play many sound effects simultaneously (possibly up to 10-20 at once) and the ability to adjust volume (for example, if the user zooms in on the battlefield the gun shot volume gets louder).
Here are my problems:
With AVAudioPlayer, I can adjust volume but I can only play 1 sound per thread. So if I want to play multiple sounds I have to have dozens and dozens of threads going just incase they overlap... This is a war game, picture 20 soldiers on the battlefield. Each soldier would have a "sound thread" to play gun fire sounds when they shoot because It is possible that every soldier could just happen to fire at the same exact time. I don't have a problem with making lots of threads, but my game already has dozens of threads running all the time and adding dozens more could get me into trouble... right? So I'd rather not go this road of adding dozens of more threads unless i have too...
With SystemSound, I can play as many sounds as I want in the same thread, but I can't adjust the volume.... So my work around here is, for every sound effect i have - save it like 4 times at 4 different volumes. That is a big pain... Any way to adjust volume with SystemSounds??
Both of these answer some of my requirements, but neither seems to be a seamless fit. Should I just go the AVAudioPlayer multi-threading nightmare road? Or the SystemSound multi-file-with-different-volume-levels nightmare road? Or is there a better way to do this?
Thanks in advance.
Finally found the solution to my problem. AVAudioPlayer IS capable of playiing multiple sounds at once but only with certain file formats... The details are available in this link. The reason why I couldn't play my sound effects simultaneously was because the file format was compressed and the iphone only has 1 hardware decompressor.
http://brainwashinc.wordpress.com/2009/08/14/iphone-playing-2-sounds-at-once/
I'm not fully sure what I'm looking for so I was hoping to gain some insight. I'm brainstorming an application I want to write, but I've never dealt with this type of project. I was wondering if any of you knew of any resources, both literature and libraries/APIs that could lead me down the path to creating an application that involves the playback of audio, visualization of audio (like displaying the waveform with a scrolling position), setting playback points, maybe some effects like fade in and out, maybe even beat mapping; all in .net
For example, an application that displays a waveform and has a position indicator that moves with playback. It allows you to visually set multiple start and stop points, etc.
Any suggestions?
Check out http://naudio.codeplex.com/
I think a lot of people used application "Fraps" for recording video from game. I use it for displaying FPS (frames per second) in the games. Fraps can show digits at the corner of screen when game runs.
I want to display core temperature of processor. The temperature I will find, but I need to khow, how can I display it in the game? (I need it for testing core temperatures in the game, because stress tests of Everest/AIDA64 doesn't much load the system).
Want to use C# (but can listen to all solutions, C++, Java)
Example games: Dirt2, Call of Duty 5 (DirectX)
P.S. This post was similar...
c# text/winForm overlay video games like xfire,PIX,steam,fraps etc
What you want to do is a bit more complex than you might think. There are different sources on the web about this, some might be a bit outdated. A good search Term is "Hook direct 3d", there are also other threads on stackoverflow about this topic. A good thread is also this.
One advice: You are changing the runtime code of the game, which can be detected by anti cheat mechanism and can cause banning if the game is a multiplayer game. It is even possible that widely known applications like fraps are on some sort of whitelist against these checks, but i'm not sure about that.
An alternative to what you want could be to make your form always stay on top (form.TopMost = true;). Then you can set the transparency color the same color as your form (by default it would be form.TransparencyKey = System.Drawing.SystemColors.Control;). After that you can remove the border of your form (form.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;).
Be careful not to use the transparency color anywhere else (it'll make part of images transparent if it contains this color).
Make sure to have a way of closing the form. (and moving it if needed).