[xiph-commits] r11039 - in branches/oggdsf_ce_port/src/lib: codecs/vorbis/filters/dsfVorbisDecoder core/directshow/dsfOggDemux2

illiminable at svn.xiph.org illiminable at svn.xiph.org
Mon Mar 20 10:31:59 PST 2006


Author: illiminable
Date: 2006-03-20 10:31:44 -0800 (Mon, 20 Mar 2006)
New Revision: 11039

Modified:
   branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.cpp
   branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.h
   branches/oggdsf_ce_port/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp
Log:
* Can now build a graph, and play vorbis in wm5. Still only tried on emulator... performance is terrible. Not ready to risk hosing the real phone yet!
* A bit more debugging stuff in demux and vorbis filter
* Doesn't install correctly from cab but with enough registry gaffer tape can work around that


Modified: branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.cpp
===================================================================
--- branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.cpp	2006-03-20 16:12:33 UTC (rev 11038)
+++ branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.cpp	2006-03-20 18:31:44 UTC (rev 11039)
@@ -61,15 +61,17 @@
 	,	mSentStreamOffset(false)
 		
 {
-	//debugLog.open("g:\\logs\\vorbislog.log", ios_base::out);
+	debugLog.open(L"\\Storage Card\\vorbinpin.txt", ios_base::out);
+	debugLog<<"Pin constructor"<<endl;
 	ConstructCodec();
+	debugLog<<"Pin constructor - post construct codec"<<endl;
 
 	mDecodedBuffer = new unsigned char[DECODED_BUFFER_SIZE];
 }
 
 VorbisDecodeInputPin::~VorbisDecodeInputPin(void)
 {
-	//debugLog.close();
+	debugLog.close();
 	DestroyCodec();
 	delete[] mDecodedBuffer;
 
@@ -330,7 +332,7 @@
 
 	if (CheckMediaType(inMediaType) == S_OK) {
 		((VorbisDecodeFilter*)mParentFilter)->setVorbisFormat(inMediaType->pbFormat);
-		
+		debugLog<<"Set media type"<<endl;
 	} else {
 		throw 0;
 	}
@@ -342,10 +344,12 @@
 		if (inMediaType->cbFormat == VORBIS_IDENT_HEADER_SIZE) {
 			if (strncmp((char*)inMediaType->pbFormat, "\001vorbis", 7) == 0) {
 				//TODO::: Possibly verify version
+				debugLog<<"Check media type ok"<<endl;
 				return S_OK;
 			}
 		}
 	}
+	debugLog<<"Check media type failed"<<endl;
 	return S_FALSE;
 	
 }
@@ -382,6 +386,7 @@
 				//TODO::: Possibly verify version
 				if (fish_sound_decode(mFishSound, inCodecHeaderPacket->packetData(), inCodecHeaderPacket->packetSize()) >= 0) {
 					mSetupState = VSS_SEEN_BOS;
+					debugLog<<"Saw first header"<<endl;
 					return IOggDecoder::AHR_MORE_HEADERS_TO_COME;
 				}
 			}
@@ -392,6 +397,7 @@
 			if (strncmp((char*)inCodecHeaderPacket->packetData(), "\003vorbis", 7) == 0) {
 				if (fish_sound_decode(mFishSound, inCodecHeaderPacket->packetData(), inCodecHeaderPacket->packetSize()) >= 0) {
 					mSetupState = VSS_SEEN_COMMENT;
+					debugLog<<"Saw second header"<<endl;
 					return IOggDecoder::AHR_MORE_HEADERS_TO_COME;
 				}
 				
@@ -414,6 +420,7 @@
 
 		
 					mSetupState = VSS_ALL_HEADERS_SEEN;
+					debugLog<<"Saw third header"<<endl;
 					return IOggDecoder::AHR_ALL_HEADERS_RECEIVED;
 				}
 				
@@ -447,6 +454,7 @@
 	} else {
 		mOggOutputPinInterface = NULL;
 	}
+	debugLog<<"Complete Connect"<<endl;
 	return AbstractTransformInputPin::CompleteConnect(inReceivePin);
 	
 }
\ No newline at end of file

Modified: branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.h
===================================================================
--- branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.h	2006-03-20 16:12:33 UTC (rev 11038)
+++ branches/oggdsf_ce_port/src/lib/codecs/vorbis/filters/dsfVorbisDecoder/VorbisDecodeInputPin.h	2006-03-20 18:31:44 UTC (rev 11039)
@@ -84,7 +84,7 @@
 
 
 protected:
-	//fstream debugLog;
+	fstream debugLog;
 
 	static const unsigned long DECODED_BUFFER_SIZE = 1<<20;		//1 Meg buffer
 

Modified: branches/oggdsf_ce_port/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp
===================================================================
--- branches/oggdsf_ce_port/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp	2006-03-20 16:12:33 UTC (rev 11038)
+++ branches/oggdsf_ce_port/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp	2006-03-20 18:31:44 UTC (rev 11039)
@@ -372,7 +372,7 @@
 				locRetryCount++;
 			//This prevents us dying on small files, if we hit eof but we also saw a +'ve gran pos, this file is ok.
 			} else if (!(mDataSource->isEOF() && mSeenPositiveGranulePos)) {
-				//debugLog<<"Bailing out"<<endl;
+				debugLog<<L"Bailing out"<<endl;
 				delete[] locBuff;
 				return VFW_E_CANNOT_RENDER;
 			}
@@ -385,7 +385,7 @@
 	//mDataSource->clear();
 	mDataSource->seek(0);			//TODO::: This is bad for streams.
 
-	//debugLog<<"COMPLETED SETUP"<<endl;
+	debugLog<<"COMPLETED SETUP"<<endl;
 	delete[] locBuff;
 	return S_OK;
 



More information about the commits mailing list