Difference between revisions of "SoundData:getSample"

m
(Arguments: Added notice to input parameters not being interpolated, to thwart any assumptions.)
Line 6: Line 6:
 
</source>
 
</source>
 
=== Arguments ===
 
=== Arguments ===
{{param|number|i|The position of the sample (0 means first sample).}}
+
{{param|number|i|The position of the sample (0 means first sample). Values are not interpolated, so use whole numbers only.}}
 +
 
 
=== Returns ===
 
=== Returns ===
 
{{param|number|sample|The normalized sample (range -1.0 to 1.0).}}
 
{{param|number|sample|The normalized sample (range -1.0 to 1.0).}}

Revision as of 18:53, 15 January 2017

Gets the sample at the specified position.

Function

Synopsis

sample = SoundData:getSample( i )

Arguments

number i
The position of the sample (0 means first sample). Values are not interpolated, so use whole numbers only.

Returns

number sample
The normalized sample (range -1.0 to 1.0).

See Also


Other Languages