Unity¤Ë´ØÏ¢¤¹¤ëµ­»ö¤Ç¤¹

¡¡¥¹¥¯¥ê¥×¥È¤«¤é¤Î AudioMixer ¤ØÌ¿Îá¤ò½Ð¤·¡¢¥²¡¼¥àÆâ¤ÇưŪ¤Ë¥Ü¥ê¥å¡¼¥à¤òÀ©¸æ¤¹¤ë¤³¤È¤¬²Äǽ¤Ç¤¹¡£
¤¿¤À¤·¡¢¥¹¥¯¥ê¥×¥ÈÆâ¤ËÌ¿Îá¤òÍÑ°Õ¤¹¤ë¤À¤±¤Ç¤ÏÀ©¸æ¤¬¤Ç¤­¤º¡¢Àµ¤·¤¤ÀßÄ꤬¤Ç¤­¤Æ¤¤¤Ê¤¤¤È¡¢²¼µ­¤Î¤è¤¦¤Ê¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£





¡¡¤³¤Î¼ê½ç¤Ç¤Ï AudioMixer ¤ÎÀßÄê¤ò½çÈ֤˹Ԥ俾å¤Ç¡¢É¬Íפʥ¹¥¯¥ê¥×¥È¤òÍÑ°Õ¤·¤Æ¤¤¤¯¼ÂÁõ¤ò¹Ô¤¤¤Þ¤¹¡£

¡¡Æä˥¹¥é¥¤¥À¡¼¤ÈÁȤ߹ç¤ï¤»¤ÆÍøÍѤ¹¤ë¤³¤È¤¬Â¿¤¤¤¿¤á¡¢²¼µ­¤Î¤è¤¦¤Ê·Á¤Ç¤Î¼ÂÁõ¤òÌÜɸ¤Ë¤·¤Æ¤ª¤¯¤È¤è¤¤¤Ç¤·¤ç¤¦¡£


¼ÂÁõÆ°²è





£±¡¥AudioMixer ¤ÎÀßÄê


¡¡¥¹¥¯¥ê¥×¥È¤Ç AudioMixer ¤ÎÀßÄê¤òưŪ¤ËÊѹ¹¤¹¤ë¤¿¤á¤Ë¤Ï¡¢»öÁ°¤Ë AudioMixer ¤ÎÀßÄ꤬ɬÍפˤʤê¤Þ¤¹¡£

¡¡¥¹¥¯¥ê¥×¥È¤«¤éÁàºî¤·¤¿¤¤ AudioMixer ¤òÁªÂò¤·¡¢¥¤¥ó¥¹¥Ú¥¯¥¿¡¼¤Ë¤¢¤ë Attenuation ¤Î¾å¤Ç±¦¥¯¥ê¥Ã¥¯¤ò¤·¤Æ¥á¥Ë¥å¡¼¤òɽ¼¨¤·¤Þ¤¹¡£
¡¡
¡¡¥á¥Ë¥å¡¼Æâ¤Î¡ÚExpose 'Volume(of Master) ' to script¡Û¤òÁªÂò¤·¤Þ¤¹¡£




¡¡¤¹¤ë¤È Volume ¤Îɽ¼¨¤Î²£¤Ë ¢ª ¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£
¤³¤Îɽ¼¨¤¬½Ð¤ì¤Ð¡¢¥¹¥¯¥ê¥×¥È¤«¤é¤ÎÀÚ¤êÂؤ¨ÀßÄ꤬¤Ç¤­¤Æ¤¤¤Þ¤¹¡£




¡¡¤â¤·¤â°ÊÁ°¤Î¾õÂÖ¤ËÌᤷ¤¿¤¤¾ì¹ç¤Ë¤Ï¡¢ºÆÅÙƱ¤¸°ÌÃ֤DZ¦¥¯¥ê¥Ã¥¯¤·¤Æ¥á¥Ë¥å¡¼¤òɽ¼¨¤·
¡ÚUnexpose¡Û¤òÁªÂò¤¹¤ë¤È ¢ª ¤¬¾Ã¤¨¡¢¸µ¤Î¤è¤¦¤Ë¥¹¥¯¥ê¥×¥È¤«¤é¤ÏÀ©¸æ¤¬¤Ç¤­¤Ê¤¤¾õÂÖ¤ËÌ᤹¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£





