[xiph-commits] r10342 - branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder

illiminable at svn.xiph.org illiminable at svn.xiph.org
Sat Nov 5 05:44:21 PST 2005


Author: illiminable
Date: 2005-11-05 05:44:17 -0800 (Sat, 05 Nov 2005)
New Revision: 10342

Modified:
   branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.cpp
   branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.h
Log:
* Sample accurate seeking in speex

Modified: branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.cpp
===================================================================
--- branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.cpp	2005-11-05 12:58:37 UTC (rev 10341)
+++ branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.cpp	2005-11-05 13:44:17 UTC (rev 10342)
@@ -83,6 +83,11 @@
 		*ppv = (IMediaSeeking*)this;
 		((IUnknown*)*ppv)->AddRef();
 		return NOERROR;
+	} else if (riid == IID_IOggDecoder) {
+		*ppv = (IOggDecoder*)this;
+		//((IUnknown*)*ppv)->AddRef();
+		return NOERROR;
+
 	}
 
 	return CBaseInputPin::NonDelegatingQueryInterface(riid, ppv); 
@@ -445,7 +450,7 @@
 {
 	switch (mSetupState) {
 		case VSS_SEEN_NOTHING:
-			if (strncmp((char*)inCodecHeaderPacket->packetData(), "speex   ", 8) == 0) {
+			if (strncmp((char*)inCodecHeaderPacket->packetData(), "Speex   ", 8) == 0) {
 				//TODO::: Possibly verify version
 				if (fish_sound_decode(mFishSound, inCodecHeaderPacket->packetData(), inCodecHeaderPacket->packetSize()) >= 0) {
 					mSetupState = VSS_SEEN_BOS;
@@ -463,6 +468,7 @@
 				if (fish_sound_decode(mFishSound, inCodecHeaderPacket->packetData(), inCodecHeaderPacket->packetSize()) >= 0) {
 					mSetupState = VSS_ALL_HEADERS_SEEN;
 
+					fish_sound_command (mFishSound, FISH_SOUND_GET_INFO, &(mFishInfo), sizeof (FishSoundInfo)); 
 					mBegun = true;
 			
 					mNumChannels = mFishInfo.channels;

Modified: branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.h
===================================================================
--- branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.h	2005-11-05 12:58:37 UTC (rev 10341)
+++ branches/oggdsf_new_demux/src/lib/codecs/speex/filters/dsfSpeexDecoder/SpeexDecodeInputPin.h	2005-11-05 13:44:17 UTC (rev 10342)
@@ -46,6 +46,7 @@
 
 class SpeexDecodeInputPin 
 	:	public AbstractTransformInputPin
+	,	public IOggDecoder
 {
 public:
 	DECLARE_IUNKNOWN



More information about the commits mailing list