diff options
author | XhmikosR <xhmikosr@users.sourceforge.net> | 2010-12-17 19:42:55 +0300 |
---|---|---|
committer | XhmikosR <xhmikosr@users.sourceforge.net> | 2010-12-17 19:42:55 +0300 |
commit | 7359bd509afa235acc2ac2f7f95fc9cb5cafd1a4 (patch) | |
tree | b5bb90eeca58fdeb9fde6825f21a25a319823cb4 /src/filters/source/ShoutcastSource/ShoutcastSource.h | |
parent | d30b15ed4b98c28951d6d45b8928f4c2b6a11129 (diff) |
apply astyle formatting
git-svn-id: https://mpc-hc.svn.sourceforge.net/svnroot/mpc-hc/trunk@2786 10f7b99b-c216-0410-bff0-8a66a9350fd8
Diffstat (limited to 'src/filters/source/ShoutcastSource/ShoutcastSource.h')
-rw-r--r-- | src/filters/source/ShoutcastSource/ShoutcastSource.h | 122 |
1 files changed, 82 insertions, 40 deletions
diff --git a/src/filters/source/ShoutcastSource/ShoutcastSource.h b/src/filters/source/ShoutcastSource/ShoutcastSource.h index 2c6a9e752..3e873955c 100644 --- a/src/filters/source/ShoutcastSource/ShoutcastSource.h +++ b/src/filters/source/ShoutcastSource/ShoutcastSource.h @@ -1,4 +1,4 @@ -/*
+/*
* Copyright (C) 2003-2006 Gabest
* http://www.gabest.org
*
@@ -6,12 +6,12 @@ * it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
- *
+ *
* This Program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with GNU Make; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
@@ -28,7 +28,7 @@ #include <qnetwork.h>
class __declspec(uuid("68F540E9-766F-44d2-AB07-E26CC6D27A79"))
-CShoutcastSource
+ CShoutcastSource
: public CSource
, public IFileSourceFilter
, public IAMFilterMiscFlags
@@ -42,7 +42,7 @@ public: virtual ~CShoutcastSource();
DECLARE_IUNKNOWN;
- STDMETHODIMP NonDelegatingQueryInterface(REFIID riid, void** ppv);
+ STDMETHODIMP NonDelegatingQueryInterface(REFIID riid, void** ppv);
// IFileSourceFilter
STDMETHODIMP Load(LPCOLESTR pszFileName, const AM_MEDIA_TYPE* pmt);
@@ -52,27 +52,59 @@ public: STDMETHODIMP_(ULONG) GetMiscFlags();
// IAMOpenProgress
- STDMETHODIMP QueryProgress(LONGLONG* pllTotal, LONGLONG* pllCurrent);
- STDMETHODIMP AbortOperation();
+ STDMETHODIMP QueryProgress(LONGLONG* pllTotal, LONGLONG* pllCurrent);
+ STDMETHODIMP AbortOperation();
// IAMMediaContent
- STDMETHODIMP GetTypeInfoCount(UINT* pctinfo) {return E_NOTIMPL;}
- STDMETHODIMP GetTypeInfo(UINT itinfo, LCID lcid, ITypeInfo** pptinfo) {return E_NOTIMPL;}
- STDMETHODIMP GetIDsOfNames(REFIID riid, OLECHAR** rgszNames, UINT cNames, LCID lcid, DISPID* rgdispid) {return E_NOTIMPL;}
- STDMETHODIMP Invoke(DISPID dispidMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS* pdispparams, VARIANT* pvarResult, EXCEPINFO* pexcepinfo, UINT* puArgErr) {return E_NOTIMPL;}
- STDMETHODIMP get_AuthorName(BSTR* pbstrAuthorName) {return E_NOTIMPL;}
+ STDMETHODIMP GetTypeInfoCount(UINT* pctinfo) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP GetTypeInfo(UINT itinfo, LCID lcid, ITypeInfo** pptinfo) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP GetIDsOfNames(REFIID riid, OLECHAR** rgszNames, UINT cNames, LCID lcid, DISPID* rgdispid) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP Invoke(DISPID dispidMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS* pdispparams, VARIANT* pvarResult, EXCEPINFO* pexcepinfo, UINT* puArgErr) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_AuthorName(BSTR* pbstrAuthorName) {
+ return E_NOTIMPL;
+ }
STDMETHODIMP get_Title(BSTR* pbstrTitle);
- STDMETHODIMP get_Rating(BSTR* pbstrRating) {return E_NOTIMPL;}
- STDMETHODIMP get_Description(BSTR* pbstrDescription) {return E_NOTIMPL;}
- STDMETHODIMP get_Copyright(BSTR* pbstrCopyright) {return E_NOTIMPL;}
- STDMETHODIMP get_BaseURL(BSTR* pbstrBaseURL) {return E_NOTIMPL;}
- STDMETHODIMP get_LogoURL(BSTR* pbstrLogoURL) {return E_NOTIMPL;}
- STDMETHODIMP get_LogoIconURL(BSTR* pbstrLogoURL) {return E_NOTIMPL;}
- STDMETHODIMP get_WatermarkURL(BSTR* pbstrWatermarkURL) {return E_NOTIMPL;}
- STDMETHODIMP get_MoreInfoURL(BSTR* pbstrMoreInfoURL) {return E_NOTIMPL;}
- STDMETHODIMP get_MoreInfoBannerImage(BSTR* pbstrMoreInfoBannerImage) {return E_NOTIMPL;}
- STDMETHODIMP get_MoreInfoBannerURL(BSTR* pbstrMoreInfoBannerURL) {return E_NOTIMPL;}
- STDMETHODIMP get_MoreInfoText(BSTR* pbstrMoreInfoText) {return E_NOTIMPL;}
+ STDMETHODIMP get_Rating(BSTR* pbstrRating) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_Description(BSTR* pbstrDescription) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_Copyright(BSTR* pbstrCopyright) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_BaseURL(BSTR* pbstrBaseURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_LogoURL(BSTR* pbstrLogoURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_LogoIconURL(BSTR* pbstrLogoURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_WatermarkURL(BSTR* pbstrWatermarkURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_MoreInfoURL(BSTR* pbstrMoreInfoURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_MoreInfoBannerImage(BSTR* pbstrMoreInfoBannerImage) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_MoreInfoBannerURL(BSTR* pbstrMoreInfoBannerURL) {
+ return E_NOTIMPL;
+ }
+ STDMETHODIMP get_MoreInfoText(BSTR* pbstrMoreInfoText) {
+ return E_NOTIMPL;
+ }
};
class CShoutcastStream : public CSourceStream
@@ -84,13 +116,19 @@ class CShoutcastStream : public CSourceStream BYTE* pData;
REFERENCE_TIME rtStart, rtStop;
CString title;
- mp3frame(DWORD len = 0) {this->len = len; pData = len ? DNew BYTE[len] : NULL; rtStart = rtStop = 0;}
- mp3frame(const mp3frame& f) {*this = f;}
- ~mp3frame() {delete pData;}
- mp3frame& operator = (const mp3frame& f)
- {
- if(this != &f)
- {
+ mp3frame(DWORD len = 0) {
+ this->len = len;
+ pData = len ? DNew BYTE[len] : NULL;
+ rtStart = rtStop = 0;
+ }
+ mp3frame(const mp3frame& f) {
+ *this = f;
+ }
+ ~mp3frame() {
+ delete pData;
+ }
+ mp3frame& operator = (const mp3frame& f) {
+ if(this != &f) {
len = f.len;
pData = f.pData;
rtStart = f.rtStart;
@@ -109,7 +147,9 @@ class CShoutcastStream : public CSourceStream DWORD m_nBytesRead;
public:
- CShoutcastSocket() {m_metaint = m_bitrate = m_freq = m_channels = 0;}
+ CShoutcastSocket() {
+ m_metaint = m_bitrate = m_freq = m_channels = 0;
+ }
int Receive(void* lpBuf, int nBufLen, int nFlags = 0);
DWORD m_metaint, m_bitrate, m_freq, m_channels;
@@ -126,7 +166,7 @@ class CShoutcastStream : public CSourceStream CString m_title;
public:
- CShoutcastStream(const WCHAR* wfn, CShoutcastSource* pParent, HRESULT* phr);
+ CShoutcastStream(const WCHAR* wfn, CShoutcastSource* pParent, HRESULT* phr);
virtual ~CShoutcastStream();
bool fExitThread;
@@ -136,15 +176,17 @@ public: LONGLONG GetBufferFullness();
CString GetTitle();
- HRESULT DecideBufferSize(IMemAllocator* pIMemAlloc, ALLOCATOR_PROPERTIES* pProperties);
- HRESULT FillBuffer(IMediaSample* pSample);
- HRESULT CheckMediaType(const CMediaType* pMediaType);
- HRESULT GetMediaType(int iPosition, CMediaType* pmt);
+ HRESULT DecideBufferSize(IMemAllocator* pIMemAlloc, ALLOCATOR_PROPERTIES* pProperties);
+ HRESULT FillBuffer(IMediaSample* pSample);
+ HRESULT CheckMediaType(const CMediaType* pMediaType);
+ HRESULT GetMediaType(int iPosition, CMediaType* pmt);
- STDMETHODIMP Notify(IBaseFilter* pSender, Quality q) {return E_NOTIMPL;}
+ STDMETHODIMP Notify(IBaseFilter* pSender, Quality q) {
+ return E_NOTIMPL;
+ }
- HRESULT OnThreadCreate();
- HRESULT OnThreadDestroy();
+ HRESULT OnThreadCreate();
+ HRESULT OnThreadDestroy();
HRESULT Inactive();
- HRESULT Pause();
+ HRESULT Pause();
};
|