You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/audiodocs/docs/core/audio-param.mdx
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -41,7 +41,7 @@ as they are more efficient for continuous changes. For more specific use cases,
41
41
| Parameter | Type | Description |
42
42
| :---: | :---: | :---- |
43
43
|`value`|`number`| A float representing the value the `AudioParam` will be set at given time |
44
-
|`startTime`|`number`| The time, in seconds, at which the change in value is going to happen. |
44
+
|`startTime`|`number`| The time, in seconds, at which the change in value is going to happen. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties). |
45
45
46
46
#### Errors:
47
47
@@ -61,7 +61,7 @@ The change begins at the time designated for the previous event. It follows a li
61
61
| Parameter | Type | Description |
62
62
| :---: | :---: | :---- |
63
63
|`value`|`number`| A float representing the value, the `AudioParam` will ramp to by given time. |
64
-
|`endTime`|`number`| The time, in seconds, at which the value ramp will end. |
64
+
|`endTime`|`number`| The time, in seconds, at which the value ramp will end. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties). |
65
65
66
66
#### Errors
67
67
@@ -81,7 +81,7 @@ The change begins at the time designated for the previous event. It follows an e
81
81
| Parameter | Type | Description |
82
82
| :---: | :---: | :---- |
83
83
|`value`|`number`| A float representing the value the `AudioParam` will ramp to by given time. |
84
-
|`endTime`|`number`| The time, in seconds, at which the value ramp will end. |
84
+
|`endTime`|`number`| The time, in seconds, at which the value ramp will end. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties).|
85
85
86
86
#### Errors
87
87
@@ -101,7 +101,7 @@ This method is useful for decay or release portions of [ADSR envelopes](/docs/ef
101
101
| Parameter | Type | Description |
102
102
| :---: | :---: | :---- |
103
103
|`target`|`number`| A float representing the value to which the `AudioParam` will start transitioning. |
104
-
|`startTime`|`number`| The time, in seconds, at which exponential transition will begin. |
104
+
|`startTime`|`number`| The time, in seconds, at which exponential transition will begin. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties). |
105
105
|`timeConstant`|`number`| A double representing the time-constant value of an exponential approach to the `target`. |
106
106
107
107
#### Errors
@@ -122,7 +122,7 @@ Schedules the parameters's value change following a curve defined by given array
122
122
| Parameter | Type | Description |
123
123
| :---: | :---: | :---- |
124
124
|`values`|`Float32Array`| The array of values defining a curve, which change will follow. |
125
-
|`startTime`|`number`| The time, in seconds, at which change will begin. |
125
+
|`startTime`|`number`| The time, in seconds, at which change will begin. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties). |
126
126
|`duration`|`number`| A double representing total time over which the change will happen. |
127
127
128
128
#### Errors
@@ -139,7 +139,7 @@ Cancels all scheduled changes after given cancel time.
139
139
140
140
| Parameter | Type | Description |
141
141
| :---: | :---: | :---- |
142
-
|`cancelTime`|`number`| The time, in seconds, after which all scheduled changes will be cancelled. |
142
+
|`cancelTime`|`number`| The time, in seconds, after which all scheduled changes will be cancelled. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties). |
143
143
144
144
#### Errors
145
145
@@ -155,7 +155,7 @@ Cancels all scheduled changes after given cancel time, but holds its value at gi
155
155
156
156
| Parameter | Type | Description |
157
157
| :---: | :---: | :---- |
158
-
|`cancelTime`|`number`| The time, in seconds, after which all scheduled changes will be cancelled. |
158
+
|`cancelTime`|`number`| The time, in seconds, after which all scheduled changes will be cancelled. If it's smaller than [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties), it will be clamped to [`currentTime`](https://docs.swmansion.com/react-native-audio-api/docs/core/base-audio-context#properties).|
0 commit comments