[MPlayer-cvslog] r25155 - trunk/stream/tvi_dshow.c

voroshil subversion at mplayerhq.hu
Sat Nov 24 08:51:31 CET 2007


Author: voroshil
Date: Sat Nov 24 08:51:31 2007
New Revision: 25155

Log:
Revert r25089 (Ignore video formats which are supported by device
but not supported by dshow driver).

It prevents code from r25091 (probing undeclared formats) functioning
properly: those code is never called if all declared by device formats
are unsupported by MPlayer (even if undeclared one is supported).

After this revert PVR-150 card should work as expected.



Modified:
   trunk/stream/tvi_dshow.c

Modified: trunk/stream/tvi_dshow.c
==============================================================================
--- trunk/stream/tvi_dshow.c	(original)
+++ trunk/stream/tvi_dshow.c	Sat Nov 24 08:51:31 2007
@@ -2067,29 +2067,18 @@ static HRESULT get_available_formats_str
 
 	pBuf = (void **) malloc((count + 1) * sizeof(void *));
 	if (pBuf) {
-	    int dst = 0;
 	    memset(pBuf, 0, (count + 1) * sizeof(void *));
 
 	    for (i = 0; i < count; i++) {
-		pBuf[dst] = malloc(size);
+		pBuf[i] = malloc(size);
 
-		if (!pBuf[dst])
+		if (!pBuf[i])
 		    break;
 
 		hr = OLE_CALL_ARGS(chain->pStreamConfig, GetStreamCaps, i,
-			       &(arpmt[dst]), pBuf[dst]);
+			       &(arpmt[i]), pBuf[i]);
 		if (FAILED(hr))
 		    break;
-		if(!memcmp(&(arpmt[dst]->majortype), &MEDIATYPE_Video, 16) && !subtype2imgfmt(&(arpmt[dst]->subtype)))
-		{
-		    DisplayMediaType("Skipping unsupported video format", arpmt[dst]);
-		    DeleteMediaType(arpmt[dst]);
-		    free(pBuf[dst]);
-		    arpmt[dst]=NULL;
-		    pBuf[dst]=NULL;
-		    continue;
-		}
-		dst++;
 	    }
 	    if (i == count) {
 		chain->arpmt = arpmt;



More information about the MPlayer-cvslog mailing list