Link to home
Start Free TrialLog in
Avatar of RLM
RLM

asked on

Clipboard formats CF_WAVE & CF_RIFF

What is the exact format of the data to be retrieved/stored in clipboard for either CF_WAVE and CF_RIFF?
Avatar of chensu
chensu
Flag of Canada image

Their formats should be exactly the same as the formats of WAV files and RIFF files. You can get the format information at http://www.wotsit.demon.co.uk.
Avatar of RLM
RLM

ASKER

I don't think there is such a thing as a RIFF file. RIFF is chunk type found inside a .wav file. (There's also a 'data' chunk as well.) And I already know the format of a WAV file but my docs on clipboard formats don't indicate that the entire wave file is placed on clipboard. In fact they don't indicate much of anything other than the fact that I can use either CB_WAVE or CB_RIFF.
A WAV file is a kind of RIFF files. The other examples of RIFF files are AVI files and RMI files (a kind of MIDI files). As far as I understand, CF_WAVE can be standard PCM format, CF_RIFF can be other formats (such as ADPCM, or even AVI) as long as it conforms to RIFF standard.

You can try this.

Call AVIPutFileOnClipboard() to copy an AVI file (or a wave file since AVIFile functions work on RIFF files) to the clipboard. Now the clipboard contains the CF_WAVE data. Then retrieve the data and view it.
I think CF_WAVE contains RIFF WAVE followed by fmt chunk and data chunk while CF_RIFF can contain other chunks.
Avatar of RLM

ASKER

Thanks chensu, please answer w/anything and I'll grade.
ASKER CERTIFIED SOLUTION
Avatar of chensu
chensu
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial