changeset 17493:f71e678e6216

use mp_a52_framesize() when liba52 is not available
author nicodvb
date Fri, 27 Jan 2006 23:07:53 +0000
parents 3f420548c0ca
children 257c8575c5ab
files libmpdemux/muxer_mpeg.c
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/muxer_mpeg.c	Fri Jan 27 23:07:16 2006 +0000
+++ b/libmpdemux/muxer_mpeg.c	Fri Jan 27 23:07:53 2006 +0000
@@ -2266,7 +2266,13 @@
 			{
 				if(s->b_buffer[i] == 0x0B && s->b_buffer[i+1] == 0x77)
 				{
+					srate = 0;
+				#ifdef USE_LIBA52
 					len = a52_syncinfo(&(s->b_buffer[i]), &dummy, &srate, &dummy);
+				#else
+					len = mp_a52_framesize(&(s->b_buffer[i]), &srate);
+				#endif
+					if(len) fprintf(stderr, "\r\nLEN: %d, srate: %d\r\n", len, srate);
 					if((len > 0) && (srate == s->wf->nSamplesPerSec) && (i + len <= s->b_buffer_len))
 					{
 						frames++;