[svn] / trunk / xvidcore / dshow / dxpatch / DXVCSDK-9.0-gcc.patch Repository:
ViewVC logotype

View of /trunk/xvidcore/dshow/dxpatch/DXVCSDK-9.0-gcc.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1504 - (download) (annotate)
Sun Jul 18 04:10:22 2004 UTC (15 years ago) by suxen_drol
File size: 6053 byte(s)
gcc build environment
diff -urN /c/DXVCSDK-orig/Include/strmif.h ./Include/strmif.h
--- /c/DXVCSDK-orig/Include/strmif.h	Wed Dec  4 01:03:00 2002
+++ ./Include/strmif.h	Fri Jul 16 21:22:28 2004
@@ -28732,8 +28732,8 @@
 
 typedef struct tagVMRGUID
     {
-    GUID *pGUID;
-    GUID GUID;
+    ::GUID *pGUID;
+    ::GUID GUID;
     } 	VMRGUID;
 
 typedef struct tagVMRMONITORINFO
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/Makefile ./Samples/MultiMedia/Directshow/BaseClasses/Makefile
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/Makefile	Thu Jan  1 10:00:00 1970
+++ ./Samples/MultiMedia/Directshow/BaseClasses/Makefile	Sun Jul 18 12:13:06 2004
@@ -0,0 +1,25 @@
+SRC=amextra.cpp amfilter.cpp amvideo.cpp combase.cpp cprop.cpp ctlutil.cpp ddmm.cpp dllentry.cpp dllsetup.cpp mtype.cpp outputq.cpp pstream.cpp pullpin.cpp refclock.cpp renbase.cpp schedule.cpp seekpt.cpp source.cpp strmctl.cpp sysclock.cpp transfrm.cpp transip.cpp videoctl.cpp vtrans.cpp winctrl.cpp winutil.cpp wxdebug.cpp wxlist.cpp wxutil.cpp
+
+#DXROOT=/c/DXVCSDK
+DXROOT=../../../..
+OBJ=$(SRC:.cpp=.o)
+LIB=strmbase.lib
+
+CXX=g++
+CXXFLAGS=-O2 -fno-for-scope -mthreads
+
+all: $(LIB)
+
+$(LIB): $(OBJ)
+	$(AR) $(ARFLAGS) $@ $^
+
+.cpp.o:
+	$(CXX) $(CXXFLAGS) \
+	-DRELEASE \
+	-I$(DXROOT)/Include \
+	-I$(DXROOT)/samples/MultiMedia/DirectShow/BaseClasses \
+	-include $(DXROOT)/mingw_dshow_port.h \
+	-c $(CXXFLAGS) $< -o $@
+
+clean:
+	rm $(OBJ)
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ctlutil.cpp ./Samples/MultiMedia/Directshow/BaseClasses/ctlutil.cpp
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ctlutil.cpp	Tue Nov 12 20:11:26 2002
+++ ./Samples/MultiMedia/Directshow/BaseClasses/ctlutil.cpp	Fri Jul 16 21:21:06 2004
@@ -709,7 +709,7 @@
 
 HRESULT
 CPosPassThru::GetSeekingLongLong
