[vlc-commits] eyetv plugin: change logic to support HD streams as suggested by cbscpe on the forums
Felix Paul Kühne
git at videolan.org
Mon Apr 4 15:37:27 CEST 2011
vlc/vlc-1.1 | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Mon Apr 4 15:34:27 2011 +0200| [89a8032d320135b81c4a9acdc703c027886372a5] | committer: Felix Paul Kühne
eyetv plugin: change logic to support HD streams as suggested by cbscpe on the forums
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=89a8032d320135b81c4a9acdc703c027886372a5
---
extras/package/macosx/eyetvplugin/eyetvplugin.c | 14 ++++++--------
1 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/extras/package/macosx/eyetvplugin/eyetvplugin.c b/extras/package/macosx/eyetvplugin/eyetvplugin.c
index 3f190a6..b4c2db4 100644
--- a/extras/package/macosx/eyetvplugin/eyetvplugin.c
+++ b/extras/package/macosx/eyetvplugin/eyetvplugin.c
@@ -1,7 +1,7 @@
/*****************************************************************************
* eyetvplugin.c: Plug-In for the EyeTV software to connect to VLC
*****************************************************************************
-* Copyright (C) 2006-2007 the VideoLAN team
+* Copyright (C) 2006-2011 the VideoLAN team
* $Id$
*
* Authors: Felix Kühne <fkuehne at videolan dot org>
@@ -309,13 +309,10 @@ static long VLCEyeTVPluginPacketsArrived(VLCEyeTVPluginGlobals_t *globals, EyeTV
{
if( globals->activePIDs[i].pid == pid )
{
- if( packetBufferSize <= (sizeof(packetBuffer)-sizeof(TransportStreamPacket)) )
- {
- /* copy packet in our buffer */
- memcpy(packetBuffer+packetBufferSize, *packets, sizeof(TransportStreamPacket));
- packetBufferSize += sizeof(TransportStreamPacket);
- }
- else
+
+ memcpy(packetBuffer+packetBufferSize, *packets, sizeof(TransportStreamPacket));
+ packetBufferSize += sizeof(TransportStreamPacket);
+ if( packetBufferSize > (sizeof(packetBuffer)-sizeof(TransportStreamPacket)) )
{
/* flush buffer to VLC */
ssize_t sent = write(i_vlcSock, packetBuffer, packetBufferSize);
@@ -331,6 +328,7 @@ static long VLCEyeTVPluginPacketsArrived(VLCEyeTVPluginGlobals_t *globals, EyeTV
}
packetBufferSize = 0;
}
+
if( i > 0 )
{
/* if we assume that consecutive packets would have the same PID in most cases,
More information about the vlc-commits
mailing list