£²¡¥AudioMixer ¥¦¥¤¥ó¥É¥¦¤ÎÀßÄê


¡¡Â³¤¤¤Æ¡¢AudioMixer ¥¦¥¤¥ó¥É¥¦¤ÇÀßÄê¤ò¹Ô¤¤¤Þ¤¹¡£
ÀßÄꤷ¤¿¤¤ AudioMixer ¤òÁªÂò¤·¤Æ¤¤¤ë¾õÂÖ¤Ç AudioMixer ¥¦¥¤¥ó¥É¥¦¤òɽ¼¨¤·¤Þ¤¹¡£

¡¡²¼µ­¤Î¾ì¹ç¤Ç¤¢¤ì¤Ð¡¢Master ¤Î AudioMixerGroup ¤òÁªÂò¤·¤Æ¤¤¤ë¾õÂ֤Ǥ¹¡£





¡¡¡Ú£±¡Û¤Î¼ê½ç¤ò¹Ô¤Ã¤Æ¤¤¤ë¤È¡¢AudioMixer ¥¦¥¤¥ó¥É¥¦¤Î±¦¾å¤Îü¤Ë¡ÚExposed Parameters¡Û¤Î¹àÌܤ¬É½¼¨¤µ¤ì¤Æ¤¤¤Þ¤¹¡£
ÀßÄꤷ¤Æ¤¤¤ë AudioMixerGroup ¤Î¿ô¤À¤± () Æâ¤Î¿ô»ú¤¬ÀßÄꤵ¤ì¤Þ¤¹¡£¤³¤Î¼ê½ç¤Ç¤¢¤ì¤Ð¡¢Exposed Parameters(1) ¤È¤Ê¤Ã¤Æ¤¤¤Þ¤¹¡£





¡¡Exposed Parameters(1) Éôʬ¤Ï¥×¥ë¥À¥¦¥ó¥á¥Ë¥å¡¼¤Ë¤Ê¤Ã¤Æ¤¤¤Þ¤¹¡£
¤³¤ÎÉôʬ¤ÏǤ°Õ¤Î̾¾Î¤òÀßÄê¤Ç¤­¤ë²Õ½ê¤Ç¤¢¤ê¡¢¤«¤Ä¡¢¥¹¥¯¥ê¥×¥È¤«¤é¤ÎÌ¿Îá¤ò¼õ¤±¤ëºÝ¤Î»ØÄêʸ»úÎó¤Ë¤â¤Ê¤ê¤Þ¤¹¡£
¤è¤Ã¤Æ¡¢¤ï¤«¤ê¤ä¤¹¤¤Ì¾¾Î¤Ë¤·¤Æ¤ª¤¯¤³¤È¤¬½ÅÍפǤ¹¡£

¡¡¤³¤Á¤é¤Î¥×¥ë¥À¥¦¥ó¥á¥Ë¥å¡¼¤ò¥¯¥ê¥Ã¥¯¤·¤Æ My Exposed Param Volume (of Master) ¤ÎÉôʬ¤ò¥À¥Ö¥ë¥¯¥ê¥Ã¥¯¤·¤Þ¤¹¡£

¡¡¤½¤¦¤¹¤ë¤È̾Á°¤òÊѹ¹¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¤Î¤Ç¡¢My Exposed Param Éôʬ¤ò¾Ã¤·¤Æ¡¢Âå¤ï¤ê¤Ë Master ¤ÈÆþÎϤ·¤Þ¤¹¡£
¤³¤Îʸ»úÎó¤ò»È¤¤¡¢¥¹¥¯¥ê¥×¥È¤«¤é¤Î AudioMaster ¤ØÌ¿Îá¤ò½Ð¤¹¤³¤È¤Ë¤Ê¤ê¤Þ¤¹¡£





