メインコンテンツ

platonicSolidLoudspeakerLayout

Platonic solid loudspeaker layout coordinates

Since R2026a

    Description

    LSSph = platonicSolidLoudspeakerLayout returns the spatial location, in spherical coordinates, of each loudspeaker in a default tetrahedral grid.

    example

    LSSph = platonicSolidLoudspeakerLayout(Name=Value) specifies options using one or more name-value arguments. For example, to specify the polyhedral shape, set Layout.

    example

    platonicSolidLoudspeakerLayout is a convenience syntax that plots a default tetrahedral grid.

    example

    platonicSolidLoudspeakerLayout(Name=Value) is a convenience syntax that plots a platonic solid grid using the options specified in the name-value arguments.

    example

    Examples

    collapse all

    Decode an ambisonic-encoded signal to a dodecahedron loudspeaker layout and plot the layout.

    Read in an ambisonic-encoded signal.

    [audioIn,fs] = audioread("Heli_16ch_ACN_SN3D.wav");

    Define a dodecahedron loudspeaker layout.

    loudspeakers = platonicSolidLoudspeakerLayout(Layout="dodecahedron");

    Plot the dodecahedron layout grid.

    platonicSolidLoudspeakerLayout(Layout="dodecahedron")

    Figure contains an axes object. The axes object with title Dodecahedron Grid. Number of Loudspeakers = 20., xlabel x (m), ylabel y (m) contains an object of type patch.

    Design the decoding matrix with an order of three.

    dmtrx = ambisonicDecoderMatrix(3, loudspeakers,...
            Normalization="sn3d",ChannelOrder="acn");

    Decode the signal to the dodecahedron loudspeaker layout.

    audioOut = audioIn*dmtrx;

    Name-Value Arguments

    collapse all

    Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

    Example: Pcoords = platonicSolidLoudspeakerLayout(Layout="dodecahedron")

    Platonic solid layout shape, specified as one of "tetrahedron", "hexahedron", "octahedron", "icosahedron", or "dodecahedron". Polyhedral grids based on the tetrahedron, hexahedron, octahedron, icosahedron, and dodecahedron have four, eight, six, twelve, and twenty loudspeaker locations, respectively. The default value of "tetrahedron" generates four loudspeaker locations.

    Data Types: char | string

    Output data type, specified as "double" or "single". Set this argument to "single" to force all matrix computations to be performed in single precision.

    Data Types: char | string

    Output Arguments

    collapse all

    Spatial location of each loudspeaker in spherical coordinates, returned as an N-by-2 matrix, where N is the number of loudspeakers. The first column corresponds to the azimuth, and the second column corresponds to the elevation. The azimuth values are in the range [0,360], and the elevation values are in the range [–90,90]. Units are in degrees.

    Extended Capabilities

    expand all

    C/C++ Code Generation
    Generate C and C++ code using MATLAB® Coder™.

    Version History

    Introduced in R2026a