[mythtv] Patch: small audio fix
Ed Wildgoose
lists at wildgooses.com
Sat Feb 5 02:11:53 UTC 2005
The attached patch seems to (finally) fix my slight video jitter that I
was seeing.
Grateful if someone could apply to cvs.
Ed W
-------------- next part --------------
Index: libs/libmyth/bio2jack.c
===================================================================
RCS file: /var/lib/mythcvs/mythtv/libs/libmyth/bio2jack.c,v
retrieving revision 1.2
diff -u -r1.2 bio2jack.c
--- libs/libmyth/bio2jack.c 11 Nov 2004 07:36:44 -0000 1.2
+++ libs/libmyth/bio2jack.c 5 Feb 2005 02:09:50 -0000
@@ -1,5 +1,5 @@
/*
- * Copyright 2003 Chris Morgan <cmorgan at alum.wpi.edu>
+ * Copyright 2003-2004 Chris Morgan <cmorgan at alum.wpi.edu>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -353,6 +353,8 @@
jack_driver_t* drv = (jack_driver_t*)arg;
unsigned int i;
+ gettimeofday(&drv->previousTime, 0); /* record the current time */
+
#if CALLBACK_TRACE
TRACE("nframes %ld, sizeof(sample_t) == %d\n", (long)nframes, sizeof(sample_t));
#endif
@@ -536,7 +538,6 @@
} /* while(jackFramesAvailable && drv->pPlayPtr) */
- gettimeofday(&drv->previousTime, 0); /* record the current time */
drv->written_client_bytes+=read;
drv->played_client_bytes+=drv->clientBytesInJack; /* move forward by the previous bytes we wrote since those must have finished by now */
drv->clientBytesInJack = read; /* record the input bytes we wrote to jack */
@@ -590,7 +591,6 @@
#if CALLBACK_TRACE
TRACE("PAUSED or STOPPED or CLOSED, outputting silence\n");
#endif
- gettimeofday(&drv->previousTime, 0); /* record the current time */
/* output silence if nothing is being outputted */
for(i = 0; i < drv->num_output_channels; i++)
More information about the mythtv-dev
mailing list