¡¡É½¼¨¤¬ Master Volume (of Master) ¤ËÊѤï¤ê¤Þ¤¹¡£



¡¡
¡¡¤³¤ì¤ÇÀßÄ괰λ¤Ç¤¹¡£

¡¡¤³¤³¤Þ¤Ç¤ÎÀßÄê¤ò¹Ô¤ï¤º¤Ë¥¹¥¯¥ê¥×¥È¤Ë¤À¤±Ì¿Îá¤òÍÑ°Õ¤·¤¿¾ì¹ç¡¢ËÁƬ¤Î¤è¤¦¤Ê¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤¬É½¼¨¤µ¤ì¤ÆÀ©¸æ¤¬¼ºÇÔ¤·¤Þ¤¹¡£





£³¡¥¥µ¥ó¥×¥ë¥¹¥¯¥ê¥×¥È


¡¡¤³¤³¤Ç¤Ï£²¤Ä¤Î¥¹¥¯¥ê¥×¥È¤òÍÑ°Õ¤·¤Æ¤¤¤Þ¤¹¡£

¡¡£±¤Ä¤Ï ConstData ¥¹¥¯¥ê¥×¥È¤Ç¤¹¡£
¤³¤Î¥¹¥¯¥ê¥×¥È¤ÇÍÑ°Õ¤¹¤ë¥¯¥é¥¹¤ÏÄê¿ôÍѤΥ¯¥é¥¹¤Ë¤Ê¤ê¤Þ¤¹¡£
¤è¤Ã¤Æ¡¢¥¯¥é¥¹¼«ÂΤâ static ¤ÇÍÑ°Õ¤·¡¢¤¤¤º¤ì¤Î¥¯¥é¥¹¤«¤é¤Ç¤âÄê¿ô¤òÍøÍѤǤ­¤ë¾õÂ֤Ȥ·¤ÆºîÀ®¤·¤Æ¤ª¤­¤Þ¤¹¡£

¡¡¥¯¥é¥¹Æâ¤ËÄêµÁ¤¹¤ë¥á¥ó¥ÐÊÑ¿ô¤â const ¤È¤·¤ÆÀë¸À¤ò¹Ô¤¦¤¿¤á¡¢Äê¿ôÃͤȤ·¤Æǧ¼±¤µ¤ì¤ë¤è¤¦¤Ë¤·¤Þ¤¹¡£

£±¡¥ConstData ¥¯¥é¥¹



ConstData.cs

<= ¥¯¥ê¥Ã¥¯¤¹¤ë¤È³«¤­¤Þ¤¹




¡¡¾åµ­¤Î½èÍý¤Ë¤ª¤¤¤Æ

¡¡public const string MASTER_AUDIO_NAME = "Master";

¡¡¤³¤ÎÉôʬ¤Îʸ»úÎó¤ÎÃͤȤ·¤Æ¡Ú£²¡Û¤Ç AudioMixer ¥¦¥¤¥ó¥É¥¦¤ÇÀßÄꤷ¤¿Ê¸»úÎó¤òµ­½Ò¤·¤Æ¤ª¤­¤Þ¤¹¡£





¡¡AudioMixer ¦¤ËÌ¿Îá¤ò½Ð¤¹ºÝ¤Ë¤Ï¾ï¤ËƱ¤¸ÃͤòÍøÍѤ¹¤ë¤Î¤Ç¡¢¤½¤¦¤¤¤Ã¤¿¥±¡¼¥¹¤Î¾ì¹ç¤Ë¤Ï
¥¹¥¯¥ê¥×¥È¤´¤È¤ËÊÑ¿ô¤òÍÑ°Õ¤¹¤ë¤Î¤Ç¤Ï¤Ê¤¯¡¢Äê¿ôÃͤȤ·¤Æ ConstData ¤Î¤è¤¦¤ÊÄê¿ôÍѤΥ¯¥é¥¹¤òºîÀ®¤·¤ÆÍøÍѤ¹¤ë¤è¤¦¤Ë¤·¤Æ¤¯¤À¤µ¤¤¡£