-( HRESULT (__stdcall IMediaSeeking::*pMethod)( LONGLONG * )
+( HRESULT ( IMediaSeeking::*pMethod)( LONGLONG * )
 , LONGLONG * pll
 )
 {
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ctlutil.h ./Samples/MultiMedia/Directshow/BaseClasses/ctlutil.h
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ctlutil.h	Tue Nov 12 20:11:26 2002
+++ ./Samples/MultiMedia/Directshow/BaseClasses/ctlutil.h	Fri Jul 16 21:21:57 2004
@@ -275,7 +275,7 @@
     //  Prevent bugs from constructing from LONG (which gets
     //  converted to double and then multiplied by 10000000
     COARefTime(LONG);
-    operator=(LONG);
+    COARefTime& operator=(LONG);
 };
 
 
@@ -355,7 +355,7 @@
     STDMETHODIMP CanSeekBackward(LONG *pCanSeekBackward);
 
 private:
-    HRESULT GetSeekingLongLong( HRESULT (__stdcall IMediaSeeking::*pMethod)( LONGLONG * ),
+    HRESULT GetSeekingLongLong( HRESULT ( IMediaSeeking::*pMethod)( LONGLONG * ),
                                 LONGLONG * pll );
 };
 
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ddmm.cpp ./Samples/MultiMedia/Directshow/BaseClasses/ddmm.cpp
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/ddmm.cpp	Tue Nov 12 20:11:26 2002
+++ ./Samples/MultiMedia/Directshow/BaseClasses/ddmm.cpp	Fri Jul 16 21:42:13 2004
@@ -17,8 +17,8 @@
  */
 typedef struct {
 	LPSTR   szDevice;
-	GUID*   lpGUID;
-	GUID    GUID;
+	::GUID*   lpGUID;
+	::GUID    GUID;
 	BOOL    fFound;
 }   FindDeviceData;
 
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/mtype.cpp ./Samples/MultiMedia/Directshow/BaseClasses/mtype.cpp
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/mtype.cpp	Tue Nov 12 20:11:26 2002
+++ ./Samples/MultiMedia/Directshow/BaseClasses/mtype.cpp	Fri Jul 16 21:43:44 2004
@@ -13,7 +13,6 @@
 // in the streams IDL file, but also has (non-virtual) functions
 
 #include <streams.h>
-#include <mmreg.h>
 
 CMediaType::~CMediaType(){
     FreeMediaType(*this);
diff -urN /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/wxdebug.cpp ./Samples/MultiMedia/Directshow/BaseClasses/wxdebug.cpp
--- /c/DXVCSDK-orig/Samples/MultiMedia/Directshow/BaseClasses/wxdebug.cpp	Tue Nov 12 20:11:26 2002
+++ ./Samples/MultiMedia/Directshow/BaseClasses/wxdebug.cpp	Sun Jul 18 13:21:46 2004
@@ -564,7 +564,7 @@
     {
         // re-read the registry every second. We cannot use RegNotify() to
         // notice registry changes because it's not available on win9x.
-        static g_dwLastRefresh = 0;
+        static DWORD g_dwLastRefresh = 0;
         DWORD dwTime = timeGetTime();
         if(dwTime - g_dwLastRefresh > 1000) {
             g_dwLastRefresh = dwTime;
@@ -1143,7 +1143,33 @@
     hr = pUnk->QueryInterface(IID_IPin, (void **)&pp);
     if(SUCCEEDED(hr))
     {
-        CDisp::CDisp(pp);
+/* --- copy from CDisp::CDisp(IPin*) --- */
+        PIN_INFO pi;
+        TCHAR str[MAX_PIN_NAME];
+        CLSID clsid;
+
+        if (pp) {
+           pp->QueryPinInfo(&pi);
+           pi.pFilter->GetClassID(&clsid);
+           QueryPinInfoReleaseFilter(pi);
+          #ifndef UNICODE
+           WideCharToMultiByte(GetACP(), 0, pi.achName, lstrlenW(pi.achName) + 1,
+                           str, MAX_PIN_NAME, NULL, NULL);
+          #else
+           lstrcpy(str, pi.achName);
+          #endif
+        } else {
+           lstrcpy(str, TEXT("NULL IPin"));
+        }
+
+        m_pString = (PTCHAR) new TCHAR[lstrlen(str)+64];
+        if (!m_pString) {
+            pp->Release();
+	    return;
+        }
+
+        wsprintf(m_pString, TEXT("%hs(%s)"), GuidNames[clsid], str);
+/* --- copy from CDisp::CDisp(IPin*) --- */
         pp->Release();
         return;
     }
diff -urN /c/DXVCSDK-orig/mingw_dshow_port.h ./mingw_dshow_port.h
--- /c/DXVCSDK-orig/mingw_dshow_port.h	Thu Jan  1 10:00:00 1970
+++ ./mingw_dshow_port.h	Sun Jul 18 12:15:19 2004
@@ -0,0 +1,12 @@
+#include <wtypes.h>
+#include <unknwn.h>
+#include <ole2.h>
+#include <limits.h>
+
+#define _WINGDI_ 1
+#define AM_NOVTABLE
+#define _OBJBASE_H_
+#undef _X86_
+#define _I64_MAX LONG_LONG_MAX
+#define EXTERN_GUID(itf,l1,s1,s2,c1,c2,c3,c4,c5,c6,c7,c8)  \
+	EXTERN_C static const IID itf = {l1,s1,s2,{c1,c2,c3,c4,c5,c6,c7,c8} }

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4