[xiph-commits] r10292 - in branches/oggdsf_new_demux/src/lib/core:
directshow/dsfOggDemux2 ogg/libOOOggSeek
illiminable at svn.xiph.org
illiminable at svn.xiph.org
Mon Oct 24 09:27:47 PDT 2005
Author: illiminable
Date: 2005-10-24 09:27:42 -0700 (Mon, 24 Oct 2005)
New Revision: 10292
Modified:
branches/oggdsf_new_demux/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp
branches/oggdsf_new_demux/src/lib/core/ogg/libOOOggSeek/AutoOggChainGranuleSeekTable.cpp
Log:
* Return duration from seek table
* Add aditional check for seek table being null when IMediaSeeking is called before all pins are conencted. Usuaully a call to getCapabilities, which will return 0 if seekTable is null, however when the graph changes this will be called again and get the actual capabilities.
Modified: branches/oggdsf_new_demux/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp
===================================================================
--- branches/oggdsf_new_demux/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp 2005-10-24 15:43:13 UTC (rev 10291)
+++ branches/oggdsf_new_demux/src/lib/core/directshow/dsfOggDemux2/OggDemuxPacketSourceFilter.cpp 2005-10-24 16:27:42 UTC (rev 10292)
@@ -526,7 +526,7 @@
STDMETHODIMP OggDemuxPacketSourceFilter::GetCapabilities(DWORD* inCapabilities)
{
- if (mSeekTable->enabled()) {
+ if ((mSeekTable != NULL) && (mSeekTable->enabled())) {
//debugLog<<"GetCaps "<<mSeekingCap<<endl;
*inCapabilities = mSeekingCap;
return S_OK;
@@ -538,7 +538,7 @@
}
STDMETHODIMP OggDemuxPacketSourceFilter::GetDuration(LONGLONG* outDuration)
{
- if (mSeekTable->enabled()) {
+ if ((mSeekTable != NULL) && (mSeekTable->enabled())) {
//debugLog<<"GetDuration = " << mSeekTable->fileDuration()<<" ds units"<<endl;
*outDuration = mSeekTable->fileDuration();
return S_OK;
@@ -584,7 +584,7 @@
return S_OK;
}
STDMETHODIMP OggDemuxPacketSourceFilter::GetStopPosition(LONGLONG *pStop){
- if (mSeekTable->enabled()) {
+ if ((mSeekTable != NULL) && (mSeekTable->enabled())) {
//debugLog<<"GetStopPos = " << mSeekTable->fileDuration()<<" ds units"<<endl;
*pStop = mSeekTable->fileDuration();
@@ -679,7 +679,7 @@
}
STDMETHODIMP OggDemuxPacketSourceFilter::GetAvailable(LONGLONG *pEarliest, LONGLONG *pLatest){
//debugLog<<"****GetAvailable : NOT IMPL"<<endl;
- if (mSeekTable->enabled()) {
+ if ((mSeekTable != NULL) && (mSeekTable->enabled())) {
//debugLog<<"Get Avail ok"<<endl;
*pEarliest = 0;
//debugLog<<"+++++ Duration is "<<mSeekTable->fileDuration()<<endl;
Modified: branches/oggdsf_new_demux/src/lib/core/ogg/libOOOggSeek/AutoOggChainGranuleSeekTable.cpp
===================================================================
--- branches/oggdsf_new_demux/src/lib/core/ogg/libOOOggSeek/AutoOggChainGranuleSeekTable.cpp 2005-10-24 15:43:13 UTC (rev 10291)
+++ branches/oggdsf_new_demux/src/lib/core/ogg/libOOOggSeek/AutoOggChainGranuleSeekTable.cpp 2005-10-24 16:27:42 UTC (rev 10292)
@@ -83,7 +83,7 @@
}
LOOG_INT64 AutoOggChainGranuleSeekTable::fileDuration()
{
-
+ return mDuration;
}
bool AutoOggChainGranuleSeekTable::acceptOggPage(OggPage* inOggPage)
{
More information about the commits
mailing list