Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

[PAPlayer] Remove BXACodec and use DVDPlayerCodec instead #1571

Merged
4 commits merged into from

2 participants

@Memphiz
Owner

Quick @cptspiff - before someone changes the projects :D

tested on osx/ios/linux

@jmarshallnz

Could possibly do with a comment as to what x-xbmc-pcm is (it was kinda obvious before from the code, not so much now)

@Memphiz Memphiz was assigned
@jmarshallnz
Owner

Looks fine to me

@Memphiz
Owner

yep - added the comments. After frodo we should rename BXA too i guess. (this was a leftover from initial pull from boxee code. Seems to mean Boxee Audio Codec or so :D ).

@ghost ghost merged commit 7942c1e into xbmc:master
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
View
6 XBMC-ATV2.xcodeproj/project.pbxproj
@@ -104,7 +104,6 @@
DF33C2A415509C1B0046CDCB /* XbmcContext.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF33C2A215509C1B0046CDCB /* XbmcContext.cpp */; };
DF33C2AE15509C5A0046CDCB /* ilog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF33C2AB15509C5A0046CDCB /* ilog.cpp */; };
DF34890913FD96390026A711 /* GUIAction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF34890713FD96390026A711 /* GUIAction.cpp */; };
- DF44852F140064F40069344B /* BXAcodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF44852D140064F40069344B /* BXAcodec.cpp */; };
DF4485351400651B0069344B /* PipesManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF4485321400651B0069344B /* PipesManager.cpp */; };
DF4485381400654A0069344B /* AirTunesServer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF4485361400654A0069344B /* AirTunesServer.cpp */; };
DF527780151BAFD600B5B63B /* WebSocket.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF527777151BAFD600B5B63B /* WebSocket.cpp */; };
@@ -1259,8 +1258,6 @@
DF33C2AC15509C5A0046CDCB /* ilog.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ilog.h; sourceTree = "<group>"; };
DF34890713FD96390026A711 /* GUIAction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GUIAction.cpp; sourceTree = "<group>"; };
DF34890813FD96390026A711 /* GUIAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GUIAction.h; sourceTree = "<group>"; };
- DF44852D140064F40069344B /* BXAcodec.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BXAcodec.cpp; sourceTree = "<group>"; };
- DF44852E140064F40069344B /* BXAcodec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BXAcodec.h; sourceTree = "<group>"; };
DF4485321400651B0069344B /* PipesManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PipesManager.cpp; sourceTree = "<group>"; };
DF4485331400651B0069344B /* PipesManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PipesManager.h; sourceTree = "<group>"; };
DF4485361400654A0069344B /* AirTunesServer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AirTunesServer.cpp; sourceTree = "<group>"; };
@@ -4487,8 +4484,6 @@
F56C7305131EC151000AD0F6 /* ASAPCodec.h */,
F56C730C131EC151000AD0F6 /* AudioDecoder.cpp */,
F56C730D131EC151000AD0F6 /* AudioDecoder.h */,
- DF44852D140064F40069344B /* BXAcodec.cpp */,
- DF44852E140064F40069344B /* BXAcodec.h */,
F56C730E131EC151000AD0F6 /* CachingCodec.h */,
F56C730F131EC151000AD0F6 /* CDDAcodec.cpp */,
F56C7310131EC151000AD0F6 /* CDDAcodec.h */,
@@ -7396,7 +7391,6 @@
18968DE814155E1D005BA742 /* ApplicationOperations.cpp in Sources */,
DFCFC53D1413F7F70004D0BF /* AFPDirectory.cpp in Sources */,
32D6D47C1423A9D8003641AC /* JpegIO.cpp in Sources */,
- DF44852F140064F40069344B /* BXAcodec.cpp in Sources */,
DF4485351400651B0069344B /* PipesManager.cpp in Sources */,
DF4485381400654A0069344B /* AirTunesServer.cpp in Sources */,
DF98D9A81434F4B400A6EBE1 /* SkinVariable.cpp in Sources */,
View
6 XBMC-IOS.xcodeproj/project.pbxproj
@@ -105,7 +105,6 @@
DF2E329415509B2C000F5772 /* XbmcContext.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF2E329215509B2C000F5772 /* XbmcContext.cpp */; };
DF33C29415509BF50046CDCB /* ilog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF33C29115509BF50046CDCB /* ilog.cpp */; };
DF3488F813FD961A0026A711 /* GUIAction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF3488F613FD961A0026A711 /* GUIAction.cpp */; };
- DF44856C140065C60069344B /* BXAcodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF44856A140065C60069344B /* BXAcodec.cpp */; };
DF448572140065E10069344B /* PipesManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF44856F140065E10069344B /* PipesManager.cpp */; };
DF4485751400662D0069344B /* AirTunesServer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF4485731400662D0069344B /* AirTunesServer.cpp */; };
DF527757151BAF8200B5B63B /* WebSocket.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF52774E151BAF8200B5B63B /* WebSocket.cpp */; };
@@ -1265,8 +1264,6 @@
DF33C29215509BF50046CDCB /* ilog.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ilog.h; sourceTree = "<group>"; };
DF3488F613FD961A0026A711 /* GUIAction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = GUIAction.cpp; sourceTree = "<group>"; };
DF3488F713FD961A0026A711 /* GUIAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GUIAction.h; sourceTree = "<group>"; };
- DF44856A140065C60069344B /* BXAcodec.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BXAcodec.cpp; sourceTree = "<group>"; };
- DF44856B140065C60069344B /* BXAcodec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BXAcodec.h; sourceTree = "<group>"; };
DF44856F140065E10069344B /* PipesManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PipesManager.cpp; sourceTree = "<group>"; };
DF448570140065E10069344B /* PipesManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PipesManager.h; sourceTree = "<group>"; };
DF4485731400662D0069344B /* AirTunesServer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AirTunesServer.cpp; sourceTree = "<group>"; };
@@ -4874,8 +4871,6 @@
F56C8307131F42E7000AD0F6 /* ASAPCodec.h */,
F56C830E131F42E7000AD0F6 /* AudioDecoder.cpp */,
F56C830F131F42E7000AD0F6 /* AudioDecoder.h */,
- DF44856A140065C60069344B /* BXAcodec.cpp */,
- DF44856B140065C60069344B /* BXAcodec.h */,
F56C8310131F42E7000AD0F6 /* CachingCodec.h */,
F56C8311131F42E7000AD0F6 /* CDDAcodec.cpp */,
F56C8312131F42E7000AD0F6 /* CDDAcodec.h */,
@@ -7426,7 +7421,6 @@
18968DDE14155E01005BA742 /* ApplicationOperations.cpp in Sources */,
DFCFC52A1413F7D60004D0BF /* AFPDirectory.cpp in Sources */,
3291892B1423A9B700E878CD /* JpegIO.cpp in Sources */,
- DF44856C140065C60069344B /* BXAcodec.cpp in Sources */,
DF448572140065E10069344B /* PipesManager.cpp in Sources */,
DF4485751400662D0069344B /* AirTunesServer.cpp in Sources */,
DF98D9991434F49500A6EBE1 /* SkinVariable.cpp in Sources */,
View
6 XBMC.xcodeproj/project.pbxproj
@@ -381,7 +381,6 @@
DF34898213FDAAF60026A711 /* HttpParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF34898113FDAAF60026A711 /* HttpParser.cpp */; };
DF448457140048A60069344B /* AirTunesServer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF448455140048A60069344B /* AirTunesServer.cpp */; };
DF44845E140048C80069344B /* PipesManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF44845B140048C80069344B /* PipesManager.cpp */; };
- DF4484EE140054530069344B /* BXAcodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF4484EC140054530069344B /* BXAcodec.cpp */; };
DF5276E1151BAEDA00B5B63B /* Base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF52769A151BAEDA00B5B63B /* Base64.cpp */; };
DF5276E2151BAEDA00B5B63B /* HttpResponse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF52769C151BAEDA00B5B63B /* HttpResponse.cpp */; };
DF527734151BAF4C00B5B63B /* WebSocket.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DF52772B151BAF4C00B5B63B /* WebSocket.cpp */; };
@@ -1866,8 +1865,6 @@
DF448456140048A60069344B /* AirTunesServer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AirTunesServer.h; sourceTree = "<group>"; };
DF44845B140048C80069344B /* PipesManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PipesManager.cpp; sourceTree = "<group>"; };
DF44845C140048C80069344B /* PipesManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PipesManager.h; sourceTree = "<group>"; };
- DF4484EC140054530069344B /* BXAcodec.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BXAcodec.cpp; sourceTree = "<group>"; };
- DF4484ED140054530069344B /* BXAcodec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BXAcodec.h; sourceTree = "<group>"; };
DF52769A151BAEDA00B5B63B /* Base64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Base64.cpp; sourceTree = "<group>"; };
DF52769B151BAEDA00B5B63B /* Base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Base64.h; sourceTree = "<group>"; };
DF52769C151BAEDA00B5B63B /* HttpResponse.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HttpResponse.cpp; sourceTree = "<group>"; };
@@ -5154,8 +5151,6 @@
88ACB01D0DCF409E0083CFDF /* ASAPCodec.h */,
E38E15E30D25F9FA00618676 /* AudioDecoder.cpp */,
E38E15E40D25F9FA00618676 /* AudioDecoder.h */,
- DF4484EC140054530069344B /* BXAcodec.cpp */,
- DF4484ED140054530069344B /* BXAcodec.h */,
E38E15E50D25F9FA00618676 /* CachingCodec.h */,
E38E15E60D25F9FA00618676 /* CDDAcodec.cpp */,
E38E15E70D25F9FA00618676 /* CDDAcodec.h */,
@@ -7464,7 +7459,6 @@
32C631281423A90F00F18420 /* JpegIO.cpp in Sources */,
DF448457140048A60069344B /* AirTunesServer.cpp in Sources */,
DF44845E140048C80069344B /* PipesManager.cpp in Sources */,
- DF4484EE140054530069344B /* BXAcodec.cpp in Sources */,
DF98D98C1434F47D00A6EBE1 /* SkinVariable.cpp in Sources */,
F5E10537140AA38100175026 /* PeripheralBusUSB.cpp in Sources */,
F5E10538140AA38100175026 /* PeripheralBus.cpp in Sources */,
View
4 project/VS2010Express/XBMC.vcxproj
@@ -398,7 +398,6 @@
<ClCompile Include="..\..\xbmc\cores\dvdplayer\DVDDemuxers\DVDDemuxPVRClient.cpp" />
<ClCompile Include="..\..\xbmc\cores\dvdplayer\DVDInputStreams\DVDInputStreamBluray.cpp" />
<ClCompile Include="..\..\xbmc\cores\dvdplayer\DVDInputStreams\DVDInputStreamPVRManager.cpp" />
- <ClCompile Include="..\..\xbmc\cores\paplayer\BXAcodec.cpp" />
<ClCompile Include="..\..\xbmc\cores\paplayer\PCMCodec.cpp" />
<ClCompile Include="..\..\xbmc\cores\VideoRenderers\RenderCapture.cpp" />
<ClCompile Include="..\..\xbmc\cores\VideoRenderers\VideoShaders\WinVideoFilter.cpp" />
@@ -1943,7 +1942,6 @@
<ClInclude Include="..\..\xbmc\cores\dvdplayer\DVDDemuxers\DVDDemuxPVRClient.h" />
<ClInclude Include="..\..\xbmc\cores\dvdplayer\DVDInputStreams\DVDInputStreamBluray.h" />
<ClInclude Include="..\..\xbmc\cores\dvdplayer\DVDInputStreams\DVDInputStreamPVRManager.h" />
- <ClInclude Include="..\..\xbmc\cores\paplayer\BXAcodec.h" />
<ClInclude Include="..\..\xbmc\cores\VideoRenderers\RenderCapture.h" />
<ClInclude Include="..\..\xbmc\cores\VideoRenderers\VideoShaders\WinVideoFilter.h" />
<ClInclude Include="..\..\xbmc\CueDocument.h" />
@@ -2917,4 +2915,4 @@
</VisualStudio>
</ProjectExtensions>
<Import Project="$(SolutionDir)\$(ProjectFileName).targets.user" Condition="Exists('$(SolutionDir)\$(ProjectFileName).targets.user')" />
-</Project>
+</Project>
View
8 project/VS2010Express/XBMC.vcxproj.filters
@@ -1996,9 +1996,6 @@
<ClCompile Include="..\..\xbmc\guilib\JpegIO.cpp">
<Filter>guilib</Filter>
</ClCompile>
- <ClCompile Include="..\..\xbmc\cores\paplayer\BXAcodec.cpp">
- <Filter>cores\paplayer</Filter>
- </ClCompile>
<ClCompile Include="..\..\xbmc\interfaces\info\SkinVariable.cpp">
<Filter>interfaces\info</Filter>
</ClCompile>
@@ -4912,9 +4909,6 @@
<ClInclude Include="..\..\xbmc\guilib\JpegIO.h">
<Filter>guilib</Filter>
</ClInclude>
- <ClInclude Include="..\..\xbmc\cores\paplayer\BXAcodec.h">
- <Filter>cores\paplayer</Filter>
- </ClInclude>
<ClInclude Include="..\..\xbmc\interfaces\info\SkinVariable.h">
<Filter>interfaces\info</Filter>
</ClInclude>
@@ -5777,4 +5771,4 @@
<Filter>interfaces\swig</Filter>
</None>
</ItemGroup>
-</Project>
+</Project>
View
2  xbmc/cores/dvdplayer/DVDDemuxers/DVDFactoryDemuxer.cpp
@@ -43,6 +43,8 @@ CDVDDemux* CDVDFactoryDemuxer::CreateDemuxer(CDVDInputStream* pInputStream)
// Try to open the AirTunes demuxer
if (pInputStream->IsStreamType(DVDSTREAM_TYPE_FILE) && pInputStream->GetContent().compare("audio/x-xbmc-pcm") == 0 )
{
+ // audio/x-xbmc-pcm this is the used codec for AirTunes
+ // (apples audio only streaming)
auto_ptr<CDVDDemuxBXA> demuxer(new CDVDDemuxBXA());
if(demuxer->Open(pInputStream))
return demuxer.release();
View
126 xbmc/cores/paplayer/BXAcodec.cpp
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2005-2012 Team XBMC
- * http://www.xbmc.org
- *
- * This Program is free software; you can redistribute it and/or modify
- * 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 XBMC; see the file COPYING. If not, see
- * <http://www.gnu.org/licenses/>.
- *
- */
-
-#include "system.h"
-#include "BXAcodec.h"
-#include "utils/EndianSwap.h"
-#include "cores/AudioEngine/Utils/AEUtil.h"
-
-BXACodec::BXACodec()
-{
- m_SampleRate = 0;
- m_Channels = 0;
- m_BitsPerSample = 0;
- m_Bitrate = 0;
- m_CodecName = "XBMC PCM";
-}
-
-BXACodec::~BXACodec()
-{
- DeInit();
-}
-
-bool BXACodec::Init(const CStdString &strFile, unsigned int filecache)
-{
- if (!m_file.Open(strFile))
- return false;
-
- // read header
- BXA_FmtHeader bxah;
- m_file.Read(&bxah, sizeof(BXA_FmtHeader));
-
- // file valid?
- if (strncmp(bxah.fourcc, "BXA ", 4) != 0 || bxah.type != BXA_PACKET_TYPE_FMT)
- {
- return false;
- }
-
- m_SampleRate = bxah.sampleRate;
- m_Channels = bxah.channels;
- m_BitsPerSample = bxah.bitsPerSample;
- m_TotalTime = bxah.durationMs;
- m_Bitrate = bxah.sampleRate * bxah.channels * bxah.bitsPerSample;
- m_DataFormat = AE_FMT_S16LE;
-
- if (m_SampleRate == 0 || m_Channels == 0 || m_BitsPerSample == 0)
- {
- return false;
- }
-
- return true;
-}
-
-void BXACodec::DeInit()
-{
- m_file.Close();
-}
-
-int64_t BXACodec::Seek(int64_t iSeekTime)
-{
- return iSeekTime;
-}
-
-template <class T>
-class MiniScopedArray
-{
-public:
- MiniScopedArray(int size) {m_arr = new T[size];}
- ~MiniScopedArray() {delete[] m_arr;}
- T* raw_data() {return m_arr;}
-private:
- T* m_arr;
-};
-
-int BXACodec::ReadPCM(BYTE *pBuffer, int size, int *actualsize)
-{
- *actualsize=0;
-
- int iAmountRead;
- //unsigned char data[size];
- MiniScopedArray<char> data(size);
- iAmountRead = m_file.Read(data.raw_data(), size);
- if (iAmountRead > 0)
- {
- *actualsize=iAmountRead;
- memcpy(pBuffer, data.raw_data(), iAmountRead <= size ? iAmountRead : size);
- return READ_SUCCESS;
- }
-
- *actualsize = 0;
- return READ_EOF;
-}
-
-bool BXACodec::CanInit()
-{
- return true;
-}
-
-CAEChannelInfo BXACodec::GetChannelInfo()
-{
- static enum AEChannel map[2][3] = {
- {AE_CH_FC, AE_CH_NULL},
- {AE_CH_FL, AE_CH_FR , AE_CH_NULL}
- };
-
- if (m_Channels > 2)
- return CAEUtil::GuessChLayout(m_Channels);
-
- return CAEChannelInfo(map[m_Channels - 1]);
-}
View
74 xbmc/cores/paplayer/BXAcodec.h
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2005-2012 Team XBMC
- * http://www.xbmc.org
- *
- * This Program is free software; you can redistribute it and/or modify
- * 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 XBMC; see the file COPYING. If not, see
- * <http://www.gnu.org/licenses/>.
- *
- */
-
-#pragma once
-
-#include "ICodec.h"
-#include "filesystem/File.h"
-#include "CachingCodec.h"
-#ifdef _WIN32
-#define __attribute__(dummy_val)
-#else
-#include <config.h>
-#endif
-
-#ifdef _WIN32
-#pragma pack(push)
-#pragma pack(1)
-#endif
-
-typedef struct
-{
- char fourcc[4];
- uint32_t type;
- uint32_t channels;
- uint32_t sampleRate;
- uint32_t bitsPerSample;
- uint64_t durationMs;
-} __attribute__((__packed__)) BXA_FmtHeader;
-
-typedef struct
-{
- char fourcc[4];
- uint32_t type;
- uint32_t length;
-} __attribute__((__packed__)) BXA_DataHeader;
-
-#ifdef _WIN32
-#pragma pack(pop)
-#endif
-
-#define BXA_PACKET_TYPE_FMT 1
-#define BXA_PACKET_TYPE_DATA 2
-
-class BXACodec : public CachingCodec
-{
-public:
- BXACodec();
- virtual ~BXACodec();
-
- virtual bool Init(const CStdString &strFile, unsigned int filecache);
- virtual void DeInit();
- virtual int64_t Seek(int64_t iSeekTime);
- virtual int ReadPCM(BYTE *pBuffer, int size, int *actualsize);
- virtual bool CanInit();
- virtual CAEChannelInfo GetChannelInfo();
-};
-
View
13 xbmc/cores/paplayer/CodecFactory.cpp
@@ -40,7 +40,6 @@
#endif
#include "URL.h"
#include "DVDPlayerCodec.h"
-#include "BXAcodec.h"
#include "PCMCodec.h"
ICodec* CodecFactory::CreateCodec(const CStdString& strFileType)
@@ -139,9 +138,15 @@ ICodec* CodecFactory::CreateCodecDemux(const CStdString& strFile, const CStdStri
else if( strContent.Equals("application/ogg") || strContent.Equals("audio/ogg"))
return CreateOGGCodec(strFile,filecache);
else if (strContent.Equals("audio/x-xbmc-pcm"))
- return (ICodec*)new BXACodec();
- else if (strContent.Equals("audio/flac") || strContent.Equals("audio/x-flac") || strContent.Equals("application/x-flac"))
- return new FLACCodec();
+ {
+ // audio/x-xbmc-pcm this is the used codec for AirTunes
+ // (apples audio only streaming)
+ DVDPlayerCodec *dvdcodec = new DVDPlayerCodec();
+ dvdcodec->SetContentType(strContent);
+ return dvdcodec;
+ }
+ else if (strContent.Equals("audio/flac") || strContent.Equals("audio/x-flac") || strContent.Equals("application/x-flac"))
+ return new FLACCodec();
if (urlFile.GetProtocol() == "lastfm" || urlFile.GetProtocol() == "shout")
{
View
1  xbmc/cores/paplayer/Makefile.in
@@ -9,7 +9,6 @@ endif
SRCS = ADPCMCodec.cpp
SRCS += AudioDecoder.cpp
-SRCS += BXAcodec.cpp
SRCS += CDDAcodec.cpp
SRCS += CodecFactory.cpp
SRCS += DVDPlayerCodec.cpp
View
9 xbmc/network/AirTunesServer.cpp
@@ -35,7 +35,8 @@
#include "ApplicationMessenger.h"
#include "filesystem/PipeFile.h"
#include "Application.h"
-#include "cores/paplayer/BXAcodec.h"
+#include "cores/dvdplayer/DVDDemuxers/DVDDemuxBXA.h"
+#include "filesystem/File.h"
#include "music/tags/MusicInfoTag.h"
#include "FileItem.h"
#include "GUIInfoManager.h"
@@ -160,7 +161,7 @@ void* CAirTunesServer::AudioOutputFunctions::audio_init(void *cls, int bits, int
pipe->OpenForWrite(XFILE::PipesManager::GetInstance().GetUniquePipeName());
pipe->SetOpenThreashold(300);
- BXA_FmtHeader header;
+ Demux_BXA_FmtHeader header;
strncpy(header.fourcc, "BXA ", 4);
header.type = BXA_PACKET_TYPE_FMT;
header.bitsPerSample = bits;
@@ -328,9 +329,9 @@ ao_device* CAirTunesServer::AudioOutputFunctions::ao_open_live(int driver_id, ao
device->pipe->OpenForWrite(XFILE::PipesManager::GetInstance().GetUniquePipeName());
device->pipe->SetOpenThreashold(300);
- BXA_FmtHeader header;
+ Demux_BXA_FmtHeader header;
strncpy(header.fourcc, "BXA ", 4);
- header.type = BXA_PACKET_TYPE_FMT;
+ header.type = BXA_PACKET_TYPE_FMT_DEMUX;
header.bitsPerSample = format->bits;
header.channels = format->channels;
header.sampleRate = format->rate;
Something went wrong with that request. Please try again.