<?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="pong" module="max" category="Math">
	<digest>
		Range limiting
	</digest>
	<description>
		Use the <o>pong</o> object to clip, fold, or wrap its input within the range of a low value and a high value.
	</description>
	<!--METADATA-->
	<metadatalist>
		<metadata name="author">
			Cycling '74
		</metadata>
		<metadata name="tag">
			MSP
		</metadata>
	</metadatalist>
	<!--INLETS-->
	<inletlist>
		<inlet id="0" type="INLET_TYPE">
			<digest>
				Float Input
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
		<inlet id="1" type="INLET_TYPE">
			<digest>
				(float) Lo val
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
		<inlet id="2" type="INLET_TYPE">
			<digest>
				(float) Hi val
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
	</inletlist>
	<!--OUTLETS-->
	<outletlist>
		<outlet id="0" type="signal">
			<digest>
				(float) Output
			</digest>
			<description>
				TEXT_HERE
			</description>
		</outlet>
	</outletlist>
	<!--ARGUMENTS-->
	<objarglist>
		<!--
    <objarg name='folding-mode' optional='1' type='int'>
      <digest> TEXT_HERE </digest>
      <description>
         An optional argument is used to set the mode of the
        <o>pong~</o>
         A 0 sets signal folding (the default), and a 1 sets signal wrapping
        (see the
        <m>mode</m>
         message).
      </description>
    </objarg>
	-->
		<objarg name="low-value" optional="1" type="float">
			<digest>
				Default low range boundary
			</digest>
			<description>
				Default low range boundary
			</description>
		</objarg>
		<objarg name="high-value" optional="1" type="float">
			<digest>
				Default high range boundary
			</digest>
			<description>
				Default high range boundary
			</description>
		</objarg>
	</objarglist>
	<!--MESSAGES-->
	<methodlist>
		<method name="int">
			<arglist>
				<arg name="input" optional="0" type="int" />
			</arglist>
			<digest>
				Converted to <m>float</m>.
			</digest>
			<description>
				TEXT_HERE
			</description>
		</method>
		<method name="float">
			<arglist>
				<arg name="input" optional="0" type="float" />
			</arglist>
			<digest>
				Function depends on inlet
			</digest>
			<description>
				In left inlet: All incoming float values which exceed the high or low value ranges specified by arguments to the <o>pong</o> object are either folded back into this range, wrapped, or clipped according to the <at>mode</at> of the <o>pong</o> object.
				<br />
				<br />
				In center inlet: Sets the low range boundary for the <o>pong</o> object.
				<br />
				<br />
				In right inlet: Sets the high range boundary for the <o>pong</o> object.
			</description>
		</method>
		<method name="list">
			<arglist>
				<arg name="input" optional="0" type="float" />
			</arglist>
			<digest>
				Limit the values of numbers in a list
			</digest>
			<description>
				In left inlet: Lists of numbers are processed together as per the <m>float</m> entry.
			</description>
		</method>
	</methodlist>
	<!--ATTRIBUTES-->
	<attributelist>
		<attribute name="mode" get="1" set="1" type="symbol" size="1">
			<digest>
				Behaviour of limiting when input exceeds range
			</digest>
			<description>
				Behaviour of limiting when input exceeds range. Options are clip, wrap, and fold.
			</description>
			<attributelist>
				<attribute name="default" get="1" set="1" type="symbol" size="1" value="none" />
				<attribute name="enumvals" get="1" set="1" type="atom" size="4">
					<enumlist>
						<enum name="none">
							<digest>
								TEXT_HERE
							</digest>
							<description>
								TEXT_HERE
							</description>
						</enum>
						<enum name="clip">
							<digest>
								TEXT_HERE
							</digest>
							<description>
								TEXT_HERE
							</description>
						</enum>
						<enum name="wrap">
							<digest>
								TEXT_HERE
							</digest>
							<description>
								TEXT_HERE
							</description>
						</enum>
						<enum name="fold">
							<digest>
								TEXT_HERE
							</digest>
							<description>
								TEXT_HERE
							</description>
						</enum>
					</enumlist>
				</attribute>
				<attribute name="style" get="1" set="1" type="symbol" size="1" value="enum" />
			</attributelist>
		</attribute>
		<attribute name="range" get="1" set="1" type="float" size="2">
			<digest>
				The range within which to keep values
			</digest>
			<description>
				The range within which to keep values. Values outside of this range will be subject to a limiting algorithm chosen by the mode attribute.
			</description>
		</attribute>
	</attributelist>
	<!--EXAMPLE-->
	<examplelist>
		<example img="pong.png" caption="pong limits the range of an input by folding it or wrapping it around an upper and lower threshold level" />
	</examplelist>
	<!--SEEALSO-->
	<seealsolist>
		<seealso name="clip" />
		<seealso name="pong~" />
	</seealsolist>
</c74object>
