示例#1
0
    // Use this for initialization
    void Start()
    {
        var criAtom = new GameObject("CRIAtom");

        criAtom.AddComponent <CriAtom>();

        CriAtom.AddCueSheet("CueSheet_0", "CueSheet_0.acb", "");

        seAtomSource  = gameObject.AddComponent <CriAtomSource> ();
        bgmAtomSource = gameObject.AddComponent <CriAtomSource> ();

        // 種別にSpectrumAnalyzerを指定
        CriAtomExPlayerOutputAnalyzer.Type[] type = new CriAtomExPlayerOutputAnalyzer.Type[1];
        //type[0] = CriAtomExPlayerOutputAnalyzer.Type.SpectrumAnalyzer;
        type[0] = CriAtomExPlayerOutputAnalyzer.Type.LevelMeter;

        // コンフィグでバンド数を指定
        //CriAtomExPlayerOutputAnalyzer.Config[] config = new CriAtomExPlayerOutputAnalyzer.Config[1];
        //config[0] = new CriAtomExPlayerOutputAnalyzer.Config(8);

        analyzer = new CriAtomExPlayerOutputAnalyzer(type, null);         //config);

        bgmAtomSource.AttachToAnalyzer(analyzer);
    }