[Mplayer-felhasznalok] [PATCH] regi mpsub workaround

MOLNAR Andor dolphy at inf.elte.hu
Tue Sep 9 13:28:51 CEST 2003


Hi!

talaltam egy regi filmet mpsub-al es mostani cvs egy darab
feliratot nem talalt.
a regiben tizedespont van a szamokban, az ujban pedig vesszo.

itt a fix:

--------------------------------[patch]-----------------------------
--- subreader.c	Tue Sep  9 13:07:30 2003
+++ subreader.c	Tue Sep  9 13:21:37 2003
@@ -557,6 +557,11 @@
 	do
 	{
 		if (!fgets(line, LINE_LEN, fd)) return NULL;
+		p=&line[0];
+		while (!eol(*p)) {
+			if (*p=='.') *p=',';        // workaround for old mpsub format (by dph)
+			p++;
+		}
 	} while (sscanf (line, "%f %f", &a, &b) !=2);

 	mpsub_position += a*mpsub_multiplier;
------------------------[patch]-----------------------------------

dph




More information about the MPlayer-felhasznalok mailing list