We've got waveforms on display! heh!


#1

new class: WaveFormWindow

the waveform display is working… currently it’s only doing mono because I wasn’t sure if ya’ll wanted two waveforms for stereo or mearly left/right or both… or… or… uhhh… heh :roll: :shock: :smiley:

It resizes and all that good stuff too… there is a bug with the transparencies. For whatever reason, it goes very light if I try to keep the transparency on (I happen to like the solid color better tho… my laptop cpu like it much better too). Probably some secret niggles in there, or someone will jump in and rant that my code sucks… heheheh.

BTW, I abandoned the wavereader class idea… because it really doesn’t take that many steps to implement loading a buffer and that what not… or getting the sample values from the buffer, etc. Maybe I’m missing the point (then again it’s hella late… I mean early, and I need sleeeeep).

I attached bithead’s waveplayer class on here too… it’s commented out because Robert has it read a wav too… so I dunno which one is going to end up being the primary one… so they are both in there…

anyway, sun is rising and I need sleep… l8z…

it’s in the usual location -> http://subminimal.org/juce


#2

great mod!

We really do need to make 2 seperate classes for this though…

whenever you get on aim today we can chat 'bout it…

neat tho.


#3

I know this is already known, but it doesn’t restore correctly.


#4

cool!!


#5

hi!

is the code available somewhere ? I checked the URL but it’s not there.

Many thanks in advance

geoffroy


#6

OK here’s my attempt at waveform display and editor classes for audio files (rather than audio buffers at the moment). Still rough but a basic infrastructure is in place.

http://code.google.com/p/audioeddie/

It’s based on the Juce audio demo.

Currently reads and displays mono or multichannel files, has a selection and mechanisms for adding other markers.


#7

Hi Martinrobinson,
i would love to give your component a try but there seems to be nothing to download at the url you given us.

Cheers
Edwin


#8

Hello,

It’s a Google code project so go to:

http://code.google.com/p/audioeddie/source/browse

browse the source, look in the trunk directory

Martin


#9

Thanx,
i did look but not good enough

Edwin


#10

You didn’t look well enough or the waveform isn’t good enough? :?


#11

You don’t seem to be using the AudioThumbnail class - is there something you’re trying to do that it doesn’t handle…?


#12

Well yes and no. I hadn’t found the AudioThumbnail class although having found the thread on the forum I now remember seeing it. I’ll look at refactoring using the class. But I do want to customise the drawing in the future but I guess I could just subclass it and override the paint() method.


#13

I didn’t look well enough but your waveform surely looks sharp :wink:
Although we had some crashes, which at the moment i can’t recall when those happened. We are using the AudioThumbnail together with the ThumbnailCache class from Juce but it’s quite buggy in our app at the moment. So this looks like a nice alternative.

Cheers
Edwin


#14

for some reason (not having looked at the classes) i assumed that ‘AudioThumbnail’ was like some custom-length preview of an audio file with fade-in/out applied (and so didn’t bother investigating). It literally never occurred to me that it generated a waveform!


#15

…and I was hoping my method would allow channels > 2 but I notice that AiffAudioFormatReader and WavAudioFormatReader only do mono/stereo so that doesn’t work anyway!

Ultimately I want to be able to read/write markers and loop points from/to an AIFF/WAVE file from my waveform editor class. I’ve hacked away at my copy of juce_AiffAudioFormat.cpp to get at INST and MARK chunks but only as far as posting them in the console. I remember something about this in another thread. Jules, have you plan to deal with these chunks? I remember you were concerned they may contain large amounts of data and were reluctant to load them all into memory.


#16

[quote=“gekkie100”]
Although we had some crashes, which at the moment i can’t recall when those happened.[/quote]

It needs checking for threadsafeness but it was crashing occasionally in the MyWaveformMultiDisplay::fillBuffers() method when changing the horizontal zoom. That should be fixed now.


#17

…added new rendering methods and some x/y rulers (the image in the post above has been updated as it’s hosted on my site).


#18