1. How do I implement the fade-in and fade-out effect when switching between sounds?
(1) For background music: classify all background music into one category (catigory), such as music. attributes are set as follows:
(2) For sound effects: Create an RPC, set the parameters in to attacktime/releasetime to control volume, and then draw a curve with the volume changing over time as needed, then attach all the sound that requires this effect to this RPC.
2. How to compress audio files? Wav occupies too many places
Xact will convert the wav (source file) format during packaging. It supports ADPCM and xwma compression formats. practice: first, right-click "compression presents", select "new compression present", and then select the corresponding compression format, such as WMA, you can also adjust the quality parameter. then, select the new compression present in the attribute Panel of the wavebank to be compressed, and compile the project to see the effect.
3. Why does my 3D sound have no sense of distance? That is to say, there is no effect on the volume.
The distance attenuation of the volume is a part of rpcs. we need to specify an RPC present for all the sound that requires this effect. create an RPC present, double-click it to open the reference and set it. Then, drag the present to the specified sound and it will be OK:
4. Why does my WAV file xact not recognize it?
Xact only supports PCM audio. We recommend that you use the wav file in PCM 16bit 44100 stereo format as the source file.
5. Why does the program become unresponsive when I try to hear the sound in xact?
Run "audio console" before the test, which is equivalent to a server. In addition, the connection fails on Web servers such as IIS because port 80 is occupied.
6. How to play one of multiple sounds at random?
Drag the selected sound to a single cue. The name and playback probability of each sound are displayed in the list on the Right of cue. the default playback method is "random (no immediate repeats). In the program, you only need one cue name to play multiple sounds at random. in addition, you can mount Multiple Waves Under play wave of sound.
7. How to play a cue cyclically?
Select "infinite" under "looping" in the sound attribute corresponding to cue, that is, an infinite loop.
8. How can I adjust the volume when the program is running?
One method is ixact3engine: setvolume to control the volume of the entire classification. The other method is to create a Gobal variable and control it through RPC:
Of course, the media used by the program to interact with xact is the "musicvolume" variable, ixact3engine: setglobalvariable/ixact3engine: getglobalvariable
9. Why does the interactive cue not stop automatically after playing?
Interactive cue can be viewed as in the "ON/OFF" status, starting from play, maintaining the "on" status until "Stop () "ends to" off "(destroy ). after playing a sound, cue enters the "(STOP)" transaction state, and waits for the variable to change and does not automatically end itself. changing the value of relevant variables will lead to a new sound playing. Of course, you can set more complex sound switching and transition in transaction...
10. How to accelerate the playing of audio?
In fact, increasing the pitch is to accelerate the playing. The tone range in xact is (-12 ~ 12) I used a stopwatch to calculate a speed of about 0.5 ~ Speed 2 (-_-). The method for adjusting the tone is the same as the volume, which is completed through rpc. See figure 8.
11. Why is stream-loaded music sometimes playing discontinuous?
If ixact3engine: dowork () is called from time to time, the audio will be disconnected after the stream loading buffer is played. therefore, putting this call into an independent thread will not be affected by the call frequency of the main loop.