£²¡¥SoundManager ¥¯¥é¥¹


¡¡Â³¤¤¤Æ¡¢BGM ¤ä SE ¤È¤¤¤Ã¤¿²»³ÚÍѤÎÀ©¸æÍѤΥ¯¥é¥¹¤Ç¤¢¤ë SoundManager ¤òºîÀ®¤·¤Þ¤¹¡£
¤³¤Á¤é¤Ç¤Ï²»³Ú¤ÎºÆÀ¸¡¦Ää»ß¤ò¹Ô¤¦¤È¤È¤â¤Ë¡¢AudioMixer ¤Ø¤Îɳ¤Å¤±¤âÍÑ°Õ¤·¤Æ¤ª¤¤¤Æ
ưŪ¤Ë¥Ü¥ê¥å¡¼¥à¤ÎÀ©¸æ¤ò¹Ô¤¦¤¿¤á¤Î¥á¥½¥Ã¥É¤òÍÑ°Õ¤·¤Æ¤ª¤­¤Þ¤¹¡£

¡¡²»³Ú¤ÎºÆÀ¸¡¢SE ¤ÎºÆÀ¸¤Ê¤É¤Ï¤¤¤º¤ì¤Î¥¯¥é¥¹¤«¤é¤Ç¤âÌ¿Îá¤ò¼Â¹Ô¤Ç¤­¤ë¤ÈÍøÊØÀ­¤¬¹â¤¯¤Ê¤ê¤Þ¤¹¤Î¤Ç¡¢
SoundManager ¥¯¥é¥¹¤Ï¥·¥ó¥°¥ë¥È¥ó¥¯¥é¥¹¤È¤·¤ÆÄêµÁ¤·¤Æ¤ª¤¯¤È¤è¤¤¤Ç¤·¤ç¤¦¡£
¤¢¤ë¤¤¤Ï DI ¥³¥ó¥Æ¥Ê¤òÍøÍѤ·¤Æ°Í¸À­ÃíÆþ¤ò¹Ô¤¦¤È¤è¤¤¤Ç¤¹¡£

¡¡¤Ê¤ªº£²ó¤Ï AudioMixer ¤Ë¤Ä¤¤¤Æ¤Î¼ÂÁõ¤Î¤¿¤á¡¢²»³Ú¤ÎºÆÀ¸¡¦Ää»ß¤Ê¤É¤Î½èÍý¤Ïµ­½Ò¤·¤Æ¤¤¤Þ¤»¤ó¡£
¤½¤Á¤é¤Ë¤Ä¤¤¤Æ¤Ï¡¢Ê̤ε­»ö¤ò»²¹Í¤Ë¤·¤Æ¼ÂÁõ¤ò¹Ô¤Ã¤Æ¤¯¤À¤µ¤¤¡£

¡¡¡¡¢ª¡¡SoundManager¤Ç¥²¡¼¥àÆâ¤Î²»¸»¤ò´ÉÍý¤¹¤ë


SoundManager.cs

<= ¥¯¥ê¥Ã¥¯¤¹¤ë¤È³«¤­¤Þ¤¹




¡¡²¼µ­¤Ï»²¹ÍÍѤΥ¤¥ó¥¹¥Ú¥¯¥¿¡¼²èÁü¤Ë¤Ê¤ê¤Þ¤¹¡£







»²¹Í¥µ¥¤¥È
Unity ¸ø¼°¥É¥­¥å¥á¥ó¥È
AudioMixer
https://docs.unity3d.com/ScriptReference/Audio.Aud...
Unity ¸ø¼°¥É¥­¥å¥á¥ó¥È
AudioMixer.SetFloat
https://docs.unity3d.com/ScriptReference/Audio.Aud...


