summaryrefslogtreecommitdiff
path: root/src/libw32dll/DirectShow/DS_VideoDecoder.c
diff options
context:
space:
mode:
authorMiguel Freitas <miguelfreitas@users.sourceforge.net>2002-06-21 01:44:17 +0000
committerMiguel Freitas <miguelfreitas@users.sourceforge.net>2002-06-21 01:44:17 +0000
commit4aadaafa08dc0d3b926378581c37b2e2f0492731 (patch)
treee55d8f0e689963677d574d1ac0714dc33d924735 /src/libw32dll/DirectShow/DS_VideoDecoder.c
parenta3be47db5aea60af614bc11fa1d9d726fabeba19 (diff)
downloadxine-lib-4aadaafa08dc0d3b926378581c37b2e2f0492731.tar.gz
xine-lib-4aadaafa08dc0d3b926378581c37b2e2f0492731.tar.bz2
update win32 codec loading code
- shiny new win32 crap from avifile and mplayer! - shiny new compilation warnings! - use directshow filter to decode msmpeg v1/v2 - disable SYNC_SHUTDOWN ugly hack (will be removed soon, i hope) CVS patchset: 2114 CVS date: 2002/06/21 01:44:17
Diffstat (limited to 'src/libw32dll/DirectShow/DS_VideoDecoder.c')
-rw-r--r--src/libw32dll/DirectShow/DS_VideoDecoder.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/libw32dll/DirectShow/DS_VideoDecoder.c b/src/libw32dll/DirectShow/DS_VideoDecoder.c
index faa080fef..33c51b4d2 100644
--- a/src/libw32dll/DirectShow/DS_VideoDecoder.c
+++ b/src/libw32dll/DirectShow/DS_VideoDecoder.c
@@ -106,10 +106,10 @@ DS_VideoDecoder * DS_VideoDecoder_Open(char* dllname, GUID* guid, BITMAPINFOHEAD
bihs = (format->biSize < (int) sizeof(BITMAPINFOHEADER)) ?
sizeof(BITMAPINFOHEADER) : format->biSize;
- bihs = sizeof(VIDEOINFOHEADER) - sizeof(BITMAPINFOHEADER) + bihs;
this->iv.m_bh = (BITMAPINFOHEADER*)malloc(bihs);
memcpy(this->iv.m_bh, format, bihs);
+
this->iv.m_State = STOP;
//this->iv.m_pFrame = 0;
this->iv.m_Mode = DIRECT;
@@ -118,6 +118,7 @@ DS_VideoDecoder * DS_VideoDecoder_Open(char* dllname, GUID* guid, BITMAPINFOHEAD
this->iv.m_fQuality = 0.0f;
this->iv.m_bCapable16b = true;
+ bihs += sizeof(VIDEOINFOHEADER) - sizeof(BITMAPINFOHEADER);
this->m_sVhdr = (VIDEOINFOHEADER*)malloc(bihs);
memset(this->m_sVhdr, 0, bihs);
memcpy(&this->m_sVhdr->bmiHeader, this->iv.m_bh, this->iv.m_bh->biSize);
@@ -725,7 +726,7 @@ int DS_VideoDecoder_SetValue(DS_VideoDecoder *this, const char* name, int value)
{
if (this->m_bIsDivX4) {
IDivxFilterInterface* pIDivx=NULL;
- printf("DS_SetValue for DIVX4, name=%s value=%d\n",name,value);
+// printf("DS_SetValue for DIVX4, name=%s value=%d\n",name,value);
if (this->m_pDS_Filter->m_pFilter->vt->QueryInterface((IUnknown*)this->m_pDS_Filter->m_pFilter, &IID_IDivxFilterInterface, (void**)&pIDivx))
{
printf("No such interface\n");
@@ -764,7 +765,7 @@ int DS_VideoDecoder_SetValue(DS_VideoDecoder *this, const char* name, int value)
// get5=set4 19
// get6=set5 23
hidden = (IHidden*)((int)this->m_pDS_Filter->m_pFilter + 0xb8);
- printf("DS_SetValue for DIVX, name=%s value=%d\n",name,value);
+// printf("DS_SetValue for DIVX, name=%s value=%d\n",name,value);
if (strcmp(name, "Quality") == 0)
{
this->m_iLastQuality = value;
@@ -826,7 +827,7 @@ int DS_VideoDecoder_SetValue(DS_VideoDecoder *this, const char* name, int value)
return result;
}
#endif
- printf("DS_SetValue for ????, name=%s value=%d\n",name,value);
+// printf("DS_SetValue for ????, name=%s value=%d\n",name,value);
return 0;
}
/*