Reputation: 11
I am trying to create a program in JythonMusic, that changes the pitch from one wav-file into the pitch from another wav-file.
The idea I have is:
->Open wav-file that sets the pitch and length (framerate)
->While wav-file.length not empty:
Save wav.frame.pitch & wav.frame somewhere
->Open second wav-file whose pitch and length have to get modified to fit wav1
->While wav.frame not empty:
Apply wav.frame.pitch to second-wav.frame
...
Anyways that's the basic idea, now I don't seem to find any way to set the framerate or apply the pitch to a single frame on a wav-file.
I can however change the pitch for the entire wav-file... but that's not really what I want.
(Just to clarify this, but this is a JythonMusic-question. Not a Jython-question...)
Upvotes: 1
Views: 113
Reputation: 81
JythonMusic allows getting and setting the pitch (or frequency) of entire wav files - see AudioSample getPitch() and setPitch() functions.
This is probably what you want.
A wav frame is too low of a level to think about pitch or frequency, as it just stores a number, the amplitude (or loudness) of sound at this particular instance in time.
Upvotes: 0