A sound reframer context that can reframe sound chunks into consistent durations. More...
Public Member Functions | |
| void | addOnFrame (fm.liveswitch.IAction1< fm.liveswitch.AudioFrame > value) |
| Adds a handler that is raised when a frame is ready. More... | |
| fm.liveswitch.AudioConfig | getConfig () |
| Gets the config. More... | |
| boolean | getDisableTimestampReset () |
| Gets whether timestamp resetting should be disabled entirely. More... | |
| boolean | getForceTimestampReset () |
| Gets whether to force a timestamp reset with the next raised frame. More... | |
| int | getFrameDuration () |
| Gets the frame duration. More... | |
| int | getTimestampResetInterval () |
| Gets the amount of time in milliseconds between audio frames that will trigger a wall-clock reset of the timestamp. More... | |
| void | processFrame (fm.liveswitch.AudioFrame frame, fm.liveswitch.AudioBuffer inputBuffer) |
| Processes a frame. More... | |
| void | removeOnFrame (fm.liveswitch.IAction1< fm.liveswitch.AudioFrame > value) |
| Removes a handler that is raised when a frame is ready. More... | |
| void | setDisableTimestampReset (boolean value) |
| Sets whether timestamp resetting should be disabled entirely. More... | |
| void | setForceTimestampReset (boolean value) |
| Sets whether to force a timestamp reset with the next raised frame. More... | |
| void | setTimestampResetInterval (int value) |
| Sets the amount of time in milliseconds between audio frames that will trigger a wall-clock reset of the timestamp. More... | |
| SoundReframerContext (int frameDuration, fm.liveswitch.AudioConfig config) | |
| Initializes a new instance of the fm.liveswitch.SoundReframerContext class. More... | |
Protected Member Functions | |
| long | autoTimestamp (int timestampDelta) |
| Gets the next timestamp. More... | |
A sound reframer context that can reframe sound chunks into consistent durations.
| fm.liveswitch.SoundReframerContext.SoundReframerContext | ( | int | frameDuration, |
| fm.liveswitch.AudioConfig | config | ||
| ) |
Initializes a new instance of the fm.liveswitch.SoundReframerContext class.
| frameDuration | The frame duration. |
| config | The configuration. |
| void fm.liveswitch.SoundReframerContext.addOnFrame | ( | fm.liveswitch.IAction1< fm.liveswitch.AudioFrame > | value | ) |
Adds a handler that is raised when a frame is ready.
|
protected |
Gets the next timestamp.
| fm.liveswitch.AudioConfig fm.liveswitch.SoundReframerContext.getConfig | ( | ) |
Gets the config.
| boolean fm.liveswitch.SoundReframerContext.getDisableTimestampReset | ( | ) |
Gets whether timestamp resetting should be disabled entirely.
Only applies if timestamps are auto-generated (i.e. not set on the frames).
| boolean fm.liveswitch.SoundReframerContext.getForceTimestampReset | ( | ) |
Gets whether to force a timestamp reset with the next raised frame.
If set to
, this value will be reset to
after the wall-clock reset takes place. Only applies if timestamps are auto-generated (i.e. not set on the frames).
| int fm.liveswitch.SoundReframerContext.getFrameDuration | ( | ) |
Gets the frame duration.
| int fm.liveswitch.SoundReframerContext.getTimestampResetInterval | ( | ) |
Gets the amount of time in milliseconds between audio frames that will trigger a wall-clock reset of the timestamp.
Only applies if timestamps are auto-generated (i.e. not set on the frames). Defaults to 1000.
| void fm.liveswitch.SoundReframerContext.processFrame | ( | fm.liveswitch.AudioFrame | frame, |
| fm.liveswitch.AudioBuffer | inputBuffer | ||
| ) |
Processes a frame.
| frame | The frame. |
| inputBuffer | The input buffer. |
| void fm.liveswitch.SoundReframerContext.removeOnFrame | ( | fm.liveswitch.IAction1< fm.liveswitch.AudioFrame > | value | ) |
Removes a handler that is raised when a frame is ready.
| void fm.liveswitch.SoundReframerContext.setDisableTimestampReset | ( | boolean | value | ) |
Sets whether timestamp resetting should be disabled entirely.
Only applies if timestamps are auto-generated (i.e. not set on the frames).
| void fm.liveswitch.SoundReframerContext.setForceTimestampReset | ( | boolean | value | ) |
Sets whether to force a timestamp reset with the next raised frame.
If set to
, this value will be reset to
after the wall-clock reset takes place. Only applies if timestamps are auto-generated (i.e. not set on the frames).
| void fm.liveswitch.SoundReframerContext.setTimestampResetInterval | ( | int | value | ) |
Sets the amount of time in milliseconds between audio frames that will trigger a wall-clock reset of the timestamp.
Only applies if timestamps are auto-generated (i.e. not set on the frames). Defaults to 1000.