immersive-home/docs/reference/lib--utils--sample_hold.md
2024-03-17 00:14:31 +01:00

27 lines
1.5 KiB
Markdown

# SampleHold
**Inherits:** [RefCounted](https://docs.godotengine.org/de/4.x/classes/class_refcounted.html)
## Methods
| Returns | Name |
| ----------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [PackedFloat32Array](https://docs.godotengine.org/de/4.x/classes/class_packedfloat32array.html) | [sample_and_hold](#sample-and-hold) ( data: [PackedVector2Array](https://docs.godotengine.org/de/4.x/classes/class_packedvector2array.html), sample_rate: [float](https://docs.godotengine.org/de/4.x/classes/class_float.html) ) |
## Method Descriptions
### static sample_and_hold (data: [PackedVector2Array](https://docs.godotengine.org/de/4.x/classes/class_packedvector2array.html) , sample_rate: [float](https://docs.godotengine.org/de/4.x/classes/class_float.html) ) -> [PackedFloat32Array](https://docs.godotengine.org/de/4.x/classes/class_packedfloat32array.html) {#sample-and-hold}
Reduces the frequency of a signal by sampling and holding the data