£³¡¥¡ãÊä´Ö½èÍý¤ò»È¤¦¾ì¹ç¡ä


¡¡AudioMixer.SetFloat ¥á¥½¥Ã¥É¤Ï¡¢»ØÄꤷ¤¿ AudioGroup ¤Î¥Ü¥ê¥å¡¼¥à¤òÀßÄꤹ¤ë¤¿¤á¤Î¤â¤Î¤Ç¤¹¡£
Âè2°ú¿ô¤Ë»ØÄꤷ¤¿Ãͤ¬¡¢¤½¤Î¤Þ¤Þ¥Ü¥ê¥å¡¼¥àÃͤȤ·¤ÆÀßÄꤵ¤ì¤Þ¤¹¡£Êä´Ö½èÍý¤ÏŬÍѤµ¤ì¤Þ¤»¤ó¡£

audioMixerGroups[0].audioMixer.SetFloat(mixerGroupName, decibel);

¡¡Êä´Ö½èÍý¤ò¹Ô¤¤¤¿¤¤¾ì¹ç¤Ï¡¢DOTween ¤Ê¤É¤Î¥é¥¤¥Ö¥é¥ê¤ò»ÈÍѤ¹¤ë¤³¤È¤Ç¼Â¸½¤Ç¤­¤Þ¤¹¡£

¡¡°Ê²¼¤Ï¡¢DOTween ¤ò»ÈÍѤ·¤¿¥µ¥ó¥×¥ë¥³¡¼¥É¤Ç¤¹¡£
¡¡
using DG.Tweening;
using UnityEngine;
using UnityEngine.Audio;

public class AudioMixerController : MonoBehaviour
{
    [SerializeField] private AudioMixer audioMixer;
    [SerializeField] private string mixerGroupName;
    [SerializeField] private float duration;

    public void SetLinearVolumeToMixerGroup(string mixerGroupName, float linerVolume) {
        float decibel = 20.0f * Mathf.Log10(linerVolume);

        if (float.IsNegativeInfinity(decibel)) {
            decibel = -96f;  // ̵²»¤Ï -80f ¤Ç¤Ï¤Ê¤¯¤Æ -96f ¤Ë¤¹¤ë
        }

¡¡¡¡¡¡¡¡// DOTween ¤òÍøÍѤ·¤ÆÊä´Ö½èÍý¤ò¹Ô¤¦
        audioMixerGroups[0].DOSetFloat(mixerGroupName, decibel, duration);
    }
}


»²¹Í¥µ¥¤¥È
Github ¥Ï¥È¥Í¥³¥¨ ÍÍ
¥ª¡¼¥Ç¥£¥ª¤Î¥Õ¥§¡¼¥É¥¤¥ó¡¦¥Õ¥§¡¼¥É¥¢¥¦¥È¡§DOTween »ÈÍÑ¡Ê¥Ö¥í¥°¸ø³«ÍÑ¡Ë
https://gist.github.com/nekonenene/3643fe8e958fc8b...



£´¡¥Slider ¤È¤ÎÏ¢·È


¡¡¥²¡¼¥à¤Ç¤Ï¤è¤¯¡¢¥¹¥é¥¤¥À¡¼Éôʬ¤òÊѹ¹¤¹¤ë¤³¤È¤Ç¥Ü¥ê¥å¡¼¥àÀ©¸æ¤Èɳ¤Å¤±¤ë¥Ñ¥¿¡¼¥ó¤¬Â¿¤¤¤Ç¤¹¡£
¤½¤Á¤é¤Ë¤Ä¤¤¤Æ¤Ï¤Û¤«¤Ë¤â¾ÜºÙ¤ËÀâÌÀ¤·¤Æ¤¤¤ëµ­»ö¤¬¤¢¤ê¤Þ¤¹¤Î¤Ç¡¢»²¹Í¤Ë¤·¤Æ¤¯¤À¤µ¤¤¡£

