VirtualRoom:
Filter:
AmbIEM/Classes (extension) | Libraries > AmbIEM | UGens > Multichannel > Ambisonics

VirtualRoom
ExtensionExtension

Easy to use class for creation of virtual environments

Description

A convenience class for easy creation and management of virtual audio environments. The rendering is done in a class method (ar) while multiple instances of a VirtualRoom may be defined to be able to switch between them (its also possible to play them simultaniously, if that makes sense to some application).

Class Methods

.new

.maxSources

.kemarPath

Instance Methods

.room

Arguments:

value

.bin

.hfDamping

Arguments:

value

.roomProperties

.refGain

Arguments:

value

.play

.init

.gui

.addSource

Arguments:

source
key
x
y
z

.removeSource

Arguments:

key

.stop

.out

.roomSize

.fullSourceFunc

Arguments:

source

.addSourceLight

Arguments:

source
key
x
y
z

.encoded

.end

Arguments:

fadeTime

.sources

.lightSourceFunc

Arguments:

source

.revIn

.listener

.revGain

Arguments:

value

.prAddSource

Arguments:

light
source
key
x
y
z

Examples

NOTE: For better performance the following server options should be set before booting the server.

First thing is to set the path to the full Kemar HRTFs (dowloadable from http://sound.media.mit.edu/KEMAR/full.tar.Z). Default is "KemarHRTF/" (located in the SC3 application folder)

Then init the class - that will switch on the rendering (and consumes CPU) and route the output to the standard output with .play

NOTE: The coordinate system is given according to the listener's head: x-axis (nose), y-axis (left-ear) and z-axis (vertex) and Rooms are defined by the origin and width/depth/height