Example #1
0
        private void StartPlay(string transition, double duration, double tuning)
        {
            m_PlayRequested = true;

            PrepareResources();

            if (m_Prepared)
            {
                if (!string.IsNullOrEmpty(transition))
                {
                    if (transition.Equals("Fade", StringComparison.OrdinalIgnoreCase))
                    {
                        //TODO fade in for <duration> seconds
                    }
                }

                Console.WriteLine("Play");

                //Explicitly report to playlog with reason
                m_PlaybackTicket = m_Template.BeginFilePlayback(m_TemplateFile, "Play");

                m_Template.SetState(API.State.OK, "Playing");

                m_Template.Debug(API.DebugLevel.High, API.DebugCategory.Information, "Playing file " + m_TemplateFile.Name);
            }
            else
            {
                m_Template.SetState(API.State.Initializing, "Not ready to play");
            }
        }