tjscience / audion.cscore

An audio visualization and processing framework for WPF
MIT License
33 stars 7 forks source link

Add DynamicWaveform control #3

Closed tjscience closed 7 years ago

tjscience commented 7 years ago

Add a DynamicWaveform control that displays the waveform of the media progressively as it is played.

Custom Properties:

Source - The Audion.Source attached to the instance Resolution - How many points to show in the waveform (The higher the resolution, the more resources it takes to display) WaveformLength - The number of seconds (double) to be displayed for the waveform LeftBrush - The brush color for the left side of the waveform RightBrush - The brush color for the right side of the waveform LeftStroke - The brush color of the left side's border of the waveform RightStroke - The brush color of the right side's border of the waveform LeftStrokeThickness - The thickness of the left side's border of the waveform RightStrokeThickness - The thickness of the right side's border of the waveform CenterLineBrush - The brush color of the center line for the waveform

The way this control will work is as follows:

  1. Attach a source to the control.
  2. The first (x) seconds are displayed in the waveform (x = WaveformLength)
  3. When the media is played, the waveform will be progressively drawn, with the current sound synced to the left side of the control.