Point Source

class visr::objectmodel::PointSource

Public Functions

virtual std::unique_ptr<Object> clone() const

Clone function used to emulate ‘virtual copy constructor’ functionality. Must be implemented in every derived instantiated class.

bool channelLock() const

Query whether the “channel lock” feature is active. In this case, the sound source is moved to the nearest loudspeaker if the angular distance to the nearest loudspeaker is less than channelLockDistance().

PointSource::Coordinate channelLockDistance() const

Return the currently set channel lock distance (angular distance in degree). If the channel lock feature is inactive, 0 is returned. The “always lock” setting returns +inf.

void setChannelLock(Coordinate newDistance)

Set the channel lock distance. When called with a nonzero value, channel lock is automatically activated. A value >= 180 (degree) or the default value (+inf) corresponds to “always lock”.

void unsetChannelLock()

Deactivate the channel lock feature. This sets the lock distance to zero.

Private Members

Coordinate mChannelLockDistance

Representation of the channel lock distance, in degree. A value of zero corresponds to “no channel lock”, while any value >=180 means “always lock”.

Private Static Attributes

const Object::Coordinate cAlwaysChannelLock

Special value to denote that the object is in “always lock” mode.

const Object::Coordinate cNoChannelLock

Special value to denote that the object is in “no channel lock” mode.