¡¡¤³¤³¤Ç¤Ï¡¢UIManager ¥¯¥é¥¹¤òºîÀ®¤·¤Æ¡¢É½¼¨¤ÈÀ©¸æ¤ò°ì½ï¤Ë¹Ô¤¦Îã¤òÄ󼨤·¤Æ¤ª¤­¤Þ¤¹¡£
¤¢¤¯¤Þ¤Ç¤â¼ÂÁõÎã¤Ç¤¹¤Î¤Ç£±¤Ä¤Î¥¯¥é¥¹¤Ë¤Þ¤È¤á¤Æ¤¤¤Þ¤¹¤¬¡¢º£¸å¤Î³Ø½¬¤Î¤¿¤á¡¢
¤³¤Á¤é¤ò¸µ¤Ë MV(R)P ¥Ñ¥¿¡¼¥ó¤Ç½ñ¤­Ä¾¤¹¤³¤È¤Ë¥Á¥ã¥ì¥ó¥¸¤·¤Æ¤ß¤Þ¤·¤ç¤¦¡£


UIManager

<= ¥¯¥ê¥Ã¥¯¤¹¤ë¤È³«¤­¤Þ¤¹¡£


¡¡AudioMixer ¤È¥¹¥é¥¤¥À¡¼¤È¤ÎÏ¢·È¤ò¹Ô¤¦¤³¤È¤Ç
¤½¤ì¤¾¤ì¤Î²èÌ̤ò°ì½ï¤Ë¸«¤ë¤³¤È¤Ç¡¢AudioMixer ¤È¥¹¥é¥¤¥À¡¼¤¬Æ±´ü¤·¤Æ¤¤¤ë¤³¤È¤ò³Îǧ¤Ç¤­¤Þ¤¹¡£


¼ÂÁõÆ°²è



¡¡Æ°ºî¸¡¾Ú¤Ï¤ï¤«¤ê¤ä¤¹¤¤·Á¤Ç¹Ô¤Ã¤Æ¤¤¤¯¤³¤È¤ò¿´³Ý¤±¤Æ¤¯¤À¤µ¤¤¡£
¡¡
¡¡°Ê¾å¤Ç´°À®¤Ç¤¹¡£
¤ªÈè¤ìÍͤǤ·¤¿¡ª


£µ¡¥¤½¤Î¤Û¤«

£±¡¥Ê£¿ô¤Î¥¹¥é¥¤¥À¡¼


¡¡º£²ó¤Î¼ÂÁõ¤Ç¤Ï¡¢Master ¤Ë¹ç¤ï¤»¤Æ¤¹¤Ù¤Æ¤Î¥Ü¥ê¥å¡¼¥à¤òÀ©¸æ¤¹¤ëÊýË¡¤Ç¼ÂÁõ¤·¤Æ¤¤¤Þ¤¹¤¬¡¢
¾¤Ë¤â BGM ÍѤΥ¹¥é¥¤¥À¡¼¤òÍÑ°Õ¤·¤Æ¡¢BGM ¤Î¥Ü¥ê¥å¡¼¥à¤Î¤ß¤òÀ©¸æ¤¹¤ëÊýË¡¤â²Äǽ¤Ç¤¹¡£





¡¡º£²ó³Ø½¬¤·¤¿ÆâÍƤò±þÍѤ¹¤ë¤³¤È¤Ç¼ÂÁõ²Äǽ¤Ç¤¹¤Î¤Ç¥Á¥ã¥ì¥ó¥¸¤·¤Æ¤ß¤Æ¤¯¤À¤µ¤¤¡£


£²¡¥Ê£¿ô¤Î¥À¥Ã¥­¥ó¥°ÀßÄê


