org.jouvieje.fmodex.enumerations
Class FMOD_DSP_PITCHSHIFT

java.lang.Object
  extended byorg.jouvieje.fmodex.enumerations.FMOD_DSP_PITCHSHIFT
All Implemented Interfaces:
java.lang.Comparable, org.jouvieje.fmodex.enumerations.Enumeration

public class FMOD_DSP_PITCHSHIFT
extends java.lang.Object
implements org.jouvieje.fmodex.enumerations.Enumeration, java.lang.Comparable



Parameter types for the FMOD_DSP_TYPE_PITCHSHIFT filter.

Remarks

This pitch shifting unit can be used to change the pitch of a sound without speeding it up or slowing it down.
It can also be used for time stretching or scaling, for example if the pitch was doubled, and the frequency of the sound was halved, the pitch of the sound would sound correct but it would be twice as slow.
Warning! This filter is very computationally expensive! Similar to a vocoder, it requires several overlapping FFT and IFFT's to produce smooth output, and can require around 440mhz for 1 stereo 48khz signal using the default settings.
Reducing the signal to mono will half the cpu usage.
Reducing this will lower audio quality, but what settings to use are largely dependant on the sound being played. A noisy polyphonic signal will need higher fft size compared to a speaking voice for example.
This pitch shifter is based on the pitch shifter code at http://www.dspdimension.com, written by Stephan M. Bernsee.
The original code is COPYRIGHT 1999-2003 Stephan M. Bernsee .
'maxchannels' dictates the amount of memory allocated. By default, the maxchannels value is 0. If FMOD is set to stereo, the pitch shift unit will allocate enough memory for 2 channels. If it is 5.1, it will allocate enough memory for a 6 channel pitch shift, etc.
If the pitch shift effect is only ever applied to the global mix (ie it was added with System::addDSP), then 0 is the value to set as it will be enough to handle all speaker modes.
When the pitch shift is added to a channel (ie Channel::addDSP) then the channel count that comes in could be anything from 1 to 8 possibly. It is only in this case where you might want to increase the channel count above the output's channel count.
If a channel pitch shift is set to a lower number than the sound's channel count that is coming in, it will not pitch shift the sound.

Platforms Supported

Win32, Win64, Linux, Linux64, Macintosh, Xbox360, PlayStation 2, PlayStation Portable, PlayStation 3, Wii, Solaris, iPhone

See Also

DSP::setParameter
DSP::getParameter
FMOD_DSP_TYPE


Field Summary
static FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_FFTSIZE
           
static FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_MAXCHANNELS
           
static FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_OVERLAP
           
static FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_PITCH
           
 
Method Summary
 int asInt()
           
 int compareTo(java.lang.Object object)
           
 boolean equals(java.lang.Object object)
           
static FMOD_DSP_PITCHSHIFT get(int nativeValue)
          Retrieve a FMOD_DSP_PITCHSHIFT enum field with his integer value
static FMOD_DSP_PITCHSHIFT get(Pointer pointer)
          Retrieve a FMOD_DSP_PITCHSHIFT enum field from a Pointer
static java.util.Iterator iterator()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

FMOD_DSP_PITCHSHIFT_PITCH

public static final FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_PITCH

FMOD_DSP_PITCHSHIFT_FFTSIZE

public static final FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_FFTSIZE

FMOD_DSP_PITCHSHIFT_OVERLAP

public static final FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_OVERLAP

FMOD_DSP_PITCHSHIFT_MAXCHANNELS

public static final FMOD_DSP_PITCHSHIFT FMOD_DSP_PITCHSHIFT_MAXCHANNELS
Method Detail

asInt

public int asInt()
Specified by:
asInt in interface org.jouvieje.fmodex.enumerations.Enumeration
Returns:
the integer value of the enumeration constant.

toString

public java.lang.String toString()

equals

public boolean equals(java.lang.Object object)

compareTo

public int compareTo(java.lang.Object object)
Specified by:
compareTo in interface java.lang.Comparable

get

public static FMOD_DSP_PITCHSHIFT get(int nativeValue)
Retrieve a FMOD_DSP_PITCHSHIFT enum field with his integer value

Parameters:
nativeValue - the integer value of the field to retrieve
Returns:
the FMOD_DSP_PITCHSHIFT enum field that correspond to the integer value

get

public static FMOD_DSP_PITCHSHIFT get(Pointer pointer)
Retrieve a FMOD_DSP_PITCHSHIFT enum field from a Pointer

Parameters:
pointer - a pointer holding an FMOD_DSP_PITCHSHIFT enum field
Returns:
the FMOD_DSP_PITCHSHIFT enum field that correspond to the enum field in the pointer

iterator

public static java.util.Iterator iterator()
Returns:
an Iterator over the elements in this enumeration.
Can be cast to Iterator in Java 1.5.


NativeFmodEx Project - © Copyright 2005-2010 - Jérôme Jouvie (Jouvieje)
NativeFmodEx is an Open Source Project under GNU LGPL License
My sites : http://jerome.jouvie.free.fr/

(Documentation Copyright © Firelight Technologies - FMOD Ex - http://www.fmod.org)