summaryrefslogtreecommitdiffstats
path: root/libmpdemux
diff options
context:
space:
mode:
authorlu_zero <lu_zero@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-11-13 23:00:12 +0000
committerlu_zero <lu_zero@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-11-13 23:00:12 +0000
commit4d8aeade41327a3e85a13da3bb39357c8696dc64 (patch)
treeaca3a5c4c76c1427b83c6906b83552ac4c97fafe /libmpdemux
parent746c24835183f0d34f25cdad04e60c3fe60df055 (diff)
downloadmpv-4d8aeade41327a3e85a13da3bb39357c8696dc64.tar.bz2
mpv-4d8aeade41327a3e85a13da3bb39357c8696dc64.tar.xz
fetch metadata for audio (from amol)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25038 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/demux_nemesi.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libmpdemux/demux_nemesi.c b/libmpdemux/demux_nemesi.c
index 8e99e0caa4..7d90c8e4f6 100644
--- a/libmpdemux/demux_nemesi.c
+++ b/libmpdemux/demux_nemesi.c
@@ -74,12 +74,13 @@ static void link_session_and_fetch_conf(Nemesi_DemuxerStreamData * ndsd,
rtp_ssrc *ssrc = NULL;
rtp_frame * fr = &ndsd->first_pkt[stype];
rtp_buff trash_buff;
+ int must_prefetch = ((fps != NULL) || (buff != NULL)) ? 1 : 0;
ndsd->session[stype] = sess;
ssrc = wait_for_packets(ndsd, stype);
- if ( (ssrc) && (fps != NULL) ) {
+ if ( ((ssrc) && (must_prefetch)) ) {
if (buff == NULL)
buff = &trash_buff;
@@ -88,7 +89,7 @@ static void link_session_and_fetch_conf(Nemesi_DemuxerStreamData * ndsd,
/* Packet prefecthing must be done anyway or we won't be
able to get the metadata, but fps calculation happens
only if the user didn't specify the FPS */
- if (!force_fps) {
+ if ( ((!force_fps) && (fps != NULL)) ) {
while ( *fps <= 0 ) {
//Wait more pkts to calculate FPS and try again
sched_yield();