private void applySourceDirectionalState(int sourceId, AudioSource src) {
        if (src.isDirectional()) {
            Vector3f dir = src.getDirection();
            al.alSource3f(sourceId, AL_DIRECTION, dir.x, dir.y, dir.z);
            al.alSourcef(sourceId, AL_CONE_INNER_ANGLE, src.getInnerAngle());
            al.alSourcef(sourceId, AL_CONE_OUTER_ANGLE, src.getOuterAngle());
            al.alSourcef(sourceId, AL_CONE_OUTER_GAIN, 0);
        } else {
            // Omnidirectional: 360 degree cone, full gain
            al.alSourcef(sourceId, AL_CONE_INNER_ANGLE, 360f);
            al.alSourcef(sourceId, AL_CONE_OUTER_ANGLE, 360f);
            al.alSourcef(sourceId, AL_CONE_OUTER_GAIN, 1f);
        }
    }
Sets cone angles/gain based on whether the source is directional
jme3-core/src/main/java/com/jme3/audio/openal/ALAudioRenderer.java