<?xml version="1.0" encoding="utf-8" standalone="yes"?>

<?xml-stylesheet href="./_c74_ref.xsl" type="text/xsl"?>

<!--This is an automatically generated file. DO NOT EDIT THIS FILE DIRECTLY. Rather, use the _ref.xml files found in the 'edits' folder.-->
<c74object name="pfft~" module="msp" category="MSP FFT">
	<digest>
		Spectral processing manager for patchers
	</digest>
	<description>
		The <o>pfft~</o> object is designed to simplify spectral audio processing using the Fast Fourier Transform (FFT). In addition to performing the FFT and the Inverse Fast Fourier Transform (IFFT), <o>pfft~</o> (with the help of its companion <o>fftin~</o> and <o>fftout~</o> objects) manages the necessary signal windowing, overlapping and adding needed to create a real-time Short Term Fourier Transform (STFT) analysis/resynthesis system.
	</description>
	<!--METADATA-->
	<metadatalist>
		<metadata name="author">
			Cycling '74
		</metadata>
		<metadata name="tag">
			MSP
		</metadata>
		<metadata name="tag">
			MSP FFT
		</metadata>
	</metadatalist>
	<!--INLETS-->
	<inletlist>
		<inlet id="0" type="signal, message">
			<digest>
				Input 1
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
		<inlet id="1" type="signal, message">
			<digest>
				Input 2
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
	</inletlist>
	<!--OUTLETS-->
	<!--ARGUMENTS-->
	<objarglist>
		<objarg name="subpatch-name" optional="0" type="symbol">
			<digest>
				Patcher name
			</digest>
			<description>
				Name of patcher to load
			</description>
		</objarg>
		<objarg name="FFT-size" optional="1" units="samples" type="int">
			<digest>
				FFT size
			</digest>
			<description>
				Specifies the FFT size, in samples, of the overlapped windows which are transformed to and from the spectral domain by the FFT/IFFT. The window size must be a power of 2, and defaults to 512. (Note: The size of the spectral &quot;frames&quot; processed by the <o>pfft~</o> object's subpatch will be half this size, as the 2nd half of the spectrum is a mirror of the first and thus redundant, unless the full-spectrum-flag is present.)
			</description>
		</objarg>
		<objarg name="overlap-factor (hop-size-denominator)" optional="1" type="int">
			<digest>
				Overlap factor
			</digest>
			<description>
				The third argument determines the overlap factor for FFT analysis and resynthesis windows. The hop size (number of samples between each successive FFT window) of Fast Fourier transforms performed is equal to the size of the Fast Fourier transform divided by this overlap factor. (e.g. if the frame size is 512 and the overlap is set to 4 then the hop size is 128 samples). The value must be a power of 2 and defaults to 2. A value of 4 is recommended for most applications.
			</description>
		</objarg>
		<objarg name="start-onset" optional="1" units="samples" type="int">
			<digest>
				Start onset
			</digest>
			<description>
				The fourth argument specifies the start onset in samples for the Fast Fourier transform. It must be a multiple of the current signal vector size and defaults to 0.
			</description>
		</objarg>
		<objarg name="full-spectrum-flag (0 or nonzero)" optional="1" type="int">
			<digest>
				Full spectrum mode enable
			</digest>
			<description>
				A non-zero fifth argument may be used to specify &quot;full-spectrum mode&quot;. In this mode, the <o>pfft~</o> object will internally compute a complex FFT and process full DC to SR mirrored spectra (instead of simply eliminating the redundant half of the spectrum). This takes extra computing power but may be potentially useful in some of the more esoteric spectral processing applications.
			</description>
		</objarg>
	</objarglist>
	<!--MESSAGES-->
	<methodlist>
		<method name="bang">
			<arglist />
			<digest>
				Function depends on inlet
			</digest>
			<description>
				Patchers loaded into a <o>pfft~</o> object can only accept <m>bang</m> messages by <o>in</o> objects within the patch. The number of inputs is determined by the <o>in</o> objects in the enclosed subpatch. See <o>in</o> for details.
			</description>
		</method>
		<method name="int">
			<arglist>
				<arg name="input" optional="0" type="int" />
			</arglist>
			<digest>
				Function depends on inlet
			</digest>
			<description>
				Integer values sent to the <o>pfft~</o> object cause the object to act according to the user-defined functionality within it.
			</description>
		</method>
		<method name="float">
			<arglist>
				<arg name="input" optional="0" type="float" />
			</arglist>
			<digest>
				Function depends on inlet
			</digest>
			<description>
				Floating-point values sent to the <o>pfft~</o> object cause the object to act according to the user-defined functionality within it.
			</description>
		</method>
		<method name="list">
			<arglist>
				<arg name="input" optional="0" type="list" />
			</arglist>
			<digest>
				Function depends on inlet
			</digest>
			<description>
				Lists sent to the <o>pfft~</o> object cause the object to act according to the user-defined functionality within it.
			</description>
		</method>
		<method name="anything">
			<arglist>
				<arg name="input" optional="0" type="list" />
			</arglist>
			<digest>
				Function depends on inlet
			</digest>
			<description>
				Messages sent to the <o>pfft~</o> object cause the object to act according to the user-defined functionality within it.
			</description>
		</method>
		<method name="(mouse)">
			<digest>
				Open a Max patcher window containing the loaded patcher
			</digest>
			<description>
				Double-clicking with the mouse on the <o>pfft~</o> object opens a Max patcher window containing the patcher loaded by the object.
			</description>
		</method>
		<method name="clear">
			<arglist />
			<digest>
				Clear all internal buffers
			</digest>
			<description>
				Clears all of the <o>pfft~</o> object's internal buffers.
			</description>
		</method>
		<method name="mute">
			<arglist>
				<arg name="mute-flag (0 or 1)" optional="0" type="int" />
			</arglist>
			<digest>
				Mute/unmute the <o>pfft~</o> 
			</digest>
			<description>
				The word <m>mute</m>, followed by a 1 or 0, will mute or unmute the <o>pfft~</o>, turning off signal processing within the enclosed subpatch.
			</description>
		</method>
		<method name="open">
			<arglist>
				<arg name="subpatch-filename" optional="0" type="int" />
			</arglist>
			<digest>
				Open the loaded subpatch
			</digest>
			<description>
				The word <m>open</m> will open the subpatch loaded into the <o>pfft~</o> object.
			</description>
		</method>
		<method name="wclose">
			<arglist>
				<arg name="subpatch-filename" optional="0" type="int" />
			</arglist>
			<digest>
				Close the loaded subpatch
			</digest>
			<description>
				Closes the enclosed subpatch if it is open.
			</description>
		</method>
	</methodlist>
	<!--ATTRIBUTES-->
	<attributelist />
	<!--EXAMPLE-->
	<examplelist>
		<example img="pfft~.png" caption="pfft~ loads subpatchers specially designed for frequency domain processing" />
	</examplelist>
	<!--SEEALSO-->
	<seealsolist>
		<seealso name="cartopol" />
		<seealso name="cartopol~" />
		<seealso name="fft~" />
		<seealso name="fftin~" />
		<seealso name="fftinfo~" />
		<seealso name="fftout~" />
		<seealso name="frameaccum~" />
		<seealso name="framedelta~" />
		<seealso name="ifft~" />
		<seealso name="in" />
		<seealso name="out" />
		<seealso name="poltocar" />
		<seealso name="poltocar~" />
		<seealso name="vectral~" />
		<seealso name="14_analysischapter03" module="msp" type="tutorial" />
		<seealso name="14_analysischapter04" module="msp" type="tutorial" />
	</seealsolist>
	<discussion>
		The number of inlets on the <o>pfft~</o> object is determined by the number of <o>fftin~</o> and/or in objects in the enclosed subpatch. Patchers loaded into a <o>pfft~</o> object can only be given signal inlets by <o>fftin~</o> objects within the patch. See <o>fftin~</o> and in for details.
	</discussion>
	<misc name="Output">
		<entry name="signal">
			<description>
				The output is the result of the FFT-based signal processing subpatch. As with the <o>fft~</o> and <o>ifft~</o> objects, <o>pfft~</o> introduces a slight delay from input to output (although it is less than half the delay than with an <o>fft~</o>/ <o>ifft~</o> combination). The I/ O delay is equal to the window size minus the hop size (e.g., for a 1024-sample FFT window with an overlap factor of 4, the hop size is equal to 256, and the overall delay from input to output is 768 samples). The number of outlets is determined by the number of <o>fftout~</o> and/or <o>out</o> objects in the loaded subpatcher. Patchers loaded into a <o>pfft~</o> object can be given outlets by <o>fftout~</o> or <o>out</o> objects within the patch. See <o>fftout~</o> and <o>out</o> for details.
			</description>
		</entry>
		<entry name="message">
			<description>
				Any messages received by an <o>out</o> object in a loaded patcher appear at the message outlet of the <o>pfft~</o> object which corresponds to the number argument of the <o>out</o> object. The message outlets of a <o>pfft~</o> object appear to the right of the rightmost signal outlet.
			</description>
		</entry>
	</misc>
</c74object>
