VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Signals | Public Member Functions | Private Slots | Private Attributes
makVrv::DtProceduralSoundLayerPlayer Class Reference

Owns a single one-layer procedural-sound audition on behalf of DtProceduralSoundsSettingsWidget.

Builds a DtProceduralSound wrapping just the selected layer, ticks it at ~30 Hz via a QTimer, and forwards live gain/pitch/scheduling changes into the running stream so the user hears property edits immediately.

Emits signal_playbackStateChanged() when the play/stop state flips so the settings widget can update its Play/Stop button text.

Inheritance diagram for makVrv::DtProceduralSoundLayerPlayer:
Inheritance graph
[legend]

Signals

void signal_playbackStateChanged (bool playing)
 

Public Member Functions

 DtProceduralSoundLayerPlayer (DtDe &de, QObject *parent=nullptr)
 
virtual ~DtProceduralSoundLayerPlayer ()
 
void startPreview (const DtProceduralLayerConfig &layer)
 
void stopPreview ()
 
void refreshLiveParameters (const DtProceduralLayerConfig &layer)
 
bool isPlaying () const
 

Private Slots

void slot_onTick ()
 

Private Attributes

DtDe & myDe
 
DtProceduralLayerConfig myCurrentLayer
 
DtProceduralSound * myPreviewSound
 
QTimer * myTickTimer
 

Constructor & Destructor Documentation

makVrv::DtProceduralSoundLayerPlayer::DtProceduralSoundLayerPlayer ( DtDe &  de,
QObject *  parent = nullptr 
)
explicit

CTOR.

Parameters
deDisplay engine used to reach DtAudioManager.
parentOptional QObject parent (typically the settings widget).
virtual makVrv::DtProceduralSoundLayerPlayer::~DtProceduralSoundLayerPlayer ( )
virtual

DTOR. Stops any active preview before destruction.

Member Function Documentation

void makVrv::DtProceduralSoundLayerPlayer::startPreview ( const DtProceduralLayerConfig &  layer)

Start a preview of layer. Stops any prior preview first.

No-op if the layer has zero clips or if the audio playback device fails to initialize.

Parameters
layerLayer configuration to audition.
void makVrv::DtProceduralSoundLayerPlayer::stopPreview ( )

Stop any active preview and release the underlying stream.

void makVrv::DtProceduralSoundLayerPlayer::refreshLiveParameters ( const DtProceduralLayerConfig &  layer)

Push a live property update to a running preview. Does nothing when no preview is active.

Parameters
layerLatest layer configuration; only gain/pitch/rate fields are applied to the live stream.
bool makVrv::DtProceduralSoundLayerPlayer::isPlaying ( ) const

Return true when a preview is currently playing.

void makVrv::DtProceduralSoundLayerPlayer::signal_playbackStateChanged ( bool  playing)
signal

Emitted when the play/stop state flips.

Parameters
playingtrue when a preview just started, false when stopped.
void makVrv::DtProceduralSoundLayerPlayer::slot_onTick ( )
privateslot

Periodic tick slot (QTimer, ~30 Hz) driving DtProceduralSound::tick().

Member Data Documentation

DtDe& makVrv::DtProceduralSoundLayerPlayer::myDe
private

Display engine reference (borrowed).

DtProceduralLayerConfig makVrv::DtProceduralSoundLayerPlayer::myCurrentLayer
private

Copy of the currently-playing layer configuration.

DtProceduralSound* makVrv::DtProceduralSoundLayerPlayer::myPreviewSound
private

nullptr when not playing.

QTimer* makVrv::DtProceduralSoundLayerPlayer::myTickTimer
private

Drives slot_onTick() at ~30 Hz.


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

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)