¡¡SE ¤ÈƱ»þ¤Ë¥Ü¥¤¥¹¤òºÆÀ¸¤¹¤ë¾ì¹ç¡¢¥Ü¥¤¥¹¤òÍ¥À褷¤ÆÌĤ餷¤¿¤¤¥±¡¼¥¹¤¬Â¿¤¤¤È»×¤¤¤Þ¤¹¡£
¤½¤Î¾ì¹ç¤Ë¤Ï¡¢BGM ¤Î AudioMixerGroup ¤ËÀßÄꤷ¤¿¥À¥Ã¥­¥ó¥°¤Î¾ðÊó¤ò SE ¤Ë¤âÀßÄꤹ¤ë¤³¤È¤Ç¼Â¸½¤Ç¤­¤Þ¤¹¡£

¡¡ÁÛÄꤵ¤ì¤ëµóÆ°¤Ï¼¡¤Î¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¡£
³Æ AudioMixerGroup ¤Ø¤Î¥À¥Ã¥­¥ó¥°ÀßÄê¤È¥¹¥ì¥Ã¥·¥ç¥ë¥É¤ÎÀßÄê¤ò¹Ô¤¦¤³¤È¤¬½ÅÍפǤ¹¡£

¡¦SE ¤¬ÌĤäƤ¤¤ë´Ö¡¢BGM ¤Î¥Ü¥ê¥å¡¼¥à¤ò¼«Æ°Åª¤Ë²¼¤²¤ë
¡¡¡¡¡¡¢ª¡¡­¡BGM ¤Ë Duck Volume ¤òÀßÄꤹ¤ë¡£Threshold ¤ÎÀßÄêÃͤò -20 ¡Á -25 °Ì¤ËÀßÄꤹ¤ë
¡¡¡¡¡¡¡¡¡¡­¢SE ¤Ë Send ¤òÀßÄꤹ¤ë¡£Send Àè¤ò BGM ¤ËÀßÄꤹ¤ë







¡¡SE ¤«¤é²»¸»¤¬Î®¤ì¤Æ¤­¤¿¤È¤­¡¢Æ±»þ¤Ë BGM ¤¬Î®¤ì¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢¥¹¥ì¥Ã¥·¥ç¥ë¥É¤ÎÃͤ˼ý¤Þ¤ë¤è¤¦¤Ë BGM ¤Î¥Ü¥ê¥å¡¼¥à¤òÍÞ¤¨¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£




¡¦¥Ü¥¤¥¹¤¬ÌĤäƤ¤¤ë´Ö¡¢BGM ¤È SE ¤Î¥Ü¥ê¥å¡¼¥à¤ò¼«Æ°Åª¤Ë²¼¤²¤ë
¡¡¡¡¡¡¢ª¡¡­¡SE ¤Ë Duck Volume ¤òÀßÄꤹ¤ë¡£Threshold ¤ÎÀßÄêÃͤò -20 ¡Á -25 °Ì¤ËÀßÄꤹ¤ë
¡¡¡¡¡¡¡¡¡¡­¢¥Ü¥¤¥¹ ¤Ë Send ¤ò£²¤ÄÀßÄꤹ¤ë¡£Send Àè¤ò BGM ¤È SE ¤Ë¤½¤ì¤¾¤ìÀßÄꤹ¤ë















¡¡¤³¤Î¤è¤¦¤ËÀßÄꤷ¤Æ¤ª¤¯¤³¤È¤Ç¡¢¥Ü¥¤¥¹¤¬Î®¤ì¤¿¤È¤­¡¢SE ¤È BGM ¤Ë¾ðÊó¤¬ÅÁ㤵¤ì¡¢
³Æ AudioMixerGroup ¤Ï¤½¤ì¤¾¤ì¤Î¥¹¥ì¥Ã¥·¥ç¥ë¥É¤ÎÈÏ°ÏÆâ¤Ë¼ý¤Þ¤ë¤è¤¦¤Ë¥Ü¥ê¥å¡¼¥à¤ÎÀ©¸Â¤ò¤·¤Æ¤¯¤ì¤Þ¤¹¡£


£³¡¥»²¹Í¥µ¥¤¥È


