]>
git.saurik.com Git - wxWidgets.git/blob - utils/wxMMedia2/sample/test_med2.cpp
26b7dfaaf235c703a220ecd3657c0e6372c44ae5
1 // --------------------------------------------------------------------------
5 // Author: Guilhem Lavaux <lavaux@easynet.fr> (C) 1999
7 // --------------------------------------------------------------------------
9 #include <wx/wfstream.h>
11 #include "../lib/sndoss.h"
12 #include "../lib/sndesd.h"
13 #include "../lib/sndwav.h"
14 #include "../lib/sndaiff.h"
16 class MyApp
: public wxApp
{
18 // wxSoundStreamOSS *oss_dev = new wxSoundStreamOSS();
19 wxSoundStreamESD
*oss_dev
= new wxSoundStreamESD();
20 wxFileInputStream
*f_input
= new wxFileInputStream(argv
[1]);
21 wxSoundFileStream
*wav_file
;
22 wxFrame
*frame
= new wxFrame(NULL
, -1, "My Frame");
25 if (oss_dev
->GetError() != wxSOUND_NOERR
) {
26 wxPrintf("No device\n");
30 wav_file
= new wxSoundWave(*f_input
, *oss_dev
);
31 if (!wav_file
->CanRead()) {
32 wav_file
= new wxSoundAiff(*f_input
, *oss_dev
);
33 if (!wav_file
->CanRead())