Пример #1
0
 // Token: 0x06003237 RID: 12855 RVA: 0x0014734C File Offset: 0x0014554C
 private static bool TrySkipDefaultTimeSignature(MidiEvent midiEvent, ref bool skip)
 {
     if (skip)
     {
         TimeSignatureEvent timeSignatureEvent = midiEvent as TimeSignatureEvent;
         if (timeSignatureEvent != null)
         {
             if (timeSignatureEvent.Numerator == 4 && timeSignatureEvent.Denominator == 4 && timeSignatureEvent.ClocksPerClick == 24 && timeSignatureEvent.NumberOf32ndNotesPerBeat == 8)
             {
                 return(true);
             }
             skip = false;
         }
     }
     return(false);
 }
Пример #2
0
        /// <summary>
        /// Determines whether the specified event is equal to the current one.
        /// </summary>
        /// <param name="timeSignatureEvent">The event to compare with the current one.</param>
        /// <param name="respectDeltaTime">If true the <see cref="MidiEvent.DeltaTime"/> will be taken into an account
        /// while comparing events; if false - delta-times will be ignored.</param>
        /// <returns>true if the specified event is equal to the current one; otherwise, false.</returns>
        public bool Equals(TimeSignatureEvent timeSignatureEvent, bool respectDeltaTime)
        {
            if (ReferenceEquals(null, timeSignatureEvent))
            {
                return(false);
            }

            if (ReferenceEquals(this, timeSignatureEvent))
            {
                return(true);
            }

            return(base.Equals(timeSignatureEvent, respectDeltaTime) &&
                   Numerator == timeSignatureEvent.Numerator &&
                   Denominator == timeSignatureEvent.Denominator &&
                   ClocksPerClick == timeSignatureEvent.ClocksPerClick &&
                   NumberOf32ndNotesPerBeat == timeSignatureEvent.NumberOf32ndNotesPerBeat);
        }
Пример #3
0
 /// <summary>
 /// Determines whether the specified event is equal to the current one.
 /// </summary>
 /// <param name="timeSignatureEvent">The event to compare with the current one.</param>
 /// <returns>true if the specified event is equal to the current one; otherwise, false.</returns>
 public bool Equals(TimeSignatureEvent timeSignatureEvent)
 {
     return(Equals(timeSignatureEvent, true));
 }