-
Notifications
You must be signed in to change notification settings - Fork 981
Closed
Description
Hi Scott,
I've got a bit of a curly question.
I was wondering if there is a way to reformat the data on the X Axis?
I'm able to open audio files and display their waveforms, however I'd like to be able to show the X Axis in a time code, instead of samples.
I've looked at the format-strings for plt.Ticks(numericFormatStringX: "t"), however it's just reformatting values in the millions and trying to get a time, which isn't working.
With 44100 samples a second, you can imagine the numbers don't work well at all...
Something like this maybe, I don't know...
x value = formatstring( x value / samplerate, "d:hh:mm:ss:mmm")
Is there a way to convert these values to time properly? Or can you point me in the right direction?
I'm at this so far:
formsPlot1.Configure(lockVerticalAxis: true);
formsPlot1.plt.PlotSignal(dataX1);
formsPlot1.plt.AxisAuto();
formsPlot1.plt.AxisBounds(0, samples, -1, 1);
formsPlot1.plt.Ticks(numericFormatStringX: "c"); // Obviously wrong
formsPlot1.Render();
Cheers,
Steve
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels