Mercurial > mplayer.hg
comparison loader/dmo/DMO_AudioDecoder.c @ 9967:b0d1b415320c
cygwin support patch by Sascha Sommer and some fixes by me
author | alex |
---|---|
date | Mon, 21 Apr 2003 21:06:08 +0000 |
parents | fb88ccbc5ccc |
children | f70772d02eaa |
comparison
equal
deleted
inserted
replaced
9966:9aeb20839969 | 9967:b0d1b415320c |
---|---|
2 | 2 |
3 DirectShow audio decoder | 3 DirectShow audio decoder |
4 Copyright 2001 Eugene Kuznetsov (divx@euro.ru) | 4 Copyright 2001 Eugene Kuznetsov (divx@euro.ru) |
5 | 5 |
6 *********************************************************/ | 6 *********************************************************/ |
7 | 7 #include "config.h" |
8 #ifndef NOAVIFILE_HEADERS | 8 #ifndef NOAVIFILE_HEADERS |
9 #include "audiodecoder.h" | 9 #include "audiodecoder.h" |
10 #include "except.h" | 10 #include "except.h" |
11 #else | 11 #else |
12 #include "libwin32.h" | 12 #include "libwin32.h" |
13 #ifdef WIN32_LOADER | |
13 #include "ldt_keeper.h" | 14 #include "ldt_keeper.h" |
15 #endif | |
14 #endif | 16 #endif |
15 | 17 |
16 #include "DMO_Filter.h" | 18 #include "DMO_Filter.h" |
17 #include "DMO_AudioDecoder.h" | 19 #include "DMO_AudioDecoder.h" |
18 | 20 |
41 { | 43 { |
42 DMO_AudioDecoder *this; | 44 DMO_AudioDecoder *this; |
43 int sz; | 45 int sz; |
44 WAVEFORMATEX* pWF; | 46 WAVEFORMATEX* pWF; |
45 | 47 |
48 #ifdef WIN32_LOADER | |
46 Setup_LDT_Keeper(); | 49 Setup_LDT_Keeper(); |
47 Setup_FS_Segment(); | 50 Setup_FS_Segment(); |
51 #endif | |
48 | 52 |
49 this = malloc(sizeof(DMO_AudioDecoder)); | 53 this = malloc(sizeof(DMO_AudioDecoder)); |
50 | 54 |
51 this->m_iFlushed=1; | 55 this->m_iFlushed=1; |
52 | 56 |
116 int r = 0; | 120 int r = 0; |
117 | 121 |
118 if (!in_data || !out_data) | 122 if (!in_data || !out_data) |
119 return -1; | 123 return -1; |
120 | 124 |
125 #ifdef WIN32_LOADER | |
121 Setup_FS_Segment(); | 126 Setup_FS_Segment(); |
127 #endif | |
122 | 128 |
123 //m_pDMO_Filter->m_pMedia->vt->Lock(m_pDMO_Filter->m_pMedia, 1); | 129 //m_pDMO_Filter->m_pMedia->vt->Lock(m_pDMO_Filter->m_pMedia, 1); |
124 bufferin = CMediaBufferCreate(in_size, (void*)in_data, in_size, 1); | 130 bufferin = CMediaBufferCreate(in_size, (void*)in_data, in_size, 1); |
125 r = this->m_pDMO_Filter->m_pMedia->vt->ProcessInput(this->m_pDMO_Filter->m_pMedia, 0, | 131 r = this->m_pDMO_Filter->m_pMedia->vt->ProcessInput(this->m_pDMO_Filter->m_pMedia, 0, |
126 (IMediaBuffer*)bufferin, | 132 (IMediaBuffer*)bufferin, |