OpenShot Audio Library | OpenShotAudio: juce::Thread::RealtimeOptions Struct Reference

OpenShot Audio Library | OpenShotAudio 0.4.0

Loading...
Searching...
No Matches
Public Member Functions | List of all members
juce::Thread::RealtimeOptions Struct Reference

`#include <juce_Thread.h>`

## Public Member Functions
RealtimeOptions | withPriority (int newPriority) const
RealtimeOptions | withProcessingTimeMs (double newProcessingTimeMs) const
RealtimeOptions | withMaximumProcessingTimeMs (double newMaximumProcessingTimeMs) const
RealtimeOptions | withApproximateAudioProcessingTime (int samplesPerFrame, double sampleRate) const
RealtimeOptions | withPeriodMs (double newPeriodMs) const
RealtimeOptions | withPeriodHz (double newPeriodHz) const
int | getPriority () const
std::optional< double > | getProcessingTimeMs () const
std::optional< double > | getMaximumProcessingTimeMs () const
std::optional< double > | getPeriodMs () const

## Detailed Description

A selection of options available when creating realtime threads.

See also
  startRealtimeThread

Definition at line 76 of file juce_Thread.h.

## Member Function Documentation

## ◆ getMaximumProcessingTimeMs()

std::optional< double > juce::Thread::RealtimeOptions::getMaximumProcessingTimeMs | ( |  | ) | const
| inlinenodiscard

Returns the maximum amount of processing time required each time the thread wakes up.

See also
  withMaximumProcessingTimeMs, getProcessingTimeMs, getPeriodMs

Definition at line 185 of file juce_Thread.h.

## ◆ getPeriodMs()

std::optional< double > juce::Thread::RealtimeOptions::getPeriodMs | ( |  | ) | const
| inlinenodiscard

Returns the approximate amount of time between each thread wake up, or nullopt if there is no inherent periodicity.

See also
  withPeriodMs, withPeriodHz, getProcessingTimeMs, getMaximumProcessingTimeMs

Definition at line 195 of file juce_Thread.h.

## ◆ getPriority()

int juce::Thread::RealtimeOptions::getPriority | ( |  | ) | const
| inlinenodiscard

Returns a value with a range of 0-10, where 10 is the highest priority.

See also
  withPriority

Definition at line 165 of file juce_Thread.h.

## ◆ getProcessingTimeMs()

std::optional< double > juce::Thread::RealtimeOptions::getProcessingTimeMs | ( |  | ) | const
| inlinenodiscard

Returns the expected amount of processing time required each time the thread wakes up.

See also
  withProcessingTimeMs, getMaximumProcessingTimeMs, getPeriodMs

Definition at line 175 of file juce_Thread.h.

## ◆ withApproximateAudioProcessingTime()

RealtimeOptions juce::Thread::RealtimeOptions::withApproximateAudioProcessingTime | ( | int | samplesPerFrame,
|  | double | sampleRate ) const
| inlinenodiscard

Specify the maximum amount of processing time required each time the thread wakes up.

This is identical to 'withMaximumProcessingTimeMs' except it calculates the processing time from a sample rate and block size. This is useful if you want to run this thread in parallel to an audio device thread.

Only used by macOS/iOS.

See also
  withMaximumProcessingTimeMs, AudioWorkgroup, ScopedWorkgroupToken

Definition at line 124 of file juce_Thread.h.

## ◆ withMaximumProcessingTimeMs()

RealtimeOptions juce::Thread::RealtimeOptions::withMaximumProcessingTimeMs | ( | double | newMaximumProcessingTimeMs | ) | const
| inlinenodiscard

Specify the maximum amount of processing time required each time the thread wakes up.

Only used by macOS/iOS.

See also
  getMaximumProcessingTimeMs, withProcessingTimeMs, withPeriodMs, withPeriodHz

Definition at line 108 of file juce_Thread.h.

## ◆ withPeriodHz()

RealtimeOptions juce::Thread::RealtimeOptions::withPeriodHz | ( | double | newPeriodHz | ) | const
| inlinenodiscard

Specify the approximate frequency at which the thread will be woken up.

Alternatively call withPeriodMs().

Only used by macOS/iOS.

See also
  getPeriodHz, withPeriodMs, withProcessingTimeMs, withMaximumProcessingTimeMs,

Definition at line 155 of file juce_Thread.h.

## ◆ withPeriodMs()

RealtimeOptions juce::Thread::RealtimeOptions::withPeriodMs | ( | double | newPeriodMs | ) | const
| inlinenodiscard

Specify the approximate amount of time between each thread wake up.

Alternatively call withPeriodHz().

Only used by macOS/iOS.

See also
  getPeriodMs, withPeriodHz, withProcessingTimeMs, withMaximumProcessingTimeMs,

Definition at line 141 of file juce_Thread.h.

## ◆ withPriority()

RealtimeOptions juce::Thread::RealtimeOptions::withPriority | ( | int | newPriority | ) | const
| inlinenodiscard

A value with a range of 0-10, where 10 is the highest priority.

Currently only used by Posix platforms.

See also
  getPriority

Definition at line 84 of file juce_Thread.h.

## ◆ withProcessingTimeMs()

RealtimeOptions juce::Thread::RealtimeOptions::withProcessingTimeMs | ( | double | newProcessingTimeMs | ) | const
| inlinenodiscard

Specify the expected amount of processing time required each time the thread wakes up.

Only used by macOS/iOS.

See also
  getProcessingTimeMs, withMaximumProcessingTimeMs, withPeriodMs, withPeriodHz

Definition at line 96 of file juce_Thread.h.

The documentation for this struct was generated from the following file:

- juce_Thread.h