class SFML::SoundCone

Directional-attenuation cone for a 3D sound source. Inside the inner_angle cone the sound plays at full volume; outside the outer_angle cone it’s attenuated by outer_gain; between the two it’s smoothly interpolated.

Angles are in degrees, measured from the source’s direction axis. outer_gain is a scalar in [0, 1] (0 = silent outside).

sound.direction = [0, 0, -1] sound.cone = SFML::SoundCone.new( inner_angle: 30, outer_angle: 90, outer_gain: 0.2, )