LIGHT11 ÍÍ
¡ÚUnity¡ÛAudio Mixer¤Ç¿§¡¹¤Ê¥Ñ¥é¥á¡¼¥¿¤ò¥¹¥¯¥ê¥×¥È¤«¤éÀ©¸æ¤Ç¤­¤ëExposed Parameter¤Î»È¤¤Êý
https://light11.hatenadiary.com/entry/2022/06/28/1...
Qiita @matsumotokaka11(RYUSUKE MATSUMOTO) ÍÍ
Unity AudioMixer¤Ç²»ÎÌÅù¤Î¥Ñ¥é¥á¡¼¥¿¤ò¥¹¥¯¥ê¥×¥È¤«¤éÁàºî¤¹¤ëºÝ¤Î¤Ä¤Þ¤ê¥Ý¥¤¥ó¥È¥á¥â
https://qiita.com/matsumotokaka11/items/2eb0e7ac34...

¥³¥á¥ó¥È¤ò¤«¤¯


¡Öhttp://¡×¤ò´Þ¤àÅê¹Æ¤Ï¶Ø»ß¤µ¤ì¤Æ¤¤¤Þ¤¹¡£

ÍøÍѵ¬Ìó¤ò¤´³Îǧ¤Î¤¦¤¨¤´µ­Æþ²¼¤µ¤¤

Menu


´ðÁÃ

µ»½Ñ/Ãμ±(¼ÂÁõÎã)

3D¥¢¥¯¥·¥ç¥ó¥²¡¼¥à

2D¤ª¤Ï¤¸¤­¥²¡¼¥à(ȯŸÊÔ)

2D¶¯À©²£¥¹¥¯¥í¡¼¥ë¥¢¥¯¥·¥ç¥ó(ȯŸÊÔ)

2D¥¿¥Ã¥×¥·¥å¡¼¥Æ¥£¥ó¥°(³ÈÄ¥ÊÔ)

¥ì¡¼¥¹¥²¡¼¥à(È´¿è)

2DÊüÃÖ¥²¡¼¥à(ȯŸÊÔ)

3D¥ì¡¼¥ë¥¬¥ó¥·¥å¡¼¥Æ¥£¥ó¥°(±þÍÑÊÔ)

3Dæ½Ð¥²¡¼¥à(È´¿è)

2D¥ê¥¢¥ë¥¿¥¤¥à¥¹¥È¥é¥Æ¥¸¡¼

3D¥¿¥Ã¥×¥¢¥¯¥·¥ç¥ó(NavMeshAgent »ÈÍÑ)

2D¥È¥Ã¥×¥Ó¥å¡¼¥¢¥¯¥·¥ç¥ó(¥«¥¨¥ë¤Î°Ù¤Ë¡Á¡¢¥Ü¥³¥¹¥«¥¦¥©¡¼¥ºÉ÷)

VideoPlayer ¥¤¥Ù¥ó¥ÈϢư¤Î¼ÂÁõÎã

VideoPlayer ¥ê¥¹¥ÈÆ⤫¤é¥à¡¼¥Ó¡¼ºÆÀ¸¤Î¼ÂÁõÎã(ȯŸ)

AR ²èÁüÉÕ¤­¥ª¥Ö¥¸¥§¥¯¥ÈÀ¸À®¤Î¼ÂÁõÎã

AR ¥ê¥¹¥ÈÆ⤫¤éÀ¸À®¤Î¼ÂÁõÎã(ȯŸ)

2D¥È¥Ã¥×¥Ó¥å¡¼¥¢¥¯¥·¥ç¥ó(¥µ¥Ð¥¤¥Ð¡¼É÷)

private



¤³¤Î¥µ¥¤¥ÈÆâ¤ÎºîÉʤϥæ¥Ë¥Æ¥£¤Á¤ã¤ó¥é¥¤¥»¥ó¥¹¾ò¹à¤Î¸µ¤ËÄ󶡤µ¤ì¤Æ¤¤¤Þ¤¹¡£

´ÉÍý¿Í/Éû´ÉÍý¿Í¤Î¤ßÊÔ½¸¤Ç¤­¤